Jump to content
Sign in to follow this  

ComboBox data from domain group - almost there.

Recommended Posts



I'm trying to populate a ComboBox from a domain group.

I can list the group just fine: Line #12 (currently commented out)

But when I try and take that list to the ComboBox, all results show up on the same line.

Never played with ComboBoxes so I would guess that I missing something very obvious to many of you, sadly it's unobvious to me.

Here is what I have so far:

#include <GuiConstantsEx.au3>

Dim $List

$Group = ObjGet("WinNT://" & "domain" & "/" & "group" & ",group")

For $Member in $Group.Members

    $List = $List & $Member.Name & "@domain.com" & @CRLF

;MsgBox(0, "Members...", $List)

GUICreate("Combo Test", 200, 50)
GUICtrlCreateCombo("", 10, 10, 150)
GUICtrlSetData(-1, $List)

While 1
$msg = GUIGetMsg()

    If $msg = $GUI_EVENT_CLOSE Then ExitLoop


Any suggestions?



Edited by mdwerne

Share this post

Link to post
Share on other sites

according to helpfile:


$List = $List & $Member.Name & "@domain.com" & '|'

I saw that in the helpfile and assumed it meant that if I wanted a separator, '|' was the default. I didn't understand that I needed to use it to force separation. :mellow:

As you may have guessed, works perfectly now.

Thank you!


Share this post

Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this