Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

InputQuery Message Box List

Posted on 1998-09-07
3
Medium Priority
?
300 Views
Last Modified: 2010-04-06
I am trying to have a message dialog query input box with a list of items to pick from, the follow code allows only one line to be displayed, cannot find out how to have a list.

begin
  dbisamtable1.CheckBrowseMode;//post all
  InputString := 'LIST'+#13#10+'PROSPECT';
  ClickedOK := InputQuery('Insert Record Category Select','Enter Category',InputString);
   if ClickedOK then
    dbisamtable1.Insert;
    dbisamtable1category.value := InputString;
   end;

Thank you.

Cordially,

JAlexander
vtcmain@pacbell.net
0
Comment
Question by:vtcmain
[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
3 Comments
 
LVL 3

Expert Comment

by:Matvey
ID: 1338884
InputQuery doesn't support any lists, combos - just a caption and an edit. If you want to make a sophisticated dialog, you have to put all you want on a new form, and then ShowModal it. You should put some buttons and make them to be Cancel, OK, etc. Use the ModalResult property of the buttons for that.
0
 
LVL 2

Accepted Solution

by:
kjteng earned 200 total points
ID: 1338885
You cannot use inputQuery to select a list of item. Try this:
1. Create a dialog box (a new form, let's call it dlgbox1)
2. Drop a listbox or combobox to the dlgbox1
3. Key in the possible values in the items property of listbox/combox
4. ADD THESE CODES IN YOUR MAIN FORM:
    dlgbox1.ShowModal;
    if dlgbox1.ModalResult = mrOK then
      { do whatever intended}

5. Alternatively, you may just create an onclick event for the OKbutton in dlgbox1 and do whatever you wish in the event hanlder
0
 
LVL 3

Expert Comment

by:Matvey
ID: 1338886
Ghm...
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
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

722 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