![]() |
Range issue
I would like my macro to look for the first empty line and use that as the secdond range value. So for example, Do while ActiveCell< empty activecell.offset(1,0).Select loop Range("A3:activecell.offset(-1,0)").select The problem is activecell.offset(-1,0) doesn't appear to be a valid Range argument. -- evil baby ------------------------------------------------------------------------ evil baby's Profile: http://www.excelforum.com/member.php...o&userid=31983 View this thread: http://www.excelforum.com/showthread...hreadid=519719 |
Range issue
It will be a valid argument if you don't use it as a string - text.
Try this: Range("A3", ActiveCell.Offset(-1, 0)).Select good luck, Excel_Fun evil baby napisal(a): I would like my macro to look for the first empty line and use that as the secdond range value. So for example, Do while ActiveCell< empty activecell.offset(1,0).Select loop Range("A3:activecell.offset(-1,0)").select The problem is activecell.offset(-1,0) doesn't appear to be a valid Range argument. -- evil baby ------------------------------------------------------------------------ evil baby's Profile: http://www.excelforum.com/member.php...o&userid=31983 View this thread: http://www.excelforum.com/showthread...hreadid=519719 |
Range issue
Don't bother with it, use this instead
Do While ActiveCell.Offset(1, 0) < Empty ActiveCell.Offset(1, 0).Select Loop -- HTH Bob Phillips (remove nothere from email address if mailing direct) "evil baby" wrote in message ... I would like my macro to look for the first empty line and use that as the secdond range value. So for example, Do while ActiveCell< empty activecell.offset(1,0).Select loop Range("A3:activecell.offset(-1,0)").select The problem is activecell.offset(-1,0) doesn't appear to be a valid Range argument. -- evil baby ------------------------------------------------------------------------ evil baby's Profile: http://www.excelforum.com/member.php...o&userid=31983 View this thread: http://www.excelforum.com/showthread...hreadid=519719 |
Range issue
Thanks for the help, didn't even bother to look at where I had the quotes. -- evil baby ------------------------------------------------------------------------ evil baby's Profile: http://www.excelforum.com/member.php...o&userid=31983 View this thread: http://www.excelforum.com/showthread...hreadid=519719 |
All times are GMT +1. The time now is 03:12 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com