![]() |
OMG! This seems to easy I can't get it
You could try
Sub ColSelect Dim Col1St As String Dim Col1Fin As String Dim Col2St As String Dim Col2Fin As String Col1St = "H" Col1Fin = "H" Col2St = "A" Col2Fin = "F" Range(Col1St & ":" & Col1Fin & "," & Col2St & ":" & Col2Fin).Select End Sub Or are you trying to record what someone selects? "Cesar Zapata" wrote in message ... Hi, this looks easey but is 3:45 PM and I dont think to well after 3:00 pM :) what I'm trying to is to select columns. Range("H:H,A:F").Select this is what the macro recorded does but the HH can change anytime so I'm trying to it with VBA like this: col = ActiveCell.EntireColumn.Address Range("ActiveCell.EntireColumn.Address,A:F").Selec t or range(activecell.column,"A:F").select this selects all the columsn from A,F to whater the acticell is but it does not jump. for example if I just want to select A:F and AZ it does not work. can you please help? Thanks cesar ' |
OMG! This seems to easy I can't get it
Thanks that worked great!
"John Gittins" wrote in message ... You could try Sub ColSelect Dim Col1St As String Dim Col1Fin As String Dim Col2St As String Dim Col2Fin As String Col1St = "H" Col1Fin = "H" Col2St = "A" Col2Fin = "F" Range(Col1St & ":" & Col1Fin & "," & Col2St & ":" & Col2Fin).Select End Sub Or are you trying to record what someone selects? "Cesar Zapata" wrote in message ... Hi, this looks easey but is 3:45 PM and I dont think to well after 3:00 pM :) what I'm trying to is to select columns. Range("H:H,A:F").Select this is what the macro recorded does but the HH can change anytime so I'm trying to it with VBA like this: col = ActiveCell.EntireColumn.Address Range("ActiveCell.EntireColumn.Address,A:F").Selec t or range(activecell.column,"A:F").select this selects all the columsn from A,F to whater the acticell is but it does not jump. for example if I just want to select A:F and AZ it does not work. can you please help? Thanks cesar ' |
All times are GMT +1. The time now is 04:47 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com