Copy Cells

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I have 2 workbooks:
# 1 Workbook.("TBD.xls").worksheet("Sheet1")

#2 is a workbook that I open with this VBA macro:
fName = Application.GetOpenFilename
Workbooks.Open filename:=fName
I also have this VBA Macro for fname
blastrow = Cells(Rows.Count, "B").End(xlUp).Row
isum = Application.WorksheetFunction.Sum(Range("b1:b10000"))
Cells(blastrow + 2, "B").Value = isum

My Question is: How do I copy the value of "Isum" in the
Workbook.("TBD.xls").worksheet("Sheet1") in cell "F34"
Thanks,
 
Workbooks("TBD.xls").Worksheets("Sheet1").Range("F34") = isum
note the s at the end of 'worksheets' and 'workbooks'
Pascal
 
Hi,

Do not copy. Create variables for the target and source.

EG:
Cells(blastrow + 2, "B").Value = isum
set x=Cells(blastrow + 2, "B").Value

Workbook.("TBD.xls").activate
set y=range("F34")
y.value=x.value

This is secret stuff. Do not tell anyone.

see my stuff at:
http://www.geocities.com/excelmarksway

regards
Mark E. Philpot
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Copy Cell.Value 1
Active cell 3
VBA Formula Help 6
Activating Workbooks 2
Better way to apply a formula 2
Listbox in VBA 1
Sub out of range 1
Open files from List 9

Back
Top