|
As it's a fairly "vanilla" COM object, it should work perfectly (just make sure it's registered on the system, and you added a reference to it to the project). I haven't tried it, though.
However, under .NET should be "more native" methods to talk to the serial port. No idea which, but would probably be worth doing (if you care about performance, or want to get rid of the mscomm.dll dependency)
Those who not hear the music think the dancers are mad. [sighist] [Agile Programming]
|
|
|
|
|
hi . i am searching for a Simple code to Show an Animated Gif in a Dialog Based Program or in a SDI project.
can anyone help me ?
regards.
-=Ehsan-de-Burge=-
|
|
|
|
|
thanx for your responses
|
|
|
|
|
dear all,
whenever i try to debug my vc 6 applications in windows Xp, i always get an error in MSDEV.exe (memory not read..)
why is it happening.
I can debug my applications in windows 98 and windows me .
why is it happenning!
any lights!!!!!!!!!!
thanx,
|
|
|
|
|
What SP release do you use? With my XP everything worked fine with SP4, and after applying SP5, msdev started to crash from time to time - but rather at compile time than during debug.
Regards,
BB
|
|
|
|
|
which service pack- for xp or for visual studio.
anyways i use no service pack,
should i get one!!!!!
thanx
|
|
|
|
|
I meant Visual Studio SP4, but of course XP SPs are also recommended - I haven't noticed they would have messed something up.
Regards,
BB
|
|
|
|
|
thanx for ur concern but even installing vs sp4, the problem persists,
now what should i do!
regards
|
|
|
|
|
If XP SPs also don't help, you may try a new clean installation
Everything works fine for me.
Regards,
BB
|
|
|
|
|
Hello,
after closing my app. I can read some lines after Detected memory leaks!
an example:
Detected memory leaks!
Dumping objects ->
afxtempl.h(330) : {574839} normal block at 0x0191AAF8, 16 bytes long.
Data: < L_4 D > FF 7F 00 00 01 00 00 00 14 CB 4C 5F 34 96 44 06
afxtempl.h(330) : {574830} normal block at 0x019200E8, 64 bytes long.
Data: < L_ > FF 7F 00 00 00 00 00 00 14 CB 4C 5F DD 09 03 00
afxtempl.h(330) : {574821} normal block at 0x01912988, 64 bytes long.
Data: < L_ > FF 7F 00 00 00 00 00 00 14 CB 4C 5F DD 09 03 00
afxtempl.h(330) : {574812} normal block at 0x01919100, 64 bytes long.
Data: < L_ > FF 7F 00 00 00 00 00 00 14 CB 4C 5F DD 09 03 00
strcore.cpp(118) : {574811} normal block at 0x018F0118, 19 bytes long.
Data: < Past> 01 00 00 00 06 00 00 00 06 00 00 00 50 61 73 74
strcore.cpp(118) : {574810} normal block at 0x019202C0, 18 bytes long.
Data: < Agua> 01 00 00 00 05 00 00 00 05 00 00 00 41 67 75 61
strcore.cpp(118) : {574809} normal block at 0x0192ECD0, 18 bytes long.
...
how can I get the origin of them?
as always thank you in advance...
|
|
|
|
|
Usually, you can just doubleclick on the line, as you would with a build time error, but it tends to be awkward with strings, as it just gives you a reference to where the string itself allocated the memory (which isn't useful to you)
However, you can see part of the string that was allocated "Past" and "Aqua" so that should make it possible for you to work out where the strings were allocated
--
Help me! I'm turning into a grapefruit!
|
|
|
|
|
ok...
I'll try to find it...
but I'm using CString object in order to handle my strings. Do I need to release in some way the string?
Thank you in advance.
|
|
|
|
|
Do you cast your CStrings into LPTSTR instead of LPCTSTR somewhere?
That is, do you bend them into being non-const?
Or do you GetBuffer() somewhere without Release() ?
Release() is only needed after GetBuffer() , but then ABSOLUTELY needed.
Normaly, the CString is dealocated when it goes out of scope.
My opinions may have changed, but not the fact that I am right.
|
|
|
|
|
;)hi,
read memory contents at
0x0191AAF8
0x019200E8
0x01912988
.
.
.
in the files as shown as see where you get, i guess maybe you are allocating some memory and not releasing it out afterwards. just check out...I m not sure whether i am right or not..did it a yr ago i guess.
cheers
Himanshu
|
|
|
|
|
Since you are using MFC, put the following code at the top of each source file in your program (after the #includes):
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
Then, when you get these memory leaks, you will be able to see the location where you allocate the object that you are leaking.
Note that it's possible to do this even if you don't use MFC, but then you have to write your own new and delete operators, and I don't want to explain all that.
Chris Richardson
Programmers find all sorts of ingenious ways to screw ourselves over. - Tim Smith
|
|
|
|
|
Thank you for the information, I've located them before, but this is a good point...
|
|
|
|
|
How can I view the processes running under svchost.exe?
I am interested in the memory of those process.
eg., tapi32.dll is a service run under svchost.exe, how to see its parameters like memory, starttime etc.
|
|
|
|
|
Did you try Task manager?
|
|
|
|
|
Use a process called depends.exe delendancy walker
Enda Mannion
Ireland.
|
|
|
|
|
This code simply open the printer setup dialog box :
CPrintDialog dlg(TRUE);
AfxGetApp()->DoPrintDialog(&dlg);
As soon as this dialog box is open, any repaint of my main window
causes a crash in the dll that do the painting. That seems to be
in relation with the use of the GDI, but I have no precise clue.
This crash occurs only 1) in Win95/98/ME, not NT/2000/XP
2) in release compilation , not debug
On one moment I had resolved the problem by compiling the dll witout any
optimization (normally size optimized). But now, after some changes in this
dll, that crashes again.
--> ?
JPG
|
|
|
|
|
I found the solution on CodeGuru...
// extract :
When starting the print-dialog, a part of the code in the printerdriver is executed (setup/init, querying printer capabilities etc). This bit of code may have altered the FPU exception mask. The driver SHOULD reset the FPU exception mask but this is quite often omitted.
The safest bet would be to reset the FPU after calling the CPrintDialog:oModal.
_control87( _CW_DEFAULT, 0xfffff )
//
Executing this line
_control87( _CW_DEFAULT, 0xfffff )
before my paint code stops the crash.
JPG
|
|
|
|
|
Hi, i've been working on an IM app, and have been having some more trouble (i had a different problem yesterday) with using rich text, now i was messing around with adding images in (like the official msn messenger client and emoticons, which coincedentically also uses rich text) i tried using some code from knowledge base article (220844) but this code seems to leak memory, my working set increases by a few mb if i add and remove 50 images. The use of ole seems like total overkill for my purposes, if you've used the messenger client you'll know what i'm talking about, the closer i can get to this level of functionality in my rich text control the better.. any thoughts?
thanks.
|
|
|
|
|
Hi,
I ported my application(MFC with VC6) to XP. I used the mechanism of seperate manifest file in application directory .Refer MSDN article for "Using XP style" (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwxp/html/xptheming.asp)
Now the problem is the Grip portion of the Toolbar is not getting repainted properly in XP.
Thanks in advance
Ajesh
|
|
|
|
|
Hi All,
I must be making this way too complicated. Could someone show me how to pass a TCHAR* or LPTSTR to a member function, allocate enough memory for an unknown string length, and have the string be there when it returns?
I feel like this is a stupid question, but just can't get it to work!
thanks
Paul
|
|
|
|
|
Hi..
many API functions that take char* as an argument takes the lenghth of the buffer as well..
you can do the same, pass the pointer and the length to the function...
|
|
|
|