CodeMonkey
CodeMonkey

Reputation: 1156

Set ComboBox to ID of another ComboBox

I am currently trying to set a CComboBox* with the ID that is assigned for existing combo box(IDC_COMBO).

I've tried CWnd's GetDlgItem() and ID assignment, but I could not figure it out yet.

I know this isn't exactly the expected details, but this is all I can give you.

Upvotes: 1

Views: 263

Answers (1)

rrirower
rrirower

Reputation: 4590

Is this what you want?

CComboBox* pCombo = reinterpret_cast<CComboBox*>(GetDlgItem (IDC_COMBO));

Upvotes: 3

Related Questions