Welcome to Dream.In.Code
Getting C++ Help is Easy!

Join 136,568 C++ Programmers for FREE! Get instant access to thousands of C++ experts, tutorials, code snippets, and more! There are 1,900 people online right now. Registration is fast and FREE... Join Now!




Get Selected Value of COMBOBOX

 
Reply to this topicStart new topic

Get Selected Value of COMBOBOX

OppLa
10 Apr, 2008 - 08:12 PM
Post #1

New D.I.C Head
*

Joined: 10 Apr, 2008
Posts: 2

Dear Bros,

CODE
case WM_INITDIALOG:
            /*
             * TODO: Add code to initialize the dialog.
             */
            SendMessage(GetDlgItem(hwndDlg,IDC_ITEM),CB_INSERTSTRING,0,(LPARAM)(LPCTSTR)"Pipe ABC");
            SendMessage(GetDlgItem(hwndDlg,IDC_ITEM),CB_INSERTSTRING,1,(LPARAM)(LPCTSTR)"Pipe DEF");
            
        return TRUE;


in this below section:

CODE
case IDD_GEN:
                {
..................
}
break;

how can I get the Selected Value of Combobox.

Example:
- In Combobox if I choose: "ABC", It will show " heheheheh"
- in Combobox if I choose: "DEF", It will show "HAHAHAHA"

Thank you very much for your help.

OppLa


This post has been edited by OppLa: 10 Apr, 2008 - 08:13 PM
User is offlineProfile CardPM
+Quote Post

jeronimo0d0a
RE: Get Selected Value Of COMBOBOX
11 Apr, 2008 - 06:37 AM
Post #2

D.I.C Head
**

Joined: 3 Mar, 2008
Posts: 141


My Contributions
If you have studio, read the help on combobox, there's an example there, but it's a little large to paste here.
User is offlineProfile CardPM
+Quote Post

OppLa
RE: Get Selected Value Of COMBOBOX
12 Apr, 2008 - 12:47 AM
Post #3

New D.I.C Head
*

Joined: 10 Apr, 2008
Posts: 2

I did not use visual, just pure C.

Thnk

OppLa
User is offlineProfile CardPM
+Quote Post

Reply to this topicStart new topic
Time is now: 12/2/08 11:53PM

Live C++ Help!

C++ Tutorials

Reference Sheets

C++ Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month