|
I'd hazard a guess and say you're developing under Win9x.
I had the same thing a little while ago (I'd never seen it before, even on much larger projects).
The solution I found was to setup the virtual memory settings myself, rather than let the OS manage it (actually, this isn't a bad idea on a development machine, since it can reduce swapfile fragmentation).
I hope this helps!
Andy Metcalfe - Sonardyne International Ltd (andy.metcalfe@lineone.net) http://www.resorg.co.uk
"I used to be a medieval re-enactor, but I'm (nearly) alright now..."
|
|
|
|
|
HI
Question about IPicture
As I know IPicture class can work whith custom types which
I can find it in PICTYPE enumeration (look in MSDN)
but when I went to
codeproject>> Bitmaps & Palettes >> Bitmaps
and then( Simple class for drawing pictures )
I found I can load other types like jpg, tif, gif(but tif didn't work)
Is this secrets so it most didn't apear in MSDN or what !!!
Thank you ...
AHMAD ALWASHALI
|
|
|
|
|
Hi,
Can I lock an edit box , say a password field such that no other application can acess the contents of that field.
Thanks
|
|
|
|
|
Interesting question. I suppose you could subclass the window and watch for WM_GETTEXT messages, and return an empty string or "sodoff" or whatever you want.
Oh, you should handle WM_GETTEXTLENGTH as well, to hide the length of the text.
--Mike--
http://home.inreach.com/mdunn/
The preferred snack of 4 out of 5 Lounge readers.
|
|
|
|
|
"sodoff" ... rofl ... thats cute
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
Hi!
Is this in any ways related to Cracking? If so, there would not be any chance if the NuMega SoftIce is around (most of the time is)!
As for Mike's post, still the WM_GETTEXTxxx will be caught and user/programmer will get the edit box's contents just coz it is a message and will be possible to set a break on it!
As I mentioned above, if it is Cracking related, then perhaps you could try using other methods rather than plain edit box, lock and even masking it with the * characters, you may know that the * are easily revealed. There is an article on coeguru I guess with source/demo.
Good Luck!
|
|
|
|
|
Hello,
I'm new to visual development and am stuck. I've got a main app window with several children in it. The children are DirectShow movie windows and dialog boxes I created to control the movies. When a play button is clicked I need to know which dialog box the command came from, to play the correct movie, how do I do this?
I tried to get the active window and figure it out that way but my child windows are never active, only the main parent window. If I could change this so that the dialog box where the command comes from is active things would be ok, does anyone know if this is possible?
Thanks for any help!
luedee@yahoo.com
|
|
|
|
|
Sounds like each dialog is built from the same template, so their control IDs are all the same. Hmmm...
Well, if the dialog with the play button knows what movie to play (or has some distinguishing data) you could set up a custom windows message that would be posted when the play button is hit. Create a handler in the main wind (perhaps using ON_MESSAGE macro, if MFC) to get all these notifications. When you post the message inside OnPlay, the wparam or lparam can be set with some indication of who posted the message, and your main handler can switch on that.
I know this is a little short on detail, but I think if you search this forum for ON_MESSAGE you'll get some tips.
|
|
|
|
|
I'm coming to the end of my inaugural WTL project and I've hit an odd snag. I am filling a listctrl with ID3 tages, editing them and writing them out again. I'm using someone elses ID3 class ( although it needed so much work I may as well have written it ;0) and it will NOT append a file with ID3V1 information for me. As soon as the info is there, I can overwrite it, but otherwise, I just cannot write to the file. It's not read only, and I've tried using
SetFilePointer(fHandle, 128, 0, FILE_END);
SetEndOfFile(fHandle);
SetFilePointer(fHandle, -128, 0, FILE_END);
if (!WriteFile(fHandle, "TAG", 3, &sentinel, 0))
WriteFile(fHandle, myID3.title, 30, &sentinel, 0);
WriteFile(fHandle, myID3.band, 30, &sentinel, 0);
WriteFile(fHandle, myID3.album, 30, &sentinel, 0);
WriteFile(fHandle, myID3.year, 4, &sentinel, 0);
WriteFile(fHandle, myID3.comment, 30, &sentinel, 0);
WriteFile(fHandle, &myID3.genre[0], 1, &sentinel, 0);
SetFilePointer(fHandle, 128, 0, FILE_END);
and various permutations of this, and also
CloseHandle(fHandle);
ofstream stream;
stream.open(filepath, ios::app);
stream.setmode(filebuf::text);
stream << "TAG";
stream << myID3.title;
stream << myID3.band;
stream << myID3.album;
stream << myID3.year;
stream << myID3.comment;
stream << &myID3.genre[0];
stream.close();
Can someone please tell me if I am doing something wrong, or suggest why this is not appending my file ? I've traced through and this code executes whenever a tag is not present, but nothing is being done.
Thanks.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
Those API calls must be failing left and right - look at the return values and the value of GetLastError() to see what's going wrong.
--Mike--
http://home.inreach.com/mdunn/
The preferred snack of 4 out of 5 Lounge readers.
|
|
|
|
|
Invalid handle, but the handle is only invalid if the file has no id3 tag at the end.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
I have written a small class to work with mp3 files, which is not complete, yet. The tagging-function works pretty well.
If you're interested, then e-mail me at:
billgates16@gmx.de
bye,
FoxHunter
|
|
|
|
|
"... so tell us Mr Graus ... what is your impression of the fabled WTL class library and its application to curing world poverty and hunger?"
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
It plainly rocks. I am a little nervous about using it for production code, only because I want to 'know' it a little better before I would entrust a major project to the idea that we won't get half way through and find it won't do something for us easily, but overall I am certainly enjoying learning it and finding it fun to use. Having the message map all in one place is so much easier when you're coding things in yourself rather than using classs wizard. I still don't have the hang of the DDX stuff, I'll attempt that tonight.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
Is it possible for you to call LockFile or LockFileEx on the file? What error would it give if not?
|
|
|
|
|
Hi everybody,
I have a problem about WH_SHELL hook. When I use WH_SHELL hook in a dll file (as system-wide hook), it shows a very strange behavior:
Under Win9x/Me, the taskbar does not work correctly. For example, while the program is active, when i start another application, its icon does not appear in the taskbar. When I close my application the icons appear.
At first I think that it is because of my application, however when I downloaded a sample by Frederic Boulanger which also uses WH_SHELL hook, I saw that this strange thing also occurs.
NOTE that everything works fine under Win2000.
Is there anyone who knows the reason of this?
Please help
Best regards
Mustafa Demirhan
|
|
|
|
|
I was wondering if there is a way to find out when an ActiveX control has actually downloaded.
I need to pass a few parameters from my HTML page to my ActiveX, but I am having timing and synchronizing problems. The problems arise from the fact that a lot of times the method calls are made before the object has fully downloaded.
Is there any method or events that I could use to find out whether an ActiveX has downloaded?
thanks
|
|
|
|
|
ok ... this is a klunk but ...
embed an image in the page but don't put its dimensions in the tag ... that causes the browser to show nothing until the image has downloaded totally ... make the image tag after your active x tag and it might give you the time you need to download completely
theres gotta be a better way than this but i did say it was a kludge
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
I am having a bad time with a program which I am writing - I wan't to run a DOS based program from my program (Windows). I tried using ShellExecute but the ony thing that happens is that a dos window comes up saying couldn't execute stub or something like that.
Please help, thanks,
James Bird - birdjames@bigfoot.com
|
|
|
|
|
Take a look at CreateProcess(), you might have better luck with this function...
- Anders
|
|
|
|
|
Does the DOS app use a DOS extender, such as DOS4GW? If so, my guess is that the problem is the current directory isn't set right, so the app can't find the DOS extender. Try setting the current dir to the one where the app is, or else use CreateProcess() which takes the dir to use as the current dir as a parameter.
--Mike--
http://home.inreach.com/mdunn/
The preferred snack of 4 out of 5 Lounge readers.
|
|
|
|
|
Anybody has a copy of Sieve of Eratosthenes --- Prime Number generator program.
|
|
|
|
|
Asking people to do your homework is not a long term method of succeeding in the computer industry. How about you post your code and I'm sure we'll all be happy to give advice on where you are stuck.
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
Thanks to those who helped me previously, my WTL project is progressing nicely (when I find time )....
My latest problem is very odd. I have tried using a number of functions that take an ATL CString, such as GetDlgItemText, GetWindowText ( no prize for guessing what I want to do ) and also GetItemText in my CListCtrl. In EVERY case, I get a message like this:
c:\my programs\wtl\mp3cat\inputdlg.h(52) : error C2664: 'int __thiscall ATL::CWindow::GetDlgItemTextA(int,unsigned short *& ) const' : cannot convert parameter 2 from 'class WTL::CString *' to 'unsigned short *& '
A reference that is not to 'const' cannot be bound to a non-lvalue
I don't see why it's asking me for a pointer to an unsigned short, but it appears an almost universal problem. I've found ways around it in other places ( by doing things differently ) but in this case I have a dialog which has the sole purpose of getting input from a CEdit. I tried fiddling with the DDX sample, but to no avail, and while I'm guessing a bit more time with that might do it, I *hate* DDX anyhow and *never* use it in MFC, so I'd much prefer to get to the bottom of this problem.
FWIW I have the version of ATL in the last SDK ( October from memory )
Thanks to one and all
Christian
The content of this post is not necessarily the opinion of my yadda yadda yadda.
To understand recursion, we must first understand recursion.
|
|
|
|
|
Sounds like something's screwy with your ANSI/Unicode settings. GetDlgItemTextA() is expecting an unsigned short* (ie Unicode string) which isn't right.
--Mike--
http://home.inreach.com/mdunn/
The preferred snack of 4 out of 5 Lounge readers.
|
|
|
|
|