|
danginkgo wrote: My project manager wants to use these keys.
It is your duty to explain him that the user will be annoyed if your application overrides predefined shortcut keys. Secondly, explain him the complexities involved in doing it. It is not impossible, but it is not worth doing.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
Thanks. I'll try
danginkgo
|
|
|
|
|
Hi all,
1. How to show dialog such a way that it's Bottom-Right corner will at same position of Bottom-Right corner of Screen?
Also to show dialog at Top-Left corner of Screen?
2. How to hide application/dialog at the start of application?
Normally by calling this->ShowWindow(SW_HIDE); application get hidden.
But when I called this->ShowWindow(SW_HIDE); in OnInitDialog() function of dialog, application is still visible. What is the solution?
Regards,
Aniket A. Salunkhe
|
|
|
|
|
Do you want to set position of your dialog you can use of WM_SIZE with MoveWindow or SetWindowPos and also on this event you can use of ShowWIndow(SW_HIDE).
|
|
|
|
|
Hi,
Thanks for the reply.
Hamid. wrote: you can use of WM_SIZE with MoveWindow or SetWindowPos
But how to get co-ordinates for MoveWindow function call, so that Bottom-Right corners of dialog will match with Bottom-Right corner of Screen.
Also to show dialog at the Top-Left corner of Screen, I made a function call as this->MoveWindow(0,0,Width,Height); but dialog was appearing at the center of Screen.
Thanks & Regards,
Aniket A. Salunkhe
modified on Tuesday, June 17, 2008 3:12 AM
|
|
|
|
|
Use of GetClientRect() and then ScreenToClient().How do you use of and where do you use of this function?
|
|
|
|
|
Aniket Salunkhe wrote: But how to get co-ordinates for MoveWindow function call,
int nHeight = GetSystemMetrics(SM_CYSCREEN);
int nWidth = GetSystemMetrics(SM_CXSCREEN);
And in case if you want to support multiple monitors use SM_CXVIRTUALSCREEN, SM_CYVIRTUALSCREEN constants.
|
|
|
|
|
Hi,
Actually, I want to show dialog as Anti-Virus Alert shows messages alongwith task-bar.
That position of dialog will depends on the size & position of Task-Bar.
Do you know how to show a dialog box as an Anti-Virus Alert Message.
Thanks & Regards,
Aniket A. Salunkhe
|
|
|
|
|
An antivirus has a dialogbox for show messages or it can uses of a tooltip for show its messages.
|
|
|
|
|
I want the dialog box to appear as Skype Sign In/Call/Chat Popup Message, same as GTalk chat Popup Message.
Actually I can't explain it to you properly in text.
|
|
|
|
|
Sounds like a "toaster" window.
"Love people and use things, not love things and use people." - Unknown
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
|
|
Hi,
Thanks for reply.
To check minimization of Dialog I am checking it as,
<br />
void CMyDialog::OnSysCommand(UINT nID, LPARAM lParam)<br />
{<br />
if ((nID && 0xFFF0) == SC_MINIMIZE)<br />
{<br />
}<br />
}<br />
But after pressing 'Windows+M' buttons OR selecting 'Show Desktop' control don't come under this function.
Can you give any solution for that.
Thanks & Regards,
Aniket A. Salunkhe
|
|
|
|
|
handle the WM_SIZE message and check nType == SIZE_MINIMIZED
void CMyDlg::OnSize(UINT nType, int cx, int cy)
{
CDialog::OnSize(nType, cx, cy);
if( nType == SIZE_MINIMIZED )
{
}
}
|
|
|
|
|
|
Aniket Salunkhe wrote: 1. How to show dialog such a way that it's Bottom-Right corner will at same position of Bottom-Right corner of Screen?
Put this in the dialog's OnInitDialog() method:
RECT rc1;
SystemParametersInfo(SPI_GETWORKAREA, 0, &rc1, 0);
int nWidth = rc1.right - rc1.left;
int nHeight = rc1.bottom - rc1.top;
CRect rc2;
GetWindowRect(rc2);
MoveWindow(nWidth - rc2.Width(), nHeight - rc2.Height(), rc2.Width(), rc2.Height());
"Love people and use things, not love things and use people." - Unknown
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
|
i got objectarray list into aobjects
how to pass it to combo box for eg: m_ANodeCombo is my combobox
modified on Tuesday, June 17, 2008 2:41 AM
|
|
|
|
|
Add each element individually to your combobox.
|
|
|
|
|
i am adding like this m_ANodeCombo.SetCurSel(0);
but not getting
|
|
|
|
|
Member 4655685 wrote: but not getting
What are you not getting? Please read the guidelines[^] before posting anything further. If your post does not conform to the norms specified in the guidelines, nobody will be able to help you.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
i choosed correct forum according to guidelines
i have written in simple english only . Not getting means i am not getting the list in combo box
|
|
|
|
|
Member 4655685 wrote: i am adding like this m_ANodeCombo.SetCurSel(0);
What ? You add items using SetCurlSel ? Did you read the documentation ?
|
|
|
|
|
If its new version of Combobox,please give us more info?
|
|
|
|