Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 260
Default Selecting Cells using dialog box

Hey

I would like to be able to have a little popup dialogbox
that allows me to click in Excel and select a range of
cells by clicking the mouse on a cell and dragging into
the cells I want to include into my range. Then after I
release my mouse button, the actual range pops up in the
dialogbox. For example I click a button and the dialog
pop up. I click in Excel and drag from A3 to B20. When I
release the mouse button, I would like for the popupbox
textbox to show A3:B20. (This type of thing can be
observed when creating a chart or pivot table.)


How do I do this?


Thanks
Todd Huttenstine
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 983
Default Selecting Cells using dialog box

You will need to create a userform and place a label on that form. Then run
the test funtion which should be placed in one of the sheets...

Option Explicit

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
UserForm1.Label1.Caption = Target.Address
End Sub

Sub test()
UserForm1.Show False
End Sub


"Todd Huttenstine" wrote:

Hey

I would like to be able to have a little popup dialogbox
that allows me to click in Excel and select a range of
cells by clicking the mouse on a cell and dragging into
the cells I want to include into my range. Then after I
release my mouse button, the actual range pops up in the
dialogbox. For example I click a button and the dialog
pop up. I click in Excel and drag from A3 to B20. When I
release the mouse button, I would like for the popupbox
textbox to show A3:B20. (This type of thing can be
observed when creating a chart or pivot table.)


How do I do this?


Thanks
Todd Huttenstine

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 260
Default Selecting Cells using dialog box

Thanks



-----Original Message-----
You will need to create a userform and place a label on

that form. Then run
the test funtion which should be placed in one of the

sheets...

Option Explicit

Private Sub Worksheet_SelectionChange(ByVal Target As

Range)
UserForm1.Label1.Caption = Target.Address
End Sub

Sub test()
UserForm1.Show False
End Sub


"Todd Huttenstine" wrote:

Hey

I would like to be able to have a little popup

dialogbox
that allows me to click in Excel and select a range of
cells by clicking the mouse on a cell and dragging into
the cells I want to include into my range. Then after

I
release my mouse button, the actual range pops up in

the
dialogbox. For example I click a button and the dialog
pop up. I click in Excel and drag from A3 to B20.

When I
release the mouse button, I would like for the popupbox
textbox to show A3:B20. (This type of thing can be
observed when creating a chart or pivot table.)


How do I do this?


Thanks
Todd Huttenstine

.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,327
Default Selecting Cells using dialog box

Hi Todd

It I understand this right:

Sub test()
Dim R As Range
On Error Resume Next
Set R = Application.InputBox("Select a range:", _
"Todd says", Selection.Address, Type:=8)
If R Is Nothing Then Exit Sub
R.Font.Bold = True 'or whatever
End Sub

You can also make a userform with a RefEdit control on it for similar
behavior.

HTH. Best wishes Harald

"Todd Huttenstine" skrev i melding
...
Hey

I would like to be able to have a little popup dialogbox
that allows me to click in Excel and select a range of
cells by clicking the mouse on a cell and dragging into
the cells I want to include into my range. Then after I
release my mouse button, the actual range pops up in the
dialogbox. For example I click a button and the dialog
pop up. I click in Excel and drag from A3 to B20. When I
release the mouse button, I would like for the popupbox
textbox to show A3:B20. (This type of thing can be
observed when creating a chart or pivot table.)


How do I do this?


Thanks
Todd Huttenstine



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
No Dialog Box when Pasting Cut Cells Albert Lan New Users to Excel 1 March 3rd 09 03:56 PM
Format Cells Dialog Box EYREI Excel Discussion (Misc queries) 1 October 20th 05 01:52 AM
format cells dialog box does not come up GMed Excel Discussion (Misc queries) 1 April 14th 05 05:00 PM
Selecting a file path in Excel VBA using FileOpen dialog John Robinson Excel Programming 1 November 1st 03 09:59 AM
Format Cells dialog box Ryan Poth[_2_] Excel Programming 0 September 17th 03 12:45 AM


All times are GMT +1. The time now is 06:44 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"