Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Call fscommand with combo box

Status
Not open for further replies.

jimborama

Technical User
Feb 24, 2003
5
US
Can this be done? I've tried everything I can think of, but can only call geturl with the combo box. I would like to call fscommand "exec".

////This works////////////////////////

function fun() {
getURL(comboBox.getSelectedItem().data, "_blank");
}

/////////////////////////////////////

////This (among others) doesn't//////

function fun() {
fscommand(comboBox.getSelectedItem().data, "exec");
}

////////////////////////////////////

Thanks Tek-tipsters
 
Is this for a projector file?



Regards,

cubalibre2.gif
 
Sorry....my bad.
This is a projector file project for cd-rom.
 
So, what do you want to do exactly with fscommand "exec" in a combobox?
You are aware that new restrictions apply with the fscommand's "exec" call (a fscommand subfolder among other things), as explained here:


Outside of that, there should be no problem using that fscommand in the Change Handler function of any combobox.



Regards,

cubalibre2.gif
 
Yes, everything is in it's rightful place, and all is well with the app. No problem launching exes, word files, pdf's, or anything else from buttons, frames, or anywhere else. It's just this one piece of code that, as Jimmy Buffett says, "plum eludes me."

Think I need a Margarita.
 
function my_function() {
if (myCombo.getValue() == 1){
fscommand("exec", "my_bat1.bat");
}
if (myCombo.getValue() == 2){
fscommand("exec", "my_exe.exe");
}
}
stop();

//Change Handler in the combo: my_function

Regards,

cubalibre2.gif
 
thanks oldnewbie....not there yet, but this paved the way to something that might work. I'll post it when I get it working.
 
This is the one that worked

////////////////////////////////////////////

function mycombo() {
fscommand("exec",comboBox.getSelectedItem().data);
}

////////////////////////////////////////////

of course the executable must be referenced in the data table.....
Thanks again for all your help........
Off to see the lizard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top