using variables instead of cells

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

Guest

freig = cells(23,2)

freig.value = m
cells(23,2).value = m

I guess I have the syntax wrong i would expect that to produce the same
results
but freig = cells(23,2) just assignes the value of cell(23,2) to freig
Is there a way to assign an actual range to to that variable so that any
method that could be performed with cells(23,2) could be done with the
variable freig instead?
 
never mind i already knew the answer to this question, i feel stupid
set freig = cells(23,2)
 
Ben,

freig is an object, so you have to set it, not implicit assign

Set freig = cells(23,2)

freig.value = m


--

HTH

RP
(remove nothere from the email address if mailing direct)
 

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

Back
Top