|
From: Cloud S. <tha...@ho...> - 2008-04-26 02:09:03
|
dwinkjr wrote:
>
> ok I am new to the whole Win32::Gui stuff.. But here is my problem. I am
> trying to load a combobox with ODBC datasources. The problem I am having
> is that the combobox is a child. I cant seem to address it correctly.
> Here is my code.
> my $GB3 = Win32::GUI::Groupbox->new($Win,
> -text => "Database Parameters:",
> -name => "GroupBox_3",
> -left => 12,
> -top => 151,
> -width => 349,
> -height => 174,
> );
> my $CB= $Win->AddCombobox(
> -name => "CBox1",
> -dropdown => 0,
> -left => 5,
> -top => 41,
> -width => 93,
> -height => 400,
> -parent => $GB3,
> );
> my %DataSources = Win32::ODBC::DataSources();
> foreach $DSNo ( keys( %DataSources ) )
> {
> my %Config = Win32::ODBC::GetDSN( $DSNo );
> $Win->CBox1->Add($DSNo);
> }
>
> $Win->CBox1->SetCurSel(0);
>
> Can someone help me out here?
> Thanks in advance.
> Dave W.
>
Try $CB->Add($DSNo) instead $Win->CBox1->Add($DSNo);
--
View this message in context: http://www.nabble.com/Access-control-in-a-child-tp16732261p16908542.html
Sent from the perl-win32-gui-users mailing list archive at Nabble.com.
|