?
Solved

Form unload

Posted on 2002-04-11
4
Medium Priority
?
193 Views
Last Modified: 2010-05-02
Hello

  in forload even i am checkin the values in the form if not satisfied then message box will be given and form will be unloaded . so how can i do that?
THanks,
shri
0
Comment
Question by:shrihalbe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 6934847
you need to manage queryunload event instead, check the required values, show msgbox if you need and set cancel to false to not unload form.
0
 
LVL 1

Expert Comment

by:soferstam
ID: 6934902
MsgBox "..."
Unload Me
???
0
 
LVL 1

Accepted Solution

by:
TechJD earned 80 total points
ID: 6942591
dim msg as string
if var <> setvalue then
msg = msgbox("your message",0,"title")
unload me
else
end if
0
 

Author Comment

by:shrihalbe
ID: 6942665
thanks,
shri
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question