This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal


Mar 13, 2015, 12:01 PM
6 Posts

Dialog List

  • Category: Application Development
  • Platform: Windows
  • Release: 9.0.1
  • Role: Developer
  • Tags: Dialog List Selection
  • Replies: 10

Hi all,

I am involved in a task where I have to decide if to use the Notes Client as a replacement for Lotus Approch. There are some applications that use Approach as a front end to the user and an SQL Database. Most of the scripts could be used in Notes (especially the sql interface and the internal logic), but the front end is quite different.

Actually I am looking for a solution to the following problem:

The script creates an array with customer names, adresses and a pointer to the customer record in the database (1 line per customer). This array should then be presented in a  dialog box where the user then selects a line with double click for further processing.

In Approach this is a quite simple task: just filling a listbox, the selection is shown as an index to the array.

I was searching and trying now for days in Notes and got a bit confused. I have learned that a listbox filed basically does what I want, but so far I was not successful with that task.

I would be very grateful if some kind soul could post a working example.

Thank you

Paul

Mar 13, 2015, 8:48 PM
10 Posts
Lotus Application Development - ListBox
Working with a blank Lotus database is easy.
You may want to open a PMR with our Application Development team for complex questions.

You can create a ListBox using LotusScript.
Use the Lotus Designer client to create database design elements.

Here are some free training documents :

Title:        LotusScript Self-Help Training Module 1 - 'Using LotusScript within a custom application'
Doc #:        7010056
URL:        
http://www.ibm.com/support/docview.wss?uid=swg27010056

Title:        LotusScript Self-Help Training Module 2: 'How to write a simple back-end LotusScript agent'
Doc #:        7010431
URL:        
http://www.ibm.com/support/docview.wss?uid=swg27010431
Mar 14, 2015, 7:15 AM
6 Posts
Dialog List - Prompt

@ Bob:

Thank you very much. This is exactly what I was looking for.

Additional question: Is there a change to use a fixed size font for the box?

BTW: This is the first really valuable hint! I was searching for a solution for more than 2 weeks, the combination with a hidden field as source and a listbox field did not work.

Thanks

Paul

 

Mar 14, 2015, 5:29 PM
6 Posts
Listbox - refresh

Although NotesUIWorkspace Prompt basically does what I want, I am still trying to find a solution with a listbox field.

This is the status now:

Within the form named "Kundenauswahl" I have defined 2 fields:

- "Auswahl": hidden multivalue text field

- "Kundenliste": listbox field, computed from "Auswahl", both refresh-checks on

This is the script that shows that form:

    Dim newdoc As NotesUIDocument
    Set newdoc = ws.ComposeDocument ( , , "Kundenauswahl" )
    Call newdoc.Document.ReplaceItemValue( "Auswahl" ,Kdn_Tab)
    Call newdoc.Document.ReplaceItemValue( "Kundenliste" ,"")
    Call newdoc.refresh

On the display the field "Kundenliste" is empty, although the data is there. I can see that when I use the debugger.  By newdoc.refresh it gets refreshed in core but not on the display.

Has someone encoutered this situation?

Paul

Mar 16, 2015, 8:39 AM
30 Posts
You might want to use

reload, not refresh

c.f.

This method is valid only when the document is in Edit mode.

This method reloads the back-end document associtated with the editing session, which can be acquired through the Document property. It does not reload the base back-end document saved on disk. You must close and reopen the document to reload the base back-end document.

This method is useful only when the AutoReload property is False. By default this property is True and modifications to the back-end document appear immediately in the front-end. Where reloading on every modification is slow, you might set the AutoReload property to False, make the modifications, and call Reload.

Rich text items are an exception. Modifications made to rich-text items in the back-end document do not appear in the front-end until the document is closed and reopened.

Modifications made to the back-end document outside the current editing session (for example, by an agent or another user) do not appear until the document is closed and reopened.

You can close and reopen a front-end document with NotesUIDocument.Close(True) and NotesUIWorkspace.EditDocument.

Mar 16, 2015, 5:23 PM
6 Posts
Listbox - display vs core

@ Christoper

Thank you for your suggestion. I tried several ways: creating a background document, load in the foreground; saving, reloading the uidocument. It always comes down to the same result: the field is created in core, but empty on display. I think it has something to do with the definition of the listbox. I also tried several combinations - always the same.

Mar 17, 2015, 4:26 PM
6 Posts
Listbox - solved

OK, I found the solution:

I wrongly defined the listbox as computed instead of editable. Now it works. The only difference to the listbox in Approach is the fact that OnClick and DblClick are not triggered for Lotusscript on the client.

Tank you all!

Paul

Mar 17, 2015, 7:43 PM
82 Posts
onChange ...
See info here Linkfor getting your listbox to fire onChange code
Mar 22, 2015, 7:45 PM
82 Posts
here is the text from the link
 I think what you are looking for is 2 things:

1. the onChange event for the first checkbox (listbox)Field

2. the 'Run Exiting/OnChange events after value change' property of a checkbox (listbox) field (found on the 3rd tab counting left to right of the Field infobox)


By selecting the Field property mentioned in 2. above, it will immediately trigger any onChange code as soon as you click (change) the checkbox
(listbox)

This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal