Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Howard,
Am Thu, 16 Jan 2014 03:32:03 -0800 (PST) schrieb L. Howard: I am trying to get the four values in Range("D11,D13,I20,D15") of source workbook and sheet1 to target workbook and sheet ORDER FORM range(A41)up next available row, each in individual cells of that row and in the order they are in. try: Sub PriceToPOrder() Dim wksSource As Worksheet, wksTarget As Worksheet Dim wkbSource As Workbook, wkbTarget As Workbook Dim rngSource As Range, rngTarget As Range Dim varRicho(3) As Variant Dim varLanier As Variant Dim rngC As Range Dim i As Long Set wkbSource = Workbooks("PRICE COMPARE TEST SHEET.xlsm") Set wkbTarget = Workbooks("ORDER FORM TEST SHEET.xlsm") Set wksSource = wkbSource.Sheets("Sheet1") Set wksTarget = wkbTarget.Sheets("ORDER FORM") If Not IsFileOpen("C:\Users\Howard Kittle\Documents\ORDER FORM TEST SHEET.xlsm") Then Workbooks.Open ("C:\Users\Howard Kittle\Documents\ORDER FORM TEST SHEET.xlsm") End If 'Set all the copy cells for RICHO or LANIER For Each rngC In wksSource.Range("D11,D13,I20,D15") varRicho(i) = rngC.Value i = i + 1 Next wksTarget.Cells(Rows.Count, 1).End(xlUp)(2) _ .Resize(columnsize:=4) = varRicho End Sub Regards Claus B. -- Win XP PRof SP2 / Vista Ultimate SP2 Office 2003 SP2 /2007 Ultimate SP2 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Keep original cell formatting when using transpose array formula | Excel Worksheet Functions | |||
Redimming an array dynamically assigned from range (how to redim first dimension of a 2-D array? /or/ reverse the original array order) | Excel Programming | |||
Array: Counting multiple values within array | Excel Worksheet Functions | |||
search an array for values contained in another array | Excel Programming | |||
Transpose Array | Excel Discussion (Misc queries) |