Solved

Lotus Notes

Posted on 2000-04-11
5
1,008 Views
Last Modified: 2013-12-18
I created a form in Lotus Notes, and I wanted to make one field "mandatory".  This field must be completed, cannot be blank. How do I set up this function?
0
Comment
Question by:keila
[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
  • 2
  • 2
5 Comments
 
LVL 2

Expert Comment

by:mchampou
ID: 2703771
You have a few options. By far the easiest is to use the the "Input Validation" event of the field you need validated.

In there you could do the following

@If ( @Trim (FIELD_NAME) = "" ; @Failure ("Please enter a value in the field FIELD_DESCRIPTION") ; @Success)

Try it out ...
0
 

Author Comment

by:keila
ID: 2704679
Mchampou I tried the function you've described, but it is not exactly what I wanted.  
I want to block the users to go to the next field if they don't fill in the "mandatory" field I've determined.
The way you described the function, the field will have a message, but the users still can pass through to the next field.
I appreciate your help.
Thanks
0
 
LVL 1

Accepted Solution

by:
asselin earned 50 total points
ID: 2705079
Put this code in the Exiting event of all mandatory fields and replace the field name with yours:

Sub Exiting(Source As Field)
     
     Dim workspace As New NotesUIWorkspace
     Dim uidoc As NotesUIDocument
     Dim doc As NotesDocument
     
     Set uidoc = workspace.currentdocument
     Set doc = uidoc.document
     
     If doc.MandatoryField(0) = "" Then
          Msgbox "Mandatory field"
          Call uidoc.gotofield("MandatoryField")
     End If
     
End Sub
0
 
LVL 2

Expert Comment

by:mchampou
ID: 2705612
You might want to change the line

if doc.MandatoryField(0) = "" Then

to this ...

if trim(doc.MandatoryField(0)) = "" then

that way the user will really need to enter something in there (not just spaces like one of mine did ;-)

Have a good day,

Mchampou
0
 

Author Comment

by:keila
ID: 2711643
Thanks for helping me!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

For users on the Lotus Notes 8 Standard client, this article provides information on checking the Java Heap size and adjusting it to half of your system RAM in attempt to get the Lotus Notes 8.x Standard client to run faster.  I've had to exercise t…
For beginners of Lotus Notes user this is important to know about the types of files and their location supported by IBM Notes. Mostly users are unaware about how many file types are created and what their usages are. This Article is fully dedicated…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

740 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