Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 465
Default Using Popups to select a range of cells.


Hi All

I have a small request for help with code.

I need a macro to have popups request the first and last cells in a
range , and then to select them.

Can someone help?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 449
Default Using Popups to select a range of cells.

Sub test()
Dim Rng As Range
On Error Resume Next
Set Rng = Application.InputBox("Select your range", _
"Mousework", Type:=8)
On Error GoTo 0
If Rng Is Nothing Then Exit Sub
MsgBox Rng.Address
End Sub


HTH. Best wishes Harald


"Colin Hayes" wrote in message
...

Hi All

I have a small request for help with code.

I need a macro to have popups request the first and last cells in a range
, and then to select them.

Can someone help?


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 465
Default Using Popups to select a range of cells.


HI Harald

Thank you very much for you help.

It's not quite what I needed though , unfortunately. I need to input two
cells (e.g. Popup 1 - A1 , Popup 2 - A30000) and for them to be selected
with me not having to visit both with the mouse.

Is this possible?

Best Wishes



In article , Harald Staff
writes
Sub test()
Dim Rng As Range
On Error Resume Next
Set Rng = Application.InputBox("Select your range", _
"Mousework", Type:=8)
On Error GoTo 0
If Rng Is Nothing Then Exit Sub
MsgBox Rng.Address
End Sub


HTH. Best wishes Harald


"Colin Hayes" wrote in message
...

Hi All

I have a small request for help with code.

I need a macro to have popups request the first and last cells in a range
, and then to select them.

Can someone help?




  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 449
Default Using Popups to select a range of cells.

Sure. Put two Refedit controls onto a userform.

http://www.contextures.com/xlUserForm01.html

Note that a range can be nothing, one cell, or multiple cells, your VBA must
decide what to do if multiple cells are selected.

Best wishes Harald


"Colin Hayes" wrote in message
...

HI Harald

Thank you very much for you help.

It's not quite what I needed though , unfortunately. I need to input two
cells (e.g. Popup 1 - A1 , Popup 2 - A30000) and for them to be selected
with me not having to visit both with the mouse.

Is this possible?

Best Wishes



In article , Harald Staff
writes
Sub test()
Dim Rng As Range
On Error Resume Next
Set Rng = Application.InputBox("Select your range", _
"Mousework", Type:=8)
On Error GoTo 0
If Rng Is Nothing Then Exit Sub
MsgBox Rng.Address
End Sub


HTH. Best wishes Harald


"Colin Hayes" wrote in message
...

Hi All

I have a small request for help with code.

I need a macro to have popups request the first and last cells in a
range
, and then to select them.

Can someone help?





  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 449
Default Using Popups to select a range of cells.

"Colin Hayes" wrote in message
...
In article , Harald Staff
writes


OK Thanks. Too technical for me I'm afraid,. I imagined it would be more
straightforward. Anyway , thanks for your help.

Best wishes.


The easier to use, the harder to build. The most intuitive user interfaces
are extremely complex under the hood. But I urge you to spend a couple of
hours and give this a try, everything is easy once you know how to.

Best wishes Harald

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Select a range of cells wx4usa Excel Discussion (Misc queries) 2 December 23rd 09 07:32 PM
When entering data into a range of cells, select the entire range. Q Excel Discussion (Misc queries) 0 September 26th 07 04:36 AM
select random value in a range of cells Pete Morris Excel Discussion (Misc queries) 4 March 30th 07 09:26 PM
Select Range of Cells programmingrookie Excel Discussion (Misc queries) 2 August 11th 05 07:13 PM
select a range using "cells()" fullers Excel Worksheet Functions 2 July 6th 05 06:00 PM


All times are GMT +1. The time now is 10:15 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"