Re: Closing form Problem

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



If you set the MinimizeBox property of the form to false, it will always
have an OK button instead of the X.


<savvaschr@xxxxxxxxxxxxxxxx> wrote in message
news:1132224605.437243.120680@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Hello
> I would like to ask what is the "correct" way to show and then to
> close a form.
>
> In my application some forms I show them with the .show event and
> other
> with the .ShowDialog .. but if the user press the X button on the form
> the form is not
> closing and I ve try to put a breakpoint in the closing event but the
> event dont rise when the X button is clicked.
> The only way i found is to put a button on the screen and in the click
> event of the button execute me.close, but i dont want to put an extra
> button in each form, and i dont know how to prevent a user from
> clicking the X button of the screen.
>
> So what can i do??
> Shall i display the forms as .Showdialog and close them on the
> .ondeactivate event?
> Or is there another way of closing them.
> Thanks a lot
> Savvas
>


.



Relevant Pages

  • Closing form Problem
    ... but if the user press the X button on the form ... closing and I ve try to put a breakpoint in the closing event but the ... event dont rise when the X button is clicked. ... Shall i display the forms as .Showdialog and close them on the ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: If then else
    ... so they dont have the option of closing out without saving. ... Dim WSN As Variant ...
    (microsoft.public.excel.programming)
  • Re: Tooltips only work once on form
    ... still fail. ... "Steve Cutting" wrote in message ... The form is opened using .showdialog from another form. ... > Closing via dialogresult.OK/cancel or close button. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: OT:: They have taken away my favorite planet!!
    ... to take my cousin there next week...i dont think england has anything ... quite like it(if its still open that is...they have been closing down ...
    (alt.med.fibromyalgia)
  • Solution for the error message when closing Word 2007 with HP multifonction
    ... message error says that the ModName: hpz3ra.dll or similar dll are in fault. ... Office 2007 SP1 dont too) now is to uncheck the multifonction as the default ... error message when closing Word 2007 after that. ...
    (microsoft.public.word.application.errors)