Solved

LISTBOX in script

Posted on 2004-09-06
5
493 Views
Last Modified: 2013-12-18
I want to create a list of items for selection by the user(eg: Select a field name:(list of field name)). User has to select the filed name from the list.

Can you suggest me what to use either PICKLIST or PROMPT[OKCANCELLIST].If so can you tell me how to use?

Thanks in advance
Purushoth
0
Comment
Question by:priyapurushoth
  • 3
  • 2
5 Comments
 
LVL 46

Expert Comment

by:Sjef Bosman
ID: 11988341
And you want it to be a popup-box, and not just a list-field on the form itself? @Picklist is meant to be used to select one or more documents from a view, so that won't work. The @Prompt might be the right way.
0
 

Author Comment

by:priyapurushoth
ID: 11988344
Ok , but what is the exact way of implementation in scripts? Because I tried few syntax and its not working
0
 
LVL 46

Expert Comment

by:Sjef Bosman
ID: 11988843
What did you try? And in what context, e.g. on a form, in a Button, in a Hotspot, in an Action? So code and explanation please...
0
 

Author Comment

by:priyapurushoth
ID: 11989592
I have used in Action and I have used like this
Dim strField as Variant

strField = workspace.Prompt(PROMPT_OKCANCELLIST, "SetField", "Choose the Field Name:","Form:Status:Fax")  where the fields are Form,Status and Fax.

I am not sure if this is right. Correct me if I am wrong in Syntax.
0
 
LVL 46

Accepted Solution

by:
Sjef Bosman earned 20 total points
ID: 11989869
Some mistakes:
    dim values(2) as string
    values(0)= "Form"
    values(1)= "Status"
    values(2)= "Fax"
    strField = workspace.Prompt(PROMPT_OKCANCELLIST, "SetField", "Choose the Field Name:","",values)
and you must show the empty default value, the comma cannot be omitted.

If you want to use the constant PROMPT_OKCANCELLIST, then you MUST also use %Include "Lsconst.lss". If you haven't specified Option Declare or Option Explicit in your options section, Notes will fill in a default value for the constant, namely 0. So either use the include, or specify the constant yourself (or just fill in 4 instead of PROMPT_OKCANCELLIST).

Instead of
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video discusses moving either the default database or any database to a new volume.

707 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now