Anthony's VBA Forum Index Anthony's VBA Forum
Where the knowledge is shared
Menu
 Anthony's VBA Forum IndexHome Page
 Anthony's VBA Forum IndexForum Index
FAQFAQ
MemberlistMemberlist
UsergroupsUsergroups
RegisterRegister
ProfileProfile
Log in to check your private messagesMessages
Log inLogin/Out

Quick Search

Advanced Search

Links
Consulting
Products

Who's Online
[ Administrator ]
[ Moderator ]


cell adress

 
Post new topic   Reply to topic     Anthony's VBA Forum Index -> General Excel VBA
View previous topic :: View next topic  
Author Message
duffy



Joined: 01 Sep 2009
Posts: 2

PostPosted: Wed Sep 02, 2009 7:35 am    Post subject: cell adress Reply with quote

Is there a VBA statement that will let me indirectly specify a cell address;
as for example: Range(A & X).value=200 ?
Where X is a cell address that contains a digit that will complete the cell address.

To expand, let us say that cell B2 contains the digit 5
Then with the proper VBA statement X would point to B2 which in turn would return the digit 5
Under these conditions Range(A & X). would become Range(A5).
Back to top
View user's profile Send private message
jcosta



Joined: 07 Sep 2009
Posts: 4

PostPosted: Mon Sep 07, 2009 9:38 pm    Post subject: Reply with quote

Sure:

Dim x As String

x = "B2"
y = Range("A" & Range(x).Value)

if B2 = 5 and A5 = 30 then you will have y=30

is that what you need?

Joaquin
Back to top
View user's profile Send private message
duffy



Joined: 01 Sep 2009
Posts: 2

PostPosted: Wed Sep 09, 2009 6:52 pm    Post subject: Reply with quote

Message for JCOStA

First, thanks so much for taking the time to respond to my query. Im a Nubie and have been searching for a solution to my question for some weeks. Thats certainly not a confidence building experience when you are just starting out.

Your solution worked like a charm and needless to say Im most appreciative.

Duffy
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Anthony's VBA Forum Index -> General Excel VBA All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group