Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi all.........
I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi
you could use a input box instead and have them enter the cell address. Dim stg As String stg = InputBox("enter cell address") MsgBox stg 'for test only Range(stg).Select 'for test only regards FSt1 "CLR" wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you, but no.......in this instance I want the user to select a
cell........ Vaya con Dios, Chuck, CABGx3 "FSt1" wrote in message ... hi you could use a input box instead and have them enter the cell address. Dim stg As String stg = InputBox("enter cell address") MsgBox stg 'for test only Range(stg).Select 'for test only regards FSt1 "CLR" wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dim myCell as range
set mycell = nothing on error resume next 'cancel will cause an error set mycell = application.inputbox(Prompt:="select a cell", type:=8).cells(1) on error goto 0 if mycell is nothing then msgbox "You didn't select a cell!" else msgbox "You selected: " & mycell.address(external:=true) end if CLR wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 -- Dave Peterson |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Got it Dave, and it does me fine...........thank you most kindly.......
BTW.......what does the Type:=8 mean, and are there other choices? Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... Dim myCell as range set mycell = nothing on error resume next 'cancel will cause an error set mycell = application.inputbox(Prompt:="select a cell", type:=8).cells(1) on error goto 0 if mycell is nothing then msgbox "You didn't select a cell!" else msgbox "You selected: " & mycell.address(external:=true) end if CLR wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 -- Dave Peterson |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I hope that there are other choices--or what the heck was MS thinking when
starting with type:=8. <vbg Type:=8 means that you want to return a range. If you search VBA's help for inputbox method (not inputbox function), you'll see: Type Optional Variant. Specifies the return data type. If this argument is omitted, the dialog box returns text. Can be one or a sum of the following values. Value Meaning 0 A formula 1 A number 2 Text (a string) 4 A logical value (True or False) 8 A cell reference, as a Range object 16 An error value, such as #N/A 64 An array of values You can use the sum of the allowable values for Type. For example, for an input box that can accept both text and numbers, set Type to 1 + 2. CLR wrote: Got it Dave, and it does me fine...........thank you most kindly....... BTW.......what does the Type:=8 mean, and are there other choices? Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... Dim myCell as range set mycell = nothing on error resume next 'cancel will cause an error set mycell = application.inputbox(Prompt:="select a cell", type:=8).cells(1) on error goto 0 if mycell is nothing then msgbox "You didn't select a cell!" else msgbox "You selected: " & mycell.address(external:=true) end if CLR wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 -- Dave Peterson -- Dave Peterson |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I guess that's why you get the Big Bucks, Dave <g
Thanks most kindly, Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... I hope that there are other choices--or what the heck was MS thinking when starting with type:=8. <vbg Type:=8 means that you want to return a range. If you search VBA's help for inputbox method (not inputbox function), you'll see: Type Optional Variant. Specifies the return data type. If this argument is omitted, the dialog box returns text. Can be one or a sum of the following values. Value Meaning 0 A formula 1 A number 2 Text (a string) 4 A logical value (True or False) 8 A cell reference, as a Range object 16 An error value, such as #N/A 64 An array of values You can use the sum of the allowable values for Type. For example, for an input box that can accept both text and numbers, set Type to 1 + 2. CLR wrote: Got it Dave, and it does me fine...........thank you most kindly....... BTW.......what does the Type:=8 mean, and are there other choices? Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... Dim myCell as range set mycell = nothing on error resume next 'cancel will cause an error set mycell = application.inputbox(Prompt:="select a cell", type:=8).cells(1) on error goto 0 if mycell is nothing then msgbox "You didn't select a cell!" else msgbox "You selected: " & mycell.address(external:=true) end if CLR wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 -- Dave Peterson -- Dave Peterson |
#8
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
When BillG, WarrenB and go out, I always pick up the tab!
CLR wrote: I guess that's why you get the Big Bucks, Dave <g Thanks most kindly, Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... I hope that there are other choices--or what the heck was MS thinking when starting with type:=8. <vbg Type:=8 means that you want to return a range. If you search VBA's help for inputbox method (not inputbox function), you'll see: Type Optional Variant. Specifies the return data type. If this argument is omitted, the dialog box returns text. Can be one or a sum of the following values. Value Meaning 0 A formula 1 A number 2 Text (a string) 4 A logical value (True or False) 8 A cell reference, as a Range object 16 An error value, such as #N/A 64 An array of values You can use the sum of the allowable values for Type. For example, for an input box that can accept both text and numbers, set Type to 1 + 2. CLR wrote: Got it Dave, and it does me fine...........thank you most kindly....... BTW.......what does the Type:=8 mean, and are there other choices? Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... Dim myCell as range set mycell = nothing on error resume next 'cancel will cause an error set mycell = application.inputbox(Prompt:="select a cell", type:=8).cells(1) on error goto 0 if mycell is nothing then msgbox "You didn't select a cell!" else msgbox "You selected: " & mycell.address(external:=true) end if CLR wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 -- Dave Peterson -- Dave Peterson -- Dave Peterson |
#9
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Something ate my I.
Ouch!!!!!!!! Dave Peterson wrote: When BillG, WarrenB and go out, I always pick up the tab! CLR wrote: I guess that's why you get the Big Bucks, Dave <g Thanks most kindly, Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... I hope that there are other choices--or what the heck was MS thinking when starting with type:=8. <vbg Type:=8 means that you want to return a range. If you search VBA's help for inputbox method (not inputbox function), you'll see: Type Optional Variant. Specifies the return data type. If this argument is omitted, the dialog box returns text. Can be one or a sum of the following values. Value Meaning 0 A formula 1 A number 2 Text (a string) 4 A logical value (True or False) 8 A cell reference, as a Range object 16 An error value, such as #N/A 64 An array of values You can use the sum of the allowable values for Type. For example, for an input box that can accept both text and numbers, set Type to 1 + 2. CLR wrote: Got it Dave, and it does me fine...........thank you most kindly....... BTW.......what does the Type:=8 mean, and are there other choices? Vaya con Dios, Chuck, CABGx3 "Dave Peterson" wrote in message ... Dim myCell as range set mycell = nothing on error resume next 'cancel will cause an error set mycell = application.inputbox(Prompt:="select a cell", type:=8).cells(1) on error goto 0 if mycell is nothing then msgbox "You didn't select a cell!" else msgbox "You selected: " & mycell.address(external:=true) end if CLR wrote: Hi all......... I would like to select a sheet (no problem there),............ then I would like a msgbox to pop up telling the user to select a cell (no problem there),.......... then I would like for the macro to pause until the user to selects a cell.......and then for the macro to continue to run using that cell as the selection. TIA Vaya con Dios, Chuck, CABGx3 -- Dave Peterson -- Dave Peterson -- Dave Peterson -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Prompt user to select a printer using a checkbox within a user | Excel Programming | |||
how do I prompt the user to select a cell? | Excel Programming | |||
Allowing user to select a cell in another workbook in VBA | Excel Programming | |||
Not allow user to select a locked cell | Excel Programming | |||
User select row? | Excel Programming |