LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default DIsabling Escape Key while dialog active

Since dialog sheet are persistent in retaining values. set it up like this

Public bFlag As Boolean
Sub showDialog()
bFlag = True
Do While bFlag
DialogSheets(1).Show
Loop
End Sub

Sub Cancel_Button()
' MsgBox "In cancel"
If ActiveDialog.CheckBoxes(1) = xlOff Then
bFlag = False
End If
End Sub

the cancel_button code is assigned to the cancel key.


If you have an init event or if you clear values in your code, use the bflag
value there to see whether to clear or not.

In the above, as long as checkbox 1 is checked, the dialog is reshown.
There is an annoying flicker, but maybe that will disuade use of the escape
key.

--
Regards,
Tom Ogilvy





<Romu wrote in message ...
No - I need it to work ith users still using XL 95. i appreciate that it
can be done in UserForms, but the solution must support xl 95.

Cheers
Romulus
"Harald Staff" wrote in message
...
Ok, the good old DialogSheets ? I doubt that it can be done after a

while
of
researching and testing. You could do it with Userforms though, is that

an
option ?
--
HTH. Best wishes Harald
Followup to newsgroup only please


"Romulus" skrev i melding
...
Thanks Folks

I think I could have been clearer in my original post.
The dialog is displayed and acts as an interface for
users to enter data onto a temporary spreadsheet. when
They're done, they click a button that transfers that
data to a master data file.

I have programmed the dialogs without the top right 'X'
button, but the "Escape" key enables users to dismiss the
dialog, and it is this I want to avoid. Is there a way
to do this?







 
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
Escape key won't work Lee B Excel Discussion (Misc queries) 1 September 3rd 08 05:01 PM
Repost: Disabling Update Links dialog box Sandeep Excel Discussion (Misc queries) 3 July 30th 07 07:51 PM
Disabling Update Links dialog box Sandeep Excel Discussion (Misc queries) 0 July 27th 07 11:28 PM
How to escape this error message jamesa Excel Programming 1 October 3rd 03 05:50 PM
Disabling the enable/disable dialog box with Digital Signature CST[_2_] Excel Programming 1 September 8th 03 08:31 PM


All times are GMT +1. The time now is 08:11 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"