This should be VERY simple. I'm trying to code VBA for the first time, and I
get a syntax error on the below statement. From all the tutorials I read,
this should work.
any clue?
Range(a99) ='[Book1.xls]Sheet1'!$B$1
Hi Greg
You need a little more code to make it work, and double qutation signs.
Have a look at this:
With Workbooks("Book1.xls")
MyValue = .Sheets(1).Range("B1").Value
End With
Range("A99") = MyValue
Regards,
Per
> This should be VERY simple. I'm trying to code VBA for the first time,
> and I
[quoted text clipped - 3 lines]
>
> Range(a99) ='[Book1.xls]Sheet1'!$B$1
Greg - 20 Mar 2008 21:55 GMT
Wow, that's a far cry from seeing some tutorials that say to do it like this:
='C:\My Documents\Worksheets\[Book1.xls]Shhet1'!$B1
but it worked!! Thank you!!
> Hi Greg
>
[quoted text clipped - 18 lines]
> >
> > Range(a99) ='[Book1.xls]Sheet1'!$B$1