xlpastevalues

  1. D

    VBA code to randomly pick from a list of names

    Hi, I have this code that randomly picks a different name from a list. Sub CommandButton1_Click() Dim lrcd As Long SendKeys "%^{F9}" Range("H31").Copy 'Range("C2:C7").PasteSpecial xlPasteValues lrcd = Sheets("Sheet1").Range("E" & Rows.Count).End(xlUp).Row Sheets("Sheet1").Cells(lrcd +...
  2. P

    VBA copy paste in table

    Hello Guys, I would like to as your help with the following issue. I want to select range and paste as value. I have done it before like this Range("AA2:AA118").Copy Range("AA2:AA118").PasteSpecial xlPasteValues However now this range is in a table. Can you help me how to do this? Thanks...
  3. J

    Copy excel range to another workbook with table and values

    I have this macro that copies that values, but doesnt copy over the table. Sub OpenReport() Set NewBook = Workbooks.Add Workbooks("TMSRULES.xlsm").Worksheets("Sheet1").Range("A115:J178").Copy NewBook.Worksheets("Sheet1").Range("A1").PasteSpecial (xlPasteValues) End Sub If I remove...
  4. X

    VBA Copy Paste on next blank row below

    Hi all, I'm quite new to VBA/Macros, & I'm trying to paste certain values from one tab to another tab on the same worksheet. What I have so far: Sub LogButton() Worksheets("Coaching Form").Range("I8").Copy Worksheets("Database").Range("A2").PasteSpecial xlPasteValues...
  5. gheyman

    Copy data from numerious tabs and Paste into one tab

    I need to grab data from numerous tabs. I have some code that does that but I need to slightly modify it. Sub Consolidate_BOEs() ' Dim ws As Worksheet ' For Each ws In Sheets ' If ws.Range("U1") = "54-TPL" Then ws.Range("B11:U1000").Copy Sheets("BOE...
  6. B

    VBA Copy Non-adjacent cells into 1 row, per worksheet..

    Hi Here's my current code; Dim ws As Worksheet For Each ws In ActiveWorkbook.Worksheets If ws.Name Like "*3CT" Then ws.Range("A29,C29,E29,G29,J29,N29,A34,C34,A36,C36,A38,C38").Copy Sheets("3CT Objectives").Cells(Rows.Count...
  7. T

    How can I make this macro repeat but update the range to the next row?

    Hi everyone, I have this macro that works great However if i could get it to repeat the exact same macro just changing "Actn1 = Sheets("Control").Range("C2")" from range C2 to C3, C4, C5 etc until it had done all the names in the row that would be great. any ideas? Sub FilterExp1()...
  8. A

    Populating Column "A" after copy & paste

    Hi Again, Can anyone help me with copying/pasting using a userform. I have a master spreadsheet that I'm copying data from an pasting to a different workbook. I've got this bit working fine but once the pasting over has happened, I need to populate column "A" from a textbox value all the way...
  9. L

    Do I need .SELECT here? Columns not filling as expected.

    Here's a short section of my code. With comp .Range("A1").PasteSpecial xlPasteValues .Rows("1:3").Delete .Columns("B:B").Delete .Columns("A:B").RemoveDuplicates Columns:=Array(1, 2), Header:=xlNo LR2 = comp.Cells(Rows.Count, 1).End(xlUp).Row .Range("A1:B" & LR2).Copy End...
  10. S

    Generic VBA code Pasting data to multiple sheets if condition met... smoothly

    Hello, I have literally started learning basic VBA this week. So far all my codes are immensely long lists of copy and pasting and I'm more than sure it can be condensed down :confused: Literally my code is: Private Sub KEY_OUT_Click() Application.ScreenUpdating = False Dim copySheet As...
  11. H

    Making a If True Double Loop Copy Special Paste Faster

    Hello, Hope you are well. I have code that looks on Sheet 7 and Sheet 18 for a cells thats values are equal. Then pastes contiguous and non contiguous values in the same row as the equal cell in Sheet 7 to Sheet 18. It takes a very long time. Can someone please help to make it faster...
  12. J

    macro with If and Else to copy if Yes and leave the same if NO

    Hi guys, I have my macro here and I would like it to copy the range if the Cell W5 is Yes and if NO copy just the selected range I have the macro but the yes/no thing is quite hard. Thanks for the help. Sub OpenFile_PW() Dim Fname As String Dim Wbk As Workbook Dim Sht As...
  13. P

    A quicker way of looping

    I am using a FOR, NEXT looking, checking through a list of 5,000 names to see if the corresponding cell is populated with any data. if it does it's copying it to another workbook, going back to the original.....etc etc , it seems that doing this check and copying and pasting is taking a...
  14. J

    Copy and paste data from one sheet to another

    Hi guys, I tried to make this macros but I get the red code highlited in yellow when I run it, Do someone know why? Thanks for the help Sub CopyData() Dim LastRow As Long Dim Sht As Worksheet Worksheets("Datadump").Range("E:G,S:S,AW:AW,AY:AY,BE:BE,CC:CC,CF:CV").Copy Set Sht =...
  15. M

    Copy rows only if cells are not blank in selected columns

    Below code (Code One) is currently working fine, where selected columns are copy & pasted with single criteria in Column A. However, I am trying to add another condition, where excel will not copy cells if Columns N to R are blank. I tried writing Code Two (below) but getting Run-time error '9'...
  16. J

    Very slow Macro, need help speeding it up

    Hi, Below is my code, is there anyone who can help optimize this? Sub filtering() ' ' filtering Macro ' Dim Rng1 As Range, Rng2 As Range Dim ws1 As Worksheet, ws2 As Worksheet, ws3 As Worksheet Dim src As Range Set ws1 = ThisWorkbook.Sheets("eodcpos") Set ws2 =...
  17. P

    Call Quality Form on Excel with VBA

    I am a newbie in VBA, and i created a form that copies the data into a new sheet once the "Submit" button is clicked. However, instead of just filling up one row every form completion entry, other data fills up the blank cells from the top row. Also, when the "Submit" button is clicked, it slows...
  18. Pinaceous

    VBA Copy Paste from a Table Question...

    Hi All, I'm using a simple copy paste Macro22(), below for reference, from a Table that is conditionally formatted of Worksheet(2) onto a nondescript Worksheet(9). Sub Macro22() ' ' Macro22 Macro ' Application.ScreenUpdating = False Worksheets(2).Range("B11:U180").Copy...
  19. C

    PasteSpecial

    I'm currently setting up a macro that will input a vlookup from another workbook into a sheet, and then copy and paste just the value into another sheet in the first workbook. Sheets("CopyPaste").Select Worksheets("CopyPaste").Cells(9 + (nRow - 9), 17).Select...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top