Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #5  
Old 09-04-2016, 05:25 PM
Dave T Dave T is offline InputBox selects rows Windows 7 64bit InputBox selects rows Office 2007
Advanced Beginner
InputBox selects rows
 
Join Date: Nov 2014
Location: Australia
Posts: 66
Dave T is on a distinguished road
Default

Hello NoSparks and p45cal,

I really appreciate both of your replies and sorry for not replying sooner.

I decided to take the kids climbing for a couple of days. Thursday night we left Adelaide for a quick drive to Mount Arapiles (one of the best cliffs in Australia that is in Victoria) and only got back late Sunday night.

I did find some examples that selected a row from cell A to K, but could not work out how to get this to work on more than one row.

Code:
 
Sub SelectRow()
'http://stackoverflow.com/questions/16394036/select-column-1-to-10-of-activecell-row-in-excel

Range("A" & ActiveCell.Row).Resize(1, 11).Select
'OR
ActiveSheet.Range(Cells(ActiveCell.Row, 1), Cells(ActiveCell.Row, 11)).Select
'OR
Range("A" & ActiveCell.Row & ":K" & ActiveCell.Row).Select

End Sub
I did not want to be restricted to a fixed range as my example showed (maybe my question was poorly worded) and what p45cal provided suited my needs perfectly. Both of his examples are good but technically the 'blah2' option where cell selection between the two columns is required is the best.

Thanks again to both of you for your responses.

Regards,
Dave T

Last edited by Dave T; 09-05-2016 at 07:02 AM.
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
InputBox selects rows MS Word 2010 Table Selector Selects Header On One Page and Rows On Next Page scptech Word Tables 4 01-11-2016 02:55 PM
VBA Macro for word with Inputbox ryanch69 Word VBA 2 12-03-2015 07:45 AM
InputBox selects rows Idiot Proof Entry with InputBox arpirnat Word VBA 1 04-27-2015 10:03 PM
Is there a way to change how Excel auto selects where it pulls data? PStark Excel 0 12-30-2014 09:28 AM
InputBox selects rows Cannot select single characters. Word selects paragraphs or parts of sentences. TMinnich Word 2 10-25-2013 09:38 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:01 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft