|
Other way is, get the folders present in "C:\Documents and Settings\". 'Cuz each and every user account on the system has folders (of username) in this path.
Come online at:-
jubinc@skype
|
|
|
|
|
Doesn't work on NT nor Vista.
Doesn't work on non-English versions of Windows since that directory will be named differently.
It also won't work if the special folders have been redirected to elsewhere.
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
Taka Muraoka wrote: I need to be able to find the special folders (e.g. My Documents) for a user other than the one currently logged on.
That's what the third argument to SHGetFolderPath() is for.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
DavidCrow wrote: That's what the third argument to SHGetFolderPath() is for.
Doesn't work for me, unfortunately. You need the user's password to get a token.
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
Then just query the registry. For each user, query the following registry key:
HKEY_USERS\<SID of user>\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Well, that's what I wrote in my original post but it seems a bit of a clunky way of getting the info I need so I was just asking if there was a better way.
Thanks anyway
0 bottles of beer on the wall, 0 bottles of beer, you take 1 down, pass it around, 4294967295 bottles of beer on the wall.
Awasu 2.2.4 [^]: A free RSS/Atom feed reader with support for Code Project.
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
The system wouldn't recognize your memory as a disk.
I don't know of any CRT library functions or OS APIs that will run a process froma memory
image.
Are you trying to speed up startup time of the other process?
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
I don't know how it could be done. I would imagine the main reason there's no API to do it is
because it's a huge security risk. It's an easy way to run a virus.
|
|
|
|
|
|
[Message Deleted due to spam]
|
|
|
|
|
Hello!
I'm sure you guys with tons of experience had same dilemma some time in your carrier. I got in my mind almost impossible task to implement from my project manager. I have to implement click and double click on the same button control.
The idea is that single-click would do some action A and double click would do action B that is totally unrelated to action A. At first look it seems ok, but windows manifest double-click like single-click followed by double-click event.
So how would I know that single-click will be followed by double-click event and not do anything on the first event but just the second one and execute just action B?
In my mind there is no solution to this problem except delaying the single-click event for the time in which double-click may happen. This can result that clients would complain that single-click is slow responsive.
Please help me or direct me to some resources so I can convince myself or my project manager that there is or is not the solution for the given problem.
Best regards,
Rostfrei
|
|
|
|
|
When you get the first WM_LBUTTONDOWN , start a timer whose timeout value is at least GetDoubleClickTime() . If the timer expires before you get WM_LBUTTONDBLCLK , then do your single-click action.
Rostfrei wrote: This can result that clients would complain that single-click is slow responsive.
Bill them for the time spent researching time travel so your code can see into the future to determine whether the user is going to double-click.
|
|
|
|
|
i am wonder how to extract the pixel data from video stream capture window (supppose 320x320) by using visual c++? anyone can do me a favour and related sources for me to refer? Thank you very much and god bless!
love-peace-joy
|
|
|
|
|
baby_fong82 wrote: i am wonder how to extract the pixel data from video stream capture window (supppose 320x320) by using visual c++?
That depends much on what "video stream capture window" you are referring to!
Mark
|
|
|
|
|
Is that 'grab bitmap' same meaning with 'extract pixel data' from video capture window? Microsoft directX 9.0 sdk has provided such grab bitmap tool. How can i utilize it?
love-peace-joy
|
|
|
|
|
baby_fong82 wrote: Microsoft directX 9.0 sdk
So you are referring to DirectShow[^]?
|
|
|
|
|
hai to all...
Can any body plzz help me for this process?
i want to read the contents of a doc file(ms word file) and write the contents
into another doc file(ms word file)...
How shall i do this?
i tried the following method, but itz working only reading and writing text files..
#include <iostream>
#include <fstream>
#include <string>
#include <conio.h>
using namespace std;
void main () {
string line;
ifstream myfile ("C:/1.doc");
if (myfile.is_open())
{
while (! myfile.eof() )
{
getline (myfile,line);
cout << line << endl;
}
myfile.close();
}
else cout << "Unable to open file";
ofstream myfile1;
myfile1.open ("C:/2.doc");
myfile1 << line;
myfile1.close();
getch();
}
Can anybocy plzz help me how to read and write for doc files...
senthil.
|
|
|
|
|
Maybe writing a MACRO for MSWord (or OpenOffice!) is easier than deciphering the proprietary DOC-Format?
"We trained hard, but it seemed that every time we were beginning to form up into teams we would be reorganised. I was to learn later in life that we tend to meet any new situation by reorganising: and a wonderful method it can be for creating the illusion of progress, while producing confusion, inefficiency and demoralisation."
-- Caius Petronius, Roman Consul, 66 A.D.
|
|
|
|
|
senthil wrote: Can anybocy plzz help me how to read and write for doc files...
You can't read the content of the ms document as it is binary file.
You can read from one doc and write to another doc by using binary files(i.e. open files in binary mode).
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
Hai laxman,
thanks for ur reply...
now itz working perfectly in binary mode....
thanks for ur valuble suggestion...
now i'm trying to convert a html file into a pdf file or an image file using
VC++... R u having any idea about this...
thanks...
senthil.
|
|
|
|
|
senthil wrote: now i'm trying to convert a html file into a pdf file or an image file using VC++... R u having any idea about this...
No, I don't have any idea, but you may refer following article. it may help you.
http://www.codeproject.com/csharp/sertf2pdf.asp[ ^]
Knock out 't' from can't,
You can if you think you can
|
|
|
|