Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Move down to next cell in excel? 1

Status
Not open for further replies.

sozzer

Technical User
Apr 4, 2005
73
GB
Hi all

Really dumb question....

I'd just like to know the syntax to move from current cell to the next one down.

For example, I'd like to run the below through the whole of column B, just moving to next cell after

Dim strvar As String
Range("b34").Select
strvar = Range("b34").Value
Range("b34").Value = strvar


Any help appreciated!

Cheers

adam
 
any number of ways - more information would be helpful though.....is this a one off movement or part of a loop?

simple answer is

Activecell.offset(1,0).select

very rarely necessary to select anything though

To change the value of a cell:

Range("B34").value = Range("B35").value

 
There are several ways to do what you ask. But the question is, what are you trying to achieve? It looks like you are trying to replace the contents of column B with values ( instead of formulae ) ... if so, then Copy and PasteSpecial would be quicker.

Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 
Just so you know (in case you need to do this in the future), you can use xlbo's suggestion with an entire column at once:

range("B:B").value = range("B:B").value

will replace all formulas in column B with their values!

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ181-2886 before posting.
 
Hi John,

nice one ====> *

Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 
Thank you, kind sir!

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ181-2886 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top