Click here to Skip to main content
15,900,258 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How to stop dropdown of ComboBox? Pin
MikeRT19-Apr-06 23:13
MikeRT19-Apr-06 23:13 
GeneralRe: How to stop dropdown of ComboBox? Pin
toxcct19-Apr-06 22:50
toxcct19-Apr-06 22:50 
GeneralRe: How to stop dropdown of ComboBox? Pin
MikeRT19-Apr-06 23:16
MikeRT19-Apr-06 23:16 
GeneralRe: How to stop dropdown of ComboBox? Pin
David Crow20-Apr-06 3:36
David Crow20-Apr-06 3:36 
GeneralRe: How to stop dropdown of ComboBox? Pin
Eytukan19-Apr-06 22:38
Eytukan19-Apr-06 22:38 
GeneralRe: How to stop dropdown of ComboBox? Pin
MikeRT19-Apr-06 23:07
MikeRT19-Apr-06 23:07 
AnswerRe: How to stop dropdown of ComboBox? Pin
Eytukan20-Apr-06 0:31
Eytukan20-Apr-06 0:31 
AnswerRe: How to stop dropdown of ComboBox? Pin
Eytukan20-Apr-06 0:35
Eytukan20-Apr-06 0:35 
There should be a simple way out , but I couldnt think about it now.
The below may sound silly , but it still works. You can create an EDIT box and make the size same as the Combo. and you can play this trick Wink | ;)

<code>
CComboBox* cmb = (CComboBox*)this->GetDlgItem(IDC_COMBO1);	
CEdit* ce =(CEdit*)this->GetDlgItem(IDC_EDIT1);

void CTESTDlg::OnSetfocusEdit1() 
{
	if(cmb->GetCount()>0)
	{
		cmb->ShowWindow(SW_NORMAL);
		ce->ShowWindow(SW_HIDE);
	}
	
}

void CTESTDlg::OnSetfocusCombo1() 
{

		if((cmb->GetCount()==0))
	{
		cmb->ShowWindow(SW_HIDE);
		ce->ShowWindow(SW_NORMAL);
	}
}
</code>

You like it ? Sniff | :^)




<marquee scrollamount="1" scrolldelay="1" direction="up" height="10" step="1">--[V]--



[My Current Status]

GeneralRe: How to stop dropdown of ComboBox? Pin
MikeRT20-Apr-06 0:46
MikeRT20-Apr-06 0:46 
GeneralRe: How to stop dropdown of ComboBox? Pin
MikeRT20-Apr-06 0:56
MikeRT20-Apr-06 0:56 
GeneralRe: How to stop dropdown of ComboBox? Pin
Eytukan20-Apr-06 20:56
Eytukan20-Apr-06 20:56 
QuestionCreate .lib in .NET 2003 and use in VC6? Pin
Brad K19-Apr-06 19:59
Brad K19-Apr-06 19:59 
AnswerRe: Create .lib in .NET 2003 and use in VC6? Pin
YaronNir19-Apr-06 21:06
YaronNir19-Apr-06 21:06 
Questionwant a new look listctrl help Pin
Sandeep A.C19-Apr-06 19:38
Sandeep A.C19-Apr-06 19:38 
Question Whois Information.... Pin
Mahesh Kulkarni19-Apr-06 19:25
Mahesh Kulkarni19-Apr-06 19:25 
AnswerRe: Whois Information.... Pin
Ganesh_T19-Apr-06 19:40
Ganesh_T19-Apr-06 19:40 
QuestionLots of questions.... Pin
HakunaMatada19-Apr-06 19:22
HakunaMatada19-Apr-06 19:22 
AnswerRe: Lots of questions.... Pin
John R. Shaw19-Apr-06 21:31
John R. Shaw19-Apr-06 21:31 
AnswerRe: Lots of questions.... Pin
YaronNir19-Apr-06 21:36
YaronNir19-Apr-06 21:36 
QuestionHow to ensure registry cleaners don't wipe out your application settings? Pin
chasetoys19-Apr-06 18:04
chasetoys19-Apr-06 18:04 
AnswerRe: How to ensure registry cleaners don't wipe out your application settings? Pin
Christian Graus19-Apr-06 18:34
protectorChristian Graus19-Apr-06 18:34 
GeneralRe: How to ensure registry cleaners don't wipe out your application settings? Pin
Stephen Hewitt19-Apr-06 18:57
Stephen Hewitt19-Apr-06 18:57 
GeneralRe: How to ensure registry cleaners don't wipe out your application settings? Pin
chasetoys19-Apr-06 22:04
chasetoys19-Apr-06 22:04 
GeneralRe: How to ensure registry cleaners don't wipe out your application settings? Pin
David Crow20-Apr-06 3:40
David Crow20-Apr-06 3:40 
AnswerRe: How to ensure registry cleaners don't wipe out your application settings? Pin
Mila02519-Apr-06 19:03
Mila02519-Apr-06 19:03 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.