|
|
if you use pop1->showWindow(SW_HIDE); why use pop1->EnableWindow(false);?
you hide window and you want to disable it
whitesky
|
|
|
|
|
i mean tried one after one
|
|
|
|
|
when u called
pop1->showWindow(SW_HIDE);
did the dialog become invisible?
nave
|
|
|
|
|
|
From where did u created this dialog?
And from where( which function ) r u trying to hide/Disable it?
nave
|
|
|
|
|
in CListBox we have a Function OnSelectChange().when the selection in the list box change then i call this dailog by
writing following code
if(m_list.GetCurSel==LB_ERR)
{
}
else
{
pop1= new CPopupDlg();
pop1->Create(IDD_DIALOG1,this);
pop1->ShowWindow( SW_SHOW );
}
once i change the selection i want to disable that dialog .
|
|
|
|
|
Then where do u want to write pop1->EnableWindow( FALSE );
I thing ur getting another pointer while calling
pop1->EnableWindow( FALSE );
nave
|
|
|
|
|
when we want select another one then it will check if condition if it is true then i will keep that EnableWinbow().
but t's not working
|
|
|
|
|
try modifying the function like this
static CPopupDlg pop1;
if( 0 == pop1.m_hWnd )
{
pop1.Create(IDD_DIALOG1,this);
pop1.ShowWindow( SW_SHOW );
}
if( /*the condition*/ )
{
// Disable the dialog
pop1.EnableWindow( FALSE );
}
else
{
// enable the dialog
pop1.EnableWindow( TRUE );
}
nave
|
|
|
|
|
enable is done but disable is not working.
i think this enable also due to pop1.ShowWindow(SW_SHOW);
without pop2.EnableWindow( TRUE ) also we can get the dialog.
but without pop1.ShowWindow(SW_SHOW); not getting the dialog
|
|
|
|
|
send me the code i will check and tell
nave
|
|
|
|
|
i think you can use these functions once no
if(m_list.GetCurSel!=LB_ERR)
{
pop1= new CPopupDlg();
pop1->Create(IDD_DIALOG1,this);
}...repeat
whitesky
|
|
|
|
|
i used the same thing but not getting the desired result
|
|
|
|
|
check for return from these functions
BOOL o=EnableWindow and BOOL o=ShowWindow
if o=1 so this function is run else no
whitesky
|
|
|
|
|
Hi friends,
1.In Windows both WINAPI and CALLBACK are declared as _stdcall .
what is the exact difference between them ??
2.if the default calling convention in windows is _stdcall ,then what is the use of preceding the functions with WINAPI ??
3.Is void MyFunc() same as void _stdcall MyFunc( ) in windows??
4.What is difference between normal functions and CALLBACK functions ??
Thanks in Advance.
Appu..
"If you judge people, you have no time to love them."
|
|
|
|
|
NiceNaidu wrote: Hi friends,
1.In Windows both WINAPI and CALLBACK are declared as _stdcall.
what is the exact difference between them ??
If declared as same then they are same!
NiceNaidu wrote: 2.if the default calling convention in windows is _stdcall,then what is the use of preceding the functions with WINAPI ??
3.Is void MyFunc() same as void _stdcall MyFunc() in windows??
4.What is difference between normal functions and CALLBACK functions ??
i am sorry to say that , you should consult MSDN before posting it here
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You
|
|
|
|
|
Hi Alok,
Thanks for the help.
I have searched MSDN for these before i post.But did n't get enough help.Thats the reason why i posted here.
If at all, you find any supporting links, Can u post them here.
Thanks again,
Appu..
"If you judge people, you have no time to love them."
|
|
|
|
|
|
1. Nothing. They are used for different purpose - WINAPI is used for Windows API function calls, CALLBACK is used for callback functions that you define. It's purely so developers can tell the difference between what the functions are used for.
2. The default calling convention for C and C++ is cdecl , not stdcall .
3. No. The first one has the cdecl calling convention, the second is stdcall .
4. A function marked with CALLBACK uses the stdcall calling convention, rather than the usual cdecl . This means that the parameters are popped off the stack by the function, rather than the caller. For cdecl functions, the parameters are popped off the stack by the caller.
Ryan "Punctuality is only a virtue for those who aren't smart enough to think of good excuses for being late" John Nichol "Point Of Impact"
|
|
|
|
|
Thanks Ryan,
This is what i am looking for..
Thanks WhiteSky.The link is very informative.
Keep going.
Thanks again.
Appu..
"If you judge people, you have no time to love them."
|
|
|
|
|
__stdcall is a "calling convention". Portability is the simplified explanation. Macros are used to enhance the portability of the code.
This article might help[^]
"Just about every question you've asked over the last 3-4 days has been "urgent". Perhaps a little planning would be helpful?" Colin Angus Mackay in the C# forum
led mike
|
|
|
|
|
Hello,
By using WinInet Api,I can know that I am connected via LAN but is there any Api by using which I can know that i am connected via WLAN or not.
Regards
Girish
Software Developer
|
|
|
|
|
Hi,
Generally I can't remember any perfect function - all techniques are based on check existance an well-known address. You can try to use
BOOL InternetCheckConnection(
LPCTSTR lpszUrl,
DWORD dwFlags,
DWORD dwReserved
);
-----------
Mila
|
|
|
|
|
I want to open avi file and get each frame from avi stream. These frames will be used in my programme. I search many sites, but I can't find siutiable answer. Please give me some suggestions if you have any idea. I am very grateful for your help. Thanks!
dinyxu
-- modified at 0:10 Friday 9th June, 2006
|
|
|
|