How to: Load Combobox from sql "select" command

Got a problem you cannot solve? Try here.
Post Reply
leos58
Posts: 10
Joined: Tue Jul 12, 2011 8:00 am

How to: Load Combobox from sql "select" command

Post by leos58 »

Hi,
I've a problem with the loading of a combobox in a dialog installaware.
My problem is that I tried to load the item of the combo with the result of a select command sql.
I tried to use the installaware command "MS SQL Server" in this mode:

~InstallAware Clipboard Data~
~MS SQL Server~
~{7B3760E7-D729-4032-AC09-EC59E8CF08A4}~
~$SERVER$,$ISTANCE$,$DB$,$USER$,$PWD$,EDS,"SELECT [Field] FROM [Dbl].[dbo].[Table]$NEWLINE$GO",0,0~
~mMSSQLIDE.dll\mMSSQLExec.dll~

And then I've modified the items property of combo with $EDS$.
But the result of the variables is "SUCCESS" and not the result of the select command.
WHY?
Any help will be appreciated.Thanks.
Bye
giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: How to: Load Combobox from sql "select" command

Post by giaviv »

Hi,

The SQL command does not return SQL values - it just executes the script and returns whether or not it succeeded.
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
leos58
Posts: 10
Joined: Tue Jul 12, 2011 8:00 am

Re: How to: Load Combobox from sql "select" command

Post by leos58 »

Thanks for your reply.
I imagined that It wasn't possible but i wanted be sure.
But is there any alternative to load a combo dinamically or not???
Thanks again.
Bye
giaviv
Posts: 2039
Joined: Fri Dec 17, 2010 1:39 pm

Re: How to: Load Combobox from sql "select" command

Post by giaviv »

You can definitely load a combo dynamically - just make sure you separate the values with NEWLINE, like so:

Item1$NEWLINE$Item2$NEWLINE$Item3
Aviv Giladi
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
Post Reply