|
thanks. I guess I will have to windiff the files in the projects and see what gets added on....
|
|
|
|
|
I've been looking around for a good tutorial on the basics of building a screen saver in C++ and without MFC.
I already have my EXE built; I just need to know how to make it work as an SCR. I know it needs to run in different modes like configure, test, preview, etc, but I don't know how to do this.
If anyone can point me to a good (or even semi-good) tutorial on this I would greatly appreciate it.
Thanks for your time.
-Cactus Joe
|
|
|
|
|
MSDN samples contains full implementation of a screen saver.
Programming is an art not a skill, every one can be a skilled programmer but not an artist.
|
|
|
|
|
*Smacks forehead*
Why did I not check there in first place...?
Thanks!
|
|
|
|
|
I want to know how can I write a program based on Dialog Application, when it display another dialog, the dialog will fit the based dialog just like SDI/MDI's new files fitting in their parent window???
|
|
|
|
|
You want something like...
BOOL CMyPopupDlg::OnInitDialog ()
{
...
CWnd *pParent = GetParent ();
if (pParent)
{
CRect rc;
pParent->GetWindowRect (&rc);
SetWindowPos (NULL, rc.left, rc.top, rc.Width (), rc.Height (), SWP_NOZORDER);
}
...
return CDialog::OnInitDialog ();
}
I hope that helps,
Iain.
|
|
|
|
|
i guess setting the child windows with WS_CHILD style will do the trick, didnt test it, but i guess thats what it is.
Programming is an art not a skill, every one can be a skilled programmer but not an artist.
|
|
|
|
|
Hi all,
I want to distribute my applications to others, but at the same time i want to make sure that it will run for the say N Days only. Can anyone give any direction to start. My application is Win32 Application and i am using MSVC 6.0
Thanks in advance.
AL
|
|
|
|
|
Producing something that can't be fooled by e.g. setting the machine date back to the day of the instalation is very hard.
Makeing a solution that is not diabled by harddisk imageing/restore is almost impossible.
But if thats OK for you, the best thing is to finde a hidden quiet spot in the registry, write some encrypted timestamp there and check at startup if you are more than N days later.
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|
|
In addition to jhwurmbach's suggestion, I would suggest making the registry key something not obvious. In other words, don't make it something InstallationDate, or DateOfExpire! Give it a name that has absolutely nothing to do with an expiring date.
A rich person is not the one who has the most, but the one that needs the least.
|
|
|
|
|
Hi jhwurmbach abd David,
Thanks for suggestion.David can you elobrate future on how I can create the key which had nothing to do expiring date.
Again Thanks in advance
AL
|
|
|
|
|
Abhi Lahare wrote:
David can you elobrate future on how I can create the key which had nothing to do expiring date
Simple: As the name of the Key use a GUID (made by Guidgen.exe). In that keys value you can store the installation (or expiration) date. Probably as an integer, not a date-string.
Hope that helps
Who is 'General Failure'? And why is he reading my harddisk?!?
|
|
|
|
|
I have read that a pointer has no relavence outside the process. What does this mean exactly. Can anyone explain this ..please. Also what about the far dont they refer to outside the process .... kindly explain.
Thank you.
|
|
|
|
|
You can use the analogy of a memory address being a phone number - where each process is equivalent to an area code.
If you call a number from the same area code you will get the person you expect. If you use a pointer withing your process you will get the data you expect...but if you use a phone number from a different area code you will get a wrong number and if you use a pointer from a different process you will get a wrong address which usually results in a program crash.
If you want to access another process' memory use the API call ReadProcessmemory which is equivalent (in the above tortured analogy) to adding the area code to the phone number.
'--8<------------------------
Ex Datis:
Duncan Jones
Merrion Computing Ltd
|
|
|
|
|
Each process has its own virtual memory space. Simply, this means your processes pointer (0x1000) will
point to a different bit of silicon than the same pointer in a different process. This makes your
life simpler and allows for security (you have to work hard to damage another process, and vice versa).
The far keyword was used in 16bit windows to indicate a 32 bit pointer, with some other fancy bits.
It is completely obsolete in 32 bit machine. I imagine the compiler just pretends you hadn't typed
it.
Iain.
|
|
|
|
|
Iain Clarke wrote:
I imagine the compiler just pretends you hadn't typed
it.
Actually, the compiler never sees it as the preprocessor strips it out.
A rich person is not the one who has the most, but the one that needs the least.
|
|
|
|
|
I was trying not to confuse the chap. I normally simplify preprocessor, compiler, and linker into
one big lump unless I can't do so. A big black box. Typed stuff in one end, exe / dlls out the other.
Unless they're doing occasional clever things, I imagine most people do to.
So there...
Iain.
|
|
|
|
|
I'm writing a context menu shell extension that is shown in response to user right-click on directory background. I need to get the explorer interface (iwebbrowser2 or similar) that executed my extension. From what I found the communication is one-way and I can't get what I need. Am I missing something, or is there some hack?
|
|
|
|
|
I've had a quick look see, and about the only information you get from the caller is the HMENU.
As this doesn't help you too much, you may be able to go from the mouse position. That would
certainly tell you the window of the explorer area. You may be able to go from there.
But in short, you're not *meant* to know / care. The information you need is passed through
the IShellExtInit::Initialize interface. That gives you the PIDL of the folder, and an
IDataObject (whatever that is!). I can't think why you'd need more.
If you expand of what you want from the caller, I may be able to help.
Iain.
|
|
|
|
|
Iain Clarke wrote:
If you expand of what you want from the caller, I may be able to help.
I want to be able change the directory of the calling explorer. More or less like the "Go To Folder" feature of http://www.shelltoysxp.com/[^].
|
|
|
|
|
Will a Separate copy of Dll be loaded for each application reference? If so, How can I share the same data between applications? could anyone explain please.
Shenthil
|
|
|
|
|
Correct. Each process gets a copy of the DLL data in its address space.
There are several solutions to data sharing across address space. One solution is memory-mapping.
Kuphryn
|
|
|
|
|
You can also mark certain data segments in a DLL as shared.
From the MSDN docs:
#pragma section ("mysectionname", read, write, shared)
__declspec(allocate("mysectionname")) int my_shared_variable = 0;
This will create a section within your DLL called mysectionname. It will be shared among the processes which loads the DLL. By using __declspec(allocate) you advise the compiler to put the variable in that section instead of it's private data segment.
--
You're entertaining at least.
|
|
|
|
|
Hello there,
I have a very stupid question to ask and I know I'm going to kick myself when I find the answer:
How do you change the font in a static text (label) box in a dialog.
Thanks in advance
|
|
|
|
|
Click the entire Dialog and Check for its properties. U'll have font attribute changing which changes the font of static text too.
Shenthil
|
|
|
|