|
Sorry, I did that too quickly. You also need to export the function.
in the .def file
EXPORTS
...
GetAccountCodeFromAccountNumber @99
...
Chris Meech
"what makes CP different is the people and sense of community, things people will only discover if they join up and join in." Christian Graus Nov 14, 2002.
"AAAAAAAAAHHHHHH!!!!! Those leaks are driving me crazy! How does one finds a memory leak in a garbage collected environment ??! Daniel Turini Nov. 2, 2002.
|
|
|
|
|
You are the man Chris Meech! Thanks fer helpin me out!
still a newb.. cut me some slack :P
-dz
|
|
|
|
|
Hello all!!
I will open a simple text file in MDI or SDI Project.
can somebody help me how i do this.
THX.
|
|
|
|
|
All you need to do is create a SDI or MDI of type CEditView... Then click the open button or from the menu and point it to a text file..
|
|
|
|
|
THX for your fast answer RobJones!!
|
|
|
|
|
Hi there everyone,
I will be very grateful to get any clue/direction about a problem, which I have on the last couple of days:
How can I transfer a rough audio buffer to an audio streaming, I have looked at the sample of this subject in the MSDN and I saw a sample which works properly only with WAV file – I want to check it with a buffer.
Thanks and Regards,
Eyal
|
|
|
|
|
Hello,
it's obvious that I don't free some memory that it's getting occupied again and again till everything blowns up...
The fact is that I've searched for all the "new"s in my project and all of them have their respective deletes...
Is there any way to detect what is happening and where?
would the memory be occupied also by SelectObject if I wouldn't delete the returned pointer?
NOTE:
is important to solve the problem becaus the VC++ program is intended to control a mechanical machine that will work 24 hours a day 365 days per year...
Thank you in advance.
|
|
|
|
|
I'd reccomend you get hold of BoundsChecker - that's a great app for tracking down memory leaks
--
Help me! I'm turning into a grapefruit!
|
|
|
|
|
another cause can be your serialization..
if you are reading in during serialization and have any 'new' keywords you could get a memory leak if your loading serialization is called multiple times without deleting what was created the previous time the data was serialized.. i know that was my problem once..
if not then i dunno try searchin for 'delete' in this board and you will come accross a bunch of ppl who have had memory leaks.. including me
still a newb.. cut me some slack :P
-dz
|
|
|
|
|
|
You might want to check out MemWatcher[^].
It's not a developer's tool, but it can help keep your PC running smoothly over long periods of time by freeing up memory that Windows thinks is in use. It works especially well on Win9X and ME which frequently "runs out of memory" when it shouldn't.
/ravi
Let's put "civil" back in "civilization"
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
I've got some RAW images and I have to open and process them: so I thought it was a good idea to get them and load them into CBitmap objects, in order to use MFC GID function, instad of readin each pixel with two FOR cycles.
RAW images have no header and they are 35MB large, I've tried this way:
*) CFile file;
*) BYTE* pData = new BYTE[fileSize];
*) file.Open(path, CFile::modeRead);
*) file.ReadHuge(pData, fileSize);
*) file.close();
*) m_bmp.CreateBitmap(m_BmWidth, m_BmHeight, 1, m_BmBpp, pData);
Variables are class attributes.
Debugging the code, is like I can't get the CreateBitmap method working.
|
|
|
|
|
1. RAW (almost by definition) has no specified format. it's usually the 'raw' uncorrected data dump from a CCD, scanner or some other device, in some undocumented format, not meant for your use.
2. CreateBitmap expects the data to be in a specific format, one which .RAW almost certainly doesn't conform to. (specifically, word-aligned pixel rows, probably with bottom-up scanlines and in BGR/BGRA channel order for 24/32 bpp images)
your best bet is to try to find out the format that your particular "RAW" image uses (good luck, and don't assume it applies to every other file with a .RAW extension), parse it into the format that CreateBitmap expects (32-bit RGBx is probably the easiest). then, you might get an image, though it will likely be in some color space (maybe logarithmic RGB , for fun) that you'll need to post-process. and, the image might need color balancing, color correction, sharpening, scaling, etc. before it looks like any kind of reasonable image.
-c
When history comes, it always takes you by surprise.
|
|
|
|
|
So I have to scan the whole 35MB with two FOR cycles, bulding my matrix?
|
|
|
|
|
yes, unless by some wild coincidence, the format of your particular .RAW file is the same format the CreateBitmap wants.
-c
When history comes, it always takes you by surprise.
|
|
|
|
|
When using CRichEditCtrl, you can catch the ENM_CHANGE message when you want to be notified of text changes.
But, I'm using CRichEditView inside an MDI-application. How can I get notified of text changes?
I don't want to catch WM_KEYUP cause then I have to catch all events like WM_LBUTTONUP, WM_RBUTTONUP, drag&drop events, copypaste events, ...
And when I want to add a message/event handler, there's no such thing as a ENM_CHANGE event.
using: [VISUAL STUDIO 6.0 sp5] [WIN98/2]
|
|
|
|
|
You should look for the EN_CHANGE notification. The ENM_CHANGE flag is used in conjunction with EM_SETEVENTMASK message to let the rich edit control you want to receive EN_CHANGE notifications.
Chris Richardson
C/C++ Include Finder[^]
|
|
|
|
|
Hi,
Where can I find some doc or some link to a site, where explains some good thecnics about GUI "database" app design ( for desktop applications) ?
Thanks in advance
Braulio
Ps.: I want to use Disconnected dataset in my apps.
|
|
|
|
|
Given a Line (CPoint from, CPoint to), how to determine if a CPoint p belongs to the line?
Thanks in advance for any lights.
[]s
Crercio O. Silva / DBTools Development
http://www.dbtools.com.br
|
|
|
|
|
|
If I have a modal dlg, and post a message to the parent, can it send me back the results (by passing in the data through a member function of my dlg in the ONMessageHandler), so that I can communicate back and forth and display info returned from the parent when I ask for it? Then when I am all done, I dismiss it....I would test it out but it needs a lot of machinery to put into place and I was wondering if its obvious that this will/wont work....?
Appreciate your help,
ns
|
|
|
|
|
ns wrote:
can it send me back the results (by passing in the data through a member function of my dlg
yes. just be careful of infinite loops (where posting a message causes an action that causes the same message to be posted again).
-c
When history comes, it always takes you by surprise.
|
|
|
|
|
MAny thanks. I plan to display a sequence of images in the cDialog which are sent from the parent in response to the users request from the Cdialog. For some reason I had thought that since it was modal it couldnt be dynamically refreshed unless it was dismissed and reModal-ed with the new info....
Appreciate your help,
ns
|
|
|
|
|
If you want to maintain a synchronous conversation, use SendMessage() instead of PostMessage() .
Yes, I'm back (after an 8 week medical emergency).
/ravi
Let's put "civil" back in "civilization"
http://www.ravib.com
ravib@ravib.com
|
|
|
|
|
Good point. Thanks.
I was wondering where you went to! Hope you're feeling better. Take care!!
Appreciate your help,
ns
|
|
|
|