ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Dialog boxes (https://www.excelbanter.com/excel-discussion-misc-queries/34557-dialog-boxes.html)

webster

Dialog boxes
 
I want to have a dialog box pop up when I open an excel workbook. I just
want it to say something like 'enter name in cell A6" and then have an "OK"
button that closes the pop up.

Any assistance would be appreciated

Harald Staff

Hi

Open the VB editor (Alt F11 or similar).
Menu Insert Module.
Paste this into the module:

Sub Auto_open()
MsgBox "enter name in cell A6", vbOKOnly, _
"Any assistance would be appreciated"
Range("A6").Select
End Sub

Save, close, reopen.

HTH. Best wishes Harald

"webster" skrev i melding
...
I want to have a dialog box pop up when I open an excel workbook. I just
want it to say something like 'enter name in cell A6" and then have an

"OK"
button that closes the pop up.

Any assistance would be appreciated




VoG via OfficeKB.com

Sub Auto_Open()
msgbox "Enter name in cell A6"
End Sub


--
Message posted via http://www.officekb.com

webster

Thanks Harald it works a treat.

Is it possible to have a number of lines in the msgbox such as
1. Enter name in A6
2. Enter D.O.B in A7
3. Enter Gender in A8

Paul


"Harald Staff" wrote:

Hi

Open the VB editor (Alt F11 or similar).
Menu Insert Module.
Paste this into the module:

Sub Auto_open()
MsgBox "enter name in cell A6", vbOKOnly, _
"Any assistance would be appreciated"
Range("A6").Select
End Sub

Save, close, reopen.

HTH. Best wishes Harald

"webster" skrev i melding
...
I want to have a dialog box pop up when I open an excel workbook. I just
want it to say something like 'enter name in cell A6" and then have an

"OK"
button that closes the pop up.

Any assistance would be appreciated





Bob Phillips

Sub Auto_open()
MsgBox "Enter name in A6" & vbNewLine & _
"Enter D.O.B in A7" & vbNewLine & _
"Enter Gender in A8", & _
vbOKOnly, "Any assistance would be appreciated"
Range("A6").Select
End Sub


--
HTH

Bob Phillips

"webster" wrote in message
...
Thanks Harald it works a treat.

Is it possible to have a number of lines in the msgbox such as
1. Enter name in A6
2. Enter D.O.B in A7
3. Enter Gender in A8

Paul


"Harald Staff" wrote:

Hi

Open the VB editor (Alt F11 or similar).
Menu Insert Module.
Paste this into the module:

Sub Auto_open()
MsgBox "enter name in cell A6", vbOKOnly, _
"Any assistance would be appreciated"
Range("A6").Select
End Sub

Save, close, reopen.

HTH. Best wishes Harald

"webster" skrev i melding
...
I want to have a dialog box pop up when I open an excel workbook. I

just
want it to say something like 'enter name in cell A6" and then have an

"OK"
button that closes the pop up.

Any assistance would be appreciated







webster

Thanks Bob - your help is much appreciated.

Paul

"Bob Phillips" wrote:

Sub Auto_open()
MsgBox "Enter name in A6" & vbNewLine & _
"Enter D.O.B in A7" & vbNewLine & _
"Enter Gender in A8", & _
vbOKOnly, "Any assistance would be appreciated"
Range("A6").Select
End Sub


--
HTH

Bob Phillips

"webster" wrote in message
...
Thanks Harald it works a treat.

Is it possible to have a number of lines in the msgbox such as
1. Enter name in A6
2. Enter D.O.B in A7
3. Enter Gender in A8

Paul


"Harald Staff" wrote:

Hi

Open the VB editor (Alt F11 or similar).
Menu Insert Module.
Paste this into the module:

Sub Auto_open()
MsgBox "enter name in cell A6", vbOKOnly, _
"Any assistance would be appreciated"
Range("A6").Select
End Sub

Save, close, reopen.

HTH. Best wishes Harald

"webster" skrev i melding
...
I want to have a dialog box pop up when I open an excel workbook. I

just
want it to say something like 'enter name in cell A6" and then have an
"OK"
button that closes the pop up.

Any assistance would be appreciated








All times are GMT +1. The time now is 12:00 PM.

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