Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to force userform to display everything?
If I do the following...
with userform1 .textbox1.value = "Some text to display" .show (modal) end with The form displays but the text box doesn't show. It's as if the form had no controls. However, if I add a msgbox command... with userform1 .textbox1.value = "Some text to display" .show (modal) msgbox "Press OK to continue.." end with The modal form displays correctly. How can I get the modal form to do what I want without having to wait for input, which defeats the whole purpose of using a modal form to pass information? Regards, John M |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to force userform to display everything?
John,
I can't reproduce, so just a guess - maybe Repaint would force it: With UserForm1 .TextBox1.Value = "Some text to display" .Show (modal) .Repaint End With hth, Doug Glancy "John Mitchell" wrote in message ... If I do the following... with userform1 .textbox1.value = "Some text to display" .show (modal) end with The form displays but the text box doesn't show. It's as if the form had no controls. However, if I add a msgbox command... with userform1 .textbox1.value = "Some text to display" .show (modal) msgbox "Press OK to continue.." end with The modal form displays correctly. How can I get the modal form to do what I want without having to wait for input, which defeats the whole purpose of using a modal form to pass information? Regards, John M |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to force userform to display everything?
Doug
Thanks. That did the trick. Regards, John M Doug Glancy wrote: John, I can't reproduce, so just a guess - maybe Repaint would force it: With UserForm1 .TextBox1.Value = "Some text to display" .Show (modal) .Repaint End With hth, Doug Glancy "John Mitchell" wrote in message ... If I do the following... with userform1 .textbox1.value = "Some text to display" .show (modal) end with The form displays but the text box doesn't show. It's as if the form had no controls. However, if I add a msgbox command... with userform1 .textbox1.value = "Some text to display" .show (modal) msgbox "Press OK to continue.." end with The modal form displays correctly. How can I get the modal form to do what I want without having to wait for input, which defeats the whole purpose of using a modal form to pass information? Regards, John M |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to force userform to display everything?
Note that you are showing your userform as a Modeless userform (not modal as
you claim). Modal would mean that it retains the focus until dropped. (modal) is not a constant and resolves to 0 as you use it. Zero is the value of the defined constant vbModeless ? vbModeless 0 The constant for modal is ? vbModal 1 It usually helps to use correct terminology. -- Regards, Tom Ogilvy "John Mitchell" wrote in message ... Doug Thanks. That did the trick. Regards, John M Doug Glancy wrote: John, I can't reproduce, so just a guess - maybe Repaint would force it: With UserForm1 .TextBox1.Value = "Some text to display" .Show (modal) .Repaint End With hth, Doug Glancy "John Mitchell" wrote in message ... If I do the following... with userform1 .textbox1.value = "Some text to display" .show (modal) end with The form displays but the text box doesn't show. It's as if the form had no controls. However, if I add a msgbox command... with userform1 .textbox1.value = "Some text to display" .show (modal) msgbox "Press OK to continue.." end with The modal form displays correctly. How can I get the modal form to do what I want without having to wait for input, which defeats the whole purpose of using a modal form to pass information? Regards, John M |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
display userform | Excel Discussion (Misc queries) | |||
UserForm: force to update controlsources | Excel Programming | |||
How to cause userform to display | Excel Programming | |||
How? Force Sheet1 to display each time the workbook is opened. | Excel Programming | |||
Must be a way to force focus back to sheet instead of UserForm - isn't there? | Excel Programming |