@Prompt in script for record display

Hello.I hope someone can assist me. I need to display a pop-up window when a user exits a field in a form. This windows should display a view in the database that contains only records select by a key value. I am not sure what the best method is to accomplish this. Any help would be great.

Subject: @Prompt in script for record display

Robert,

Here are some places to start. I’m assuming you will do this in Lotusscript - it can be done in formula, but script gives you much better control.

  1. look at the ‘exiting’ event of the field to trigger the display of your dialog

  2. look at the ‘dialogbox’ method to present the pop-up to the user

  3. you can use either a single-category view, or @setviewinfo to limit the display of the view in the popup.

Searching in the forum will give you many examples to learn from. Good luck!

Subject: RE: @Prompt in script for record display

Subject: RE: @Prompt in script for record display

Thank you for your response Stuart.

Yes I will be doing this in Lotus Script from an Exiting sub for a field. I figured that ‘dialogbox’ method would be the way to go , however I am have a hard time finding out any information related to single-category view and looking up categorywith a key.

Bottom line is I need to lookup information by a key value and pop it up in a ‘dialogbox’ . If you know of any examples of this that you could point me to it would be great.

Bob

Subject: RE: @Prompt in script for record display

Bob,

Start by building a new form that will be presented to the user in the dialogbox. Also, make sure you have a view built that will be presented in the form - it should be categorized by your key field. Use a table in the form to group everything in the form. Then embed the view in the appropriate place in the table on the form. For information on making it single-category, look at the topic ‘to show a single category in embedded views’ in Designer Help. You will also need to have the key field on your dialog form someplace (either hidden or not) so that Notes knows what category to display.

It all comes together when you call the dialogbox method, specifying your new form as the form to display. Set the ‘sizetotable’ argument to ‘true’ to make everything look nice.

Hope this helps.

Subject: RE: @Prompt in script for record display

Stuart ,Thanks again it worked great. One last question. Is it possible to click an entry in the embedded view dialog box and open that document. It does not appear to be the case. Not a biggie if it can be done . It would just be convenient.

Subject: RE: @Prompt in script for record display

hmmm…I don’t think I’ve ever done that in an app, so I can’t say for sure. Dialog boxes are ‘modal’ - you can’t do anything else in Notes until the box is closed, so perhaps that is the problem.

But there is (almost) always a creative way to solve a problem like this in Notes. Search the forum and see if anyone has any good suggestions.

good luck!

Subject: RE: @Prompt in script for record display

I will try this and let you know how it goes. Thanks for taking the time to assist me. Happy Holidays