Solved

Displays a dialog box containing multiple input fields..

Posted on 2013-05-24
6
2,039 Views
Last Modified: 2013-05-24
in Delphi XE4 iOS Firemonkey mobile Application I need to show a dialog box with multiple input fields, here is my code, it always shows the dialog box with ONE input field

const
     S : array [1..2] of string = ('ContactName' , 'ContactNumber');
var
     V : Array [1..2] of string;
begin
     if InputQuery('Contact Details', S, V, nil) then
     begin
          // Do something ...
     end;
end;

Open in new window



I tried also

if InputQuery('Contact Details', S, V) then {removed the last parameter}

Open in new window


I got same result.

any Ideas?

Thanks in advance.
0
Comment
Question by:i7m
  • 3
  • 3
6 Comments
 
LVL 26

Expert Comment

by:Sinisa Vuk
ID: 39194212
Try this one:
var
  Vars : array of String;
begin
  SetLength(Vars,2);
  //default
  Vars[0] := '';
  Vars[1] := '';

  if InputQuery('Contact Details', ['ContactName' , 'ContactNumber'], Vars, nil) then
  begin
    ....

Open in new window


http://docwiki.embarcadero.com/Libraries/XE2/en/Vcl.Dialogs.InputQuery
Think that string array must start from 0 index (Array [0..1] of...)
0
 

Author Comment

by:i7m
ID: 39194242
Tried and got same result.

It displayed the the array item [1] only
0
 
LVL 26

Expert Comment

by:Sinisa Vuk
ID: 39194318
Is this code works on Win platform? Could be Firemonkey issue.
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 

Author Comment

by:i7m
ID: 39194393
Yes Works Okay on Win32 Platform
Untitled.png
0
 
LVL 26

Accepted Solution

by:
Sinisa Vuk earned 500 total points
ID: 39194488
Then must be Firemonkey issue on iOS platform. Maybe you can ask on Embarcadero forum.
0
 

Author Comment

by:i7m
ID: 39195180
I posted it as a bug on Embarcader's Quality Center. and waiting their. Thanks for your help.
0

Featured Post

Does Powershell have you tied up in knots?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Wininet read php file from internet issue 6 91
Machine not responding during CopyFile() 3 98
Delphi TcxGrid group footer summary 3 273
Delphi: Connect to running MS Outlook 4 87
A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

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