jfcby Posted July 1, 2009 Share Posted July 1, 2009 Hi, I've been searching this forum and the help file looking for a way to create a combobox with multi columns loaded from a text file. My txt file data will look like this: Id1 Full Name 1 Id2 Full Name 2 Id3 Full Name 3 The ids and full names will not be the same character length. When the combobox selection is made I will only need the Id to be inserted into an IE form and the full name is for reference only. The examples I found in the help file and in this forum are single column only. Thank you for your help, jfcby Determined -- Devoted -- Delivered Make your mind up -- to seriously apply yourself -- accomplishing the desired results. **** A soft answer turneth away wrath: but grievous words stir up anger. Proverbs 15:1 KJB **** Link to comment Share on other sites More sharing options...
exodius Posted July 1, 2009 Share Posted July 1, 2009 (edited) I guess I don't understand what you mean by "columns" in a combobox... Since comboboxes don't have columns? This is about the closest thing I could fathom to what you want: #include <GUIConstantsEx.au3> Opt ("GuiOnEventMode", 1) Global $combo GUICreate("My GUI combo") GUISetOnEvent($GUI_EVENT_CLOSE, "_GUI_EVENT_CLOSE") $combo = GUICtrlCreateCombo("Id1", 10, 10) GUICtrlSetOnEvent (-1, "_ComboFunc") GUICtrlSetData(-1, "Id2|Id3") GUISetState() While 1 Sleep (50) WEnd Func _ComboFunc() Switch GUICtrlRead ($combo) Case "Id1" MsgBox (0, "Id1", "Full Name 1") Case "Id2" MsgBox (0, "Id2", "Full Name 2") Case "Id3" MsgBox (0, "Id3", "Full Name 3") EndSwitch EndFunc Func _GUI_EVENT_CLOSE() Exit EndFunc Edited July 1, 2009 by exodius Link to comment Share on other sites More sharing options...
PsaltyDS Posted July 1, 2009 Share Posted July 1, 2009 Perhaps you mean to use a ListView control, vice a ComboBox? Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
TalivanIBM Posted December 2, 2009 Share Posted December 2, 2009 I think they say this, a listview vice a combobox, i was searching this too, but not 2 controls, a style for combobox that can able columns in the list of the combobox, like groups in listview (it's an user function) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now