|
plz kindly help me in my project
#sanroop#
|
|
|
|
|
Why don't you have a try first and show us what you did? Then we would be able to better help you.
|
|
|
|
|
I guess its a general question
|
|
|
|
|
See here[^] is this your answer?
|
|
|
|
|
Hi,
How you get the coordinates (screen) (on Win32) of the icon/exe/shortcut that initiated an exe. I.e how can I obtain the position of the icon/mouse, on which i clicked/double clicked and my application started.
Thanks in advance.
|
|
|
|
|
Can you be more specific,please
|
|
|
|
|
I don't think this is possible. What exactly are you trying to do, popup your window next to the icon or something?
- S
50 cups of coffee and you know it's on!
|
|
|
|
|
Steve Echols wrote: popup your window next to the icon or something?
yes that is true.
|
|
|
|
|
|
Please suggest me an article which helps me working with UDP.
I know working with TCP.
Thank you
KIRAN PINJARLA
|
|
|
|
|
See Here you can find the articles on UDP
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
Thank you _AnShUmAn_
KIRAN PINJARLA
|
|
|
|
|
|
Hi!
I am u using a Tree View control to get windows folder list. I am using IshellFolder Interface and PIDL to add folders to the list. The Problem is that I dont want some virtual folders to be added into the list.
Is there some way to determine whether the folder is virtual folder or some other special folder using its PIDL??
Thanks in advance!
|
|
|
|
|
See is this[^] good for you
|
|
|
|
|
Thx for the link! It was really helpful. I am facing a new problem now.
I am using SHGetDataFromIDList() function to determine the type of the PIDL variable.
Althought the fucntion returns NOERROR, I am not able to check the values of pv.dwDescriptionId structure. WHat I am trying to do is check dwDescriptionId and determine whether it is a FIXED drive or a removable.
here is my code
SHDESCRIPTIONID pv;<br />
HRESULT hres=SHGetDataFromIDList(pParentFolder,pidl,SHGDFIL_DESCRIPTIONID,&pv,sizeof(SHDESCRIPTIONID));<br />
if(hres==E_INVALIDARG) <br />
{<br />
MessageBox("ERROR","OK",MB_OK);<br />
}<br />
if(pv.dwDescriptionId & SHDID_COMPUTER_REMOVABLE)<br />
{<br />
MessageBox("REMOVABLE","OK",MB_OK);<br />
return;<br />
}
Plz help me!!
|
|
|
|
|
when we press the Show Desktop symbol in the quick lauch bar it minimizes the application
but i don't want to do so
So i m able to get the message of the first Show Desktop Click or (WindowsLogo + D)
and i do my processing accordingly i.e. minimize it in the system tray
i get the message in WM_SIZE IN THAT
void CProDlg::OnSize(UINT nType, int cx, int cy)
{
if(nType==SIZE_MINIMIZED)
{
//minimzed it in the system tray
}
}
but when we press it for the second time i.e.Show Desktop Click or (WindowsLogo + D) i m not able to
do the same as it was in the previouly i.e.i don't know how but my application gets popup and is displayed in an unwanted manner.
I am not able to find out which message is send to the dialogbox when the Show Desktop or Keyboard shortcut i.e. (Windows Logo+ D) for the second time.
One thing is clear that the process Shell_TrayWnd program sends message to all the application to minimze
val
/*MinAll*/ 415,
/*MaxAll*/ 416,
accordingly
static HWND hShellWnd = ::FindWindow(_T("Shell_TrayWnd"), NULL);
if(hShellWnd != NULL)
::PostMessage(hShellWnd, WM_COMMAND, MAKELONG(415, 0), NULL);//for minimizing
::PostMessage(hShellWnd, WM_COMMAND, MAKELONG(416, 0), NULL);//for maximizing
This stuff will minimize all the window
Could u please find out the message so that i could remove the flaw.
Payal
Developer
|
|
|
|
|
Not sure I understand you too clearly, but you should be processing the WM_SYSCOMMAND message. This is what's sent to your application to tell it to minimize/restore. The WM_SIZE is only sent after the application has been resized.
|
|
|
|
|
if(pMsg->message==WM_SYSCOMMAND)
{
if(pMsg->wParam==SIZE_MINIMIZED||pMsg->lParam==SIZE_MINIMIZED)
{
OnMinimize();
pMsg->lParam=pMsg->wParam=0;
}
if(pMsg->wParam==SIZE_MAXIMIZED||pMsg->lParam==SIZE_MAXIMIZED)
{
OnMaximized();
pMsg->lParam=pMsg->wParam=0;
}
TRIED THIS THING BUT NOT WORKING
payal
|
|
|
|
|
Perhaps you should read the docs about the WM_SYSCOMMAND message. Where are those SIZE_MINIMIZED and SIZE_MAXIMIZED coming from? Infact, all you need to do is search the forums, I know for sure this topic has come up at least 3 times in the last week.
|
|
|
|
|
hi all,
In the OnPaint(...) event i am painting the Dialog as Black Color with every pixel PutPixel(...) with 15 * 15 (Horizontal and Vertical) Dots in entire Screen.
I want to create a Transparent EditControl when ever i am generate a LButton Click event, so that the Dots must be visible from the EditControl what i crated in LButtonDown(...) event.
i am giving the snippet of Code.
//===========================================================================
OnPaint(...) //Back ground color with Putpixel(...)
void CExpDlg::OnPaint()
{
if (IsIconic()) // not necessary wizard code
{
CPaintDC dc(this);
SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0);
// Center icon in client rectangle
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;
// Draw the icon
dc.DrawIcon(x, y, m_hIcon);
}
else //My code starts here !!!!!!!!!!!!!!!!!!!!!
{
CPaintDC dc(this); // here the black color with Pixel --->
CRect Recto;
GetClientRect(&Recto);
CBrush bgBrush(BLACK_BRUSH);
dc.SelectObject(bgBrush);
dc.Rectangle(Recto);
for(int x = 0; x < Recto.Width(); x += 15)
{
for(int y = 0; y < Recto.Height(); y += 15)
{
dc.SetPixel(x, y, RGB(225, 225, 225));
}
}
CDialog::OnPaint();
} //My code Ends here !!!!!!!!!!!!!!!!!!!!!
}
//==========================================================================
//==========================================================================
second thing is generate the CEdit Control in LButton Event.
void CExpDlg::OnLButtonDown(UINT nFlags, CPoint point)
{
ptr = new CEdit;
ptr->Create(WS_VISIBLE|WS_CHILD|WS_BORDER|WS_TABSTOP|ES_AUTOHSCROLL,CRect (point.x,point.y,point.x +100, point.y +20),this,NULL);
}
//===========================================================================
Now my doubt is The Edit box is created but the Dots that i have drawn in Onpaint must be Trasparent in the Dynamically Created EditBox is not visible.
because Transparent means the back side things must also be visible ????
please help me out.
Uday kiran
|
|
|
|
|
http://www.codeproject.com/editctrl/ctrltrans.asp
gO FOR THIS article a good one for the probs
payal
|
|
|
|
|
|
Hi Gurus,
Does using RegFlushKey automatically close the handle to a new registry key created using RegCreateKeyEx function. Or we have to use RegCloseKey if the handle needs to be closed?
Thanks
C++beginer
|
|
|
|
|
All RegFlushKey() does is write your changes to the registry rather than letting the OS's lazy flusher do the job. It does not close your handle, you have to do that yourself.
|
|
|
|