[Gambas-user] How to add a command output to the combo box list?
Joshua Higgins
joshiggins at ...1601...
Tue Mar 31 20:16:50 CEST 2009
I think you'd need to
DIM interfaceoutput AS String
SHELL "ifconfig blah blah" to interfaceoutput
Then you'll need to split it - is it space or return separated?
E.g. (return separated)
allinterfaces = Split(interfaceoutput, "\n")
"allinterfaces" is an array that now contains all the interfaces. To add
them to the combobox, its as simple as:
For each interface in allinterfaces
Comobox1.Add(interface)
Next
** The only problem being is that command you have will probably need some
backslashes in for it to be passed to shell properly.
HTH
--
joshua higgins
>>>>>>------
More information about the User
mailing list