?
Solved

Lotus Notes

Posted on 2000-04-11
5
Medium Priority
?
1,011 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 200 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

Industry Leaders: 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

You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
Notes Document Link used by IBM Notes is a link file which aids in the sharing of links to documents in email and webpages. The posts describe the importance and steps to create a Lotus Notes NDL file in brief.
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

777 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