ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Selecting ranges with a text box (https://www.excelbanter.com/excel-programming/277585-selecting-ranges-text-box.html)

Ed[_13_]

Selecting ranges with a text box
 
Bob,

You can add a UserForm and set it's ShowModeal to False.
This will allow the user to copy from cells while the
form remains open.

-----Original Message-----
I am trying to duplicate the functionality of the

inputbox
with a type =8. (Setting type to 8 allows the user to
select a range of cells on a worksheet using the mouse
while the dialog box remains on top).

I am trying to allow the user to input a range into a

text
box by selecting a range of cells using the mouse.

I am trying to do this by duplicating the functionality

of
the inputbox with a type =8. (Setting type to 8 allows
the user to select a range of cells on a worksheet using
the mouse while the dialog box remains on top).

This code will show the functionality I am trying to
duplicate.

Set mycell = Application.InputBox( _
prompt:="Select the range of cells.", Type:=8)

I would use this code as is except I have other items I
want to add to a dialog box.

Thanks,
Bob
.


Bob Metzler

Selecting ranges with a text box
 

Thanks for your help. This works for cutting and pasting data into a
textbox, but I was hoping to have the address of the range input
automatically when I selected it on a worksheet, similar to the inputbox
control with type=8. It appears that refedit will work, although it
does look a bit different than the inputbox dialog box.


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


All times are GMT +1. The time now is 03:17 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com