Original Post
Hi Guys, Im trying to use Microsoft's Sample UI that comes with the directx 9c SDK but having a little trouble with the combo box control. When i create a combo box i do this for example: thats all fine and dandy but when i try to get the data back: I get an "C2100: illegal indirection" Error... Any ideas? Cheers all! Mike
int a = 1;
m_Interface.AddComboBox( MZE_VIEWCOMBO, 0, 0, 150, 32 );
m_Interface.GetComboBox( MZE_VIEWCOMBO )->AddItem( L"Maze View", &a );
void CALLBACK OnGUIEvent( UINT nEvent, int nControlID, CDXUTControl* pControl )
{
DXUTComboBoxItem *pItem = NULL
int z;
switch( nControlID )
{
case MZE_VIEWCOMBO:
pItem = ((CDXUTComboBox*)pControl)->GetSelectedItem();
z = (int)*pItem->pData;
break;
}
}