|
I want my MFC application will check whether another instance of it is already running or not. And if another inst. is running then it will kill the prev process. I want to know how get the information whether another instance is running and not? and how to get the process id of that one?
|
|
|
|
|
|
|
I have a multiple desktop application in which I am trying to set a different wall paper when you switch between different desktops. I am setting the wallpaper as:
<br />
SystemParametersInfo(SPI_SETDESKWALLPAPER,0,(void*)m_WallPaper,SPIF_UPDATEINIFILE|SPIF_SENDWININICHANGE)<br />
This seems to set the wall paper correctly, but after I call SwitchDesktop the wall paper vanishes a few seconds later. I create a seperate explorer.exe per desktop.
1. Does any one know if there is any other way to set the wall paper?
2. Is it possible to identify what causes the wall paper to change? I mean, who has changed it?
3. Is the wall paper set by the system or windows explorer?
4. Any ideas to debug why the wall paper vanishes?
thanks!
|
|
|
|
|
Brundiez wrote: SystemParametersInfo(SPI_SETDESKWALLPAPER,0,(void*)m_WallPaper,SPIF_UPDATEINIFILE|SPIF_SENDWININICHANGE)
This won't work when ActiveDesktop is enabled. You need to use IActiveDesktop COM object to solve this.
http://www.codeproject.com/tools/wallpaperq.asp[^]
Jesus Lives Forever - Amen <marquee direction="up" height="40" scrolldelay="10" step=".5" scrollamount="1" style="background:#99ccff;border-bottom:thin solid 1px #6699cc">
--Owner drawn
--An eye for an eye makes the whole world blind.
--If you find my post helpful then do rate it.
--Jesus is Lord
|
|
|
|
|
1. From the look of my desktop, I dont think I have ActiveDesktop enabled. How do I confirm if it is enabled?
2. Does the IActiveDesktop COM object's way of setting the wall paper help in both the cases - ActiveDesktop is enabled and disabled?
3. FYI, I downloaded Virtual Desktop manager from http://www.microsoft.com/windowsxp/downloads/powertoys/xppowertoys.mspx. I can change the wall paper in a desktop, but when I switch between desktop it doesnt seem remember and restore the wall paper that I changed. Have you used this, any idea why it doesnt work, is it a bug?
thanks!
|
|
|
|
|
convert char[] to cstring
Thanks in Advance
|
|
|
|
|
|
Thank u for ur responce
i am sorry , i need to assign a array element
CString s[10]
char ch[]
-
s[i]=ch
any how thanks a lot
|
|
|
|
|
ptr_Electron wrote: i am sorry , i need to assign a array element
So what
char str[] ="Owner drawn is a good boy";
CString str1[10];
str1[0] = str;
MessageBox(str1[0]);
Jesus Lives Forever - Amen <marquee direction="up" height="40" scrolldelay="10" step=".5" scrollamount="1" style="background:#99ccff;border-bottom:thin solid 1px #6699cc">
--Owner drawn
--An eye for an eye makes the whole world blind.
--If you find my post helpful then do rate it.
--Jesus is Lord
|
|
|
|
|
|
|
is the same way to do with CString array
Thank in Advance
|
|
|
|
|
|
|
Hi,
I have a dialog application where user enters hex values in CEditbox.
Is there a editbox where we can create a member variable of type HEX??
for CEDIT, only int, long, byte etc are possible but not HEX.
the hex value can range from 0x00 to 0xFFFFFFFFFFFFFFFF
in this case.
Any clues on how to do this????
- KK
|
|
|
|
|
|
I thought about that, but not sure of how to do that. Is there a code I can refer or has someone done something similar to this?
- KK
|
|
|
|
|
|
I did check that.
It validates the user entry and makes sure that user enters valid hex code, but does not solve my problem. It does not have a member variable which can give me hex value.
- KK
|
|
|
|
|
|
Thank you for your time, although I was looking for help from someone who can give easy to follow help for beginers too !
- KK
|
|
|
|
|
|
kk_vp wrote: It validates the user entry and makes sure that user enters valid hex code...
Actually it says it will do that but it is missing several key points.
kk_vp wrote: ...It does not have a member variable which can give me hex value.
What do you mean by this?
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
|
|
|
|
|
there's no particuliar type to store hexadecimal values.
the answers of Owner Drawn are good enough. if you'r not satisfied, please detail the points you need help on, because nobody will do the whole job for you...
TOXCCT >>> GEII power [toxcct][VisualCalc 2.20][VCalc 3.0 soon...]
-- modified at 8:09 Tuesday 31st January, 2006
|
|
|
|