|
|
valerie99 wrote:
c:\dev\c++\billing\voldisc\voldiscdlg.cpp(592)
You are calling new on this line, and there is no matching delete to match it.
"You're obviously a superstar." - Christian Graus about me - 12 Feb '03
"Obviously ??? You're definitely a superstar!!!" - mYkel - 21 Jun '04
"There's not enough blatant self-congratulatory backslapping in the world today..." - HumblePie - 21 Jun '05
Within you lies the power for good - Use it!
|
|
|
|
|
that works!
more question ......what about this :
{435} client block at 0x00FC27A8, subtype 0, 28 bytes long.
a CPtrList object at $00FC27A8, 28 bytes long
{434} normal block at 0x00FD8400, 40 bytes long.
Data: <binaryfield> 42 69 6E 61 72 79 46 69 65 6C 64 00 00 00 00 00
c:\dev\c++\billing\voldisc\voldiscdlg.cpp(1169) : {433} normal block at 0x00FD8158, 612 bytes long.
Data: < a P W > DC AE 61 00 50 8B FD 00 57 04 00 00 0C 00 00 00
and the 202020202020.......thank you and have a greatweekend!
|
|
|
|
|
Just double click on the "c:\dev\c++\billing\voldisc\voldiscdlg.cpp(1169)" line and it will take you to the leaky object.
He is smart. He will make our Windows go.
|
|
|
|
|
Hello gurus,
I'm currently rewriting a 20 years old 2D game. The game I rewrite is BubbleBobble for the TI-68K platform in standard C (C99). I ask my questions on this forum because it might interest other people and I don't know where to find the answers.
I would like to know where I can get information about old fashion 2D games programming for the following things:
- Physics of sprites:
* Jumping of sprites with detection of elements of the map (player, ennemies and bosses)
* Collision detection between sprites of different natures and sizes (player/ennemy/bubbles)
* Collision detection with the elements of the map (mainly walls)
- AI:
* Tracking algorithms with path-finding: that is ennemies follows the player and avoid obstacles when encounting them
* sentinel movements
Thanks in advance for the help.
Best regards.
There is no spoon.
|
|
|
|
|
you have to make a sprite manager for sprite collision, etc...
buy a book something like Game programming in 24h or lesson it`s a good book of 2D game programming
|
|
|
|
|
There are lots of game programming sights on the net that have tons of code for doing every thing you are looking for.
Some good keywords to search for: Graphics, Gems.
"Graphics Gems" are a series of books on graphics algorithms, and the code is online.
There's also another series of books with "Gems" in the title that covers: graphics, AI, collision detection, sprite management, ect...
INTP
"The more help VB provides VB programmers, the more miserable your life as a C++ programmer becomes."
Andrew W. Troelsen
|
|
|
|
|
Hi,
I am using Matlab C++ Math library in my codes. I want to use randn("state",0) to reset the state of the generator. But when I run the program, I got run time error, unhandled execption.
Is there anyone who can help me?
Thanks a lot
Chenyu
|
|
|
|
|
Hello everyone.
Is it possible to make a MFC application using MySql as the source database in .Net enviroment to run in a computer which isn't installed .net runtime?
If the answer is yes, could anybody tell me how to do it please? And also how to connect with mysql database in a MFC application please?
Thanks in advance
Asura
|
|
|
|
|
Ming Luo wrote:
Is it possible to make a MFC application using MySql as the source database in .Net enviroment to run in a computer which isn't installed .net runtime?
Yes, you just wouldn't be able to test it effectively.
Ming Luo wrote:
If the answer is yes, could anybody tell me how to do it please? And also how to connect with mysql database in a MFC application please?
Create a DSN and then look at the MFC classes CRecordset and CDatabase , or the ODBC API if you are not using MFC.
|
|
|
|
|
DavidCrow wrote:
Ming Luo wrote:
Is it possible to make a MFC application using MySql as the source database in .Net enviroment to run in a computer which isn't installed .net runtime?
DavidCrow wrote:
Yes, you just wouldn't be able to test it effectively.
I am a quite new C++ learner. Could you tell me how to make it please??
Asura
|
|
|
|
|
I'm trying to set up info tips for different subitems in a CListView in Report mode. I can catch the LVN_GETINFOTIP when you hover over subitem 0, and correctly display the text I want. But hovering over any other subitem doesn't produce the notify. It would seem that the method CListView::SetInfoTip might do what I want, but it fails (returns false) when I invoke it, and I have no idea why.
I have an application manifest, and I am using version 6 of ComClt32.dll. I've set the extended style to include LVS_EX_INFOTIP.
I'd like to get this API working. Alternatively, if there's some way to get the LVN_GETINFOTIP notify when hovering over a different sub-item, that would do it too.
thanks,
Stache
|
|
|
|
|
The docs say that LVN_GETINFOTIP is only generated for the first item.
As for SetInfoTip, make sure that you are using a wide string. I had the same problem only to find out later that I was passing a ANSI string when it expected a wide string.
-Atul, Sky Software http://www.ssware.com
Shell MegaPack For ActiveX & .Net - Windows Explorer Like Shell UI Controls
|
|
|
|
|
Ok, I think I've done all the manifest stuff correctly. DLLGetVersion on "comctl32.dll" reports Major Version 6, Minor Version 0, Build 2900, Platform 2.
Here's the actual code fragment, since at this point, I think I must be missing something blindingly obvious:
LVSETINFOTIP sit;<br />
sit.cbSize = sizeof( sit );<br />
sit.dwFlags = 0;<br />
sit.iItem = 1;<br />
sit.iSubItem = 1;<br />
sit.pszText = L"fake primary info tip";<br />
<br />
CString str = m_ListCtrl.GetItemText( 1, 1 );<br />
<br />
BOOL bResult = m_ListCtrl.SetInfoTip( & sit );
The extended style includes LVS_EX_INFOTIP and LVS_EX_LABELTIP, and I've tried either, both or none with no difference in results.
Any insight would be greatly appreciated!
thanks,
Stache
|
|
|
|
|
Hi I need to write a small console application that goes through all the entries and appends a character to the caption of every resource id string. Does anyone have some sort of example that could be useful or anything else that could help me get started?? Libraries I should use to read a an etry from a table might help. ok thanks
newbie0415
|
|
|
|
|
Given the following format:
STRINGTABLE PRELOAD DISCARDABLE
BEGIN
ID1 "GymScores"
ID2 "Ready"
END
STRINGTABLE DISCARDABLE
BEGIN
ID_INDICATOR_EXT "EXT"
ID_INDICATOR_CAPS "CAP"
ID_INDICATOR_NUM "NUM"
ID_INDICATOR_OVR "OVR"
ID_INDICATOR_REC "REC"
ID_INDICATOR_ITEMCOUNT "9,999 items"
END You would need to read each line of the file until you find a line starting with "STRINGTABLE." Skip the next line that starts with "BEGIN," and process the next N lines until you encounter one that starts with "END." Since there can be multiple STRINGTABLE/BEGIN/END sections, you'll need to do this in a loop. Make sense?
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
I want to create a file mapping object, map it writable to a view and write some data to the shared area, and then give the file mapping object to the clients for read-only. To be able to first write to the shared area, I have to use PAGE_READWRITE with CreateFileMapping, but with this the clients can call MapViewOfFIle with FILE_MAP_WRITE and write to the shared area.
Any idea how I can avoid create a file mapping object and still write to it once and only once?
Thanks for any ideas.
|
|
|
|
|
typo: take out that "avoid" from there, my question is:
how I can create a file mapping object and map it writeable the first time and only read-only for any other views?
|
|
|
|
|
Hi
I need to be able to handle the ondestroy message in the view to clear up memory. However, If I close the app by clicking on the cross (top right corner of SDI app) the view does not get this message.
Is there another elegant way to handle this ordect that the view is being destroyed.
tcss
|
|
|
|
|
tcss wrote:
However, If I close the app by clicking on the cross (top right corner of SDI app) the view does not get this message.
Actually it does. Something else is awry here. Perhaps you have altered the default message-routing mechanism.
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
Kudu's to you David.
I checked through the code and the ODestroy macro was commented out. works again.
Must be the little elfs at work again.
Many thanks.
|
|
|
|
|
hi ,
i am making a spell checker program in VC++ i have to take a text file as a input from this file i have to seperate paragraphs sentences and words and check them against the dictionary text file. The problem i am facing is that i am not able to seperate the paragraphs sentences and word
can anyone help ?????
-- modified at 12:06 Friday 9th September, 2005
|
|
|
|
|
if you are just spell checking ( matching up words ), you simply need to scan (have a look at strtok ) the text for spaces, and take each word and send it to your dictionnary.
if you want to go further, and be able to make the distinction between declination of words ( singular, plural, spelling, ... ) you will need to do ( a lot ) more work.
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|
|
Hi, I am having problem replacing the default icon to my own in my SDI app.
I have tried some of the following:
1) edit the code: CSingleDocTemplate* pDocTemplate;
pDocTemplate = new CSingleDocTemplate(
IDR_MAINFRAME,
RUNTIME_CLASS(CReminderAlarmDoc),
RUNTIME_CLASS(CMainFrame), // main SDI frame window
RUNTIME_CLASS(CReminderAlarmView));
AddDocTemplate(pDocTemplate);
replace 'IDR_MAINFRAME' to new icon id. Did not work. When running, I got message ' failed to create empty document'.
2) in devstudio resource editor, copy-paste the new icon into the IDR_MAINFRAME icon. Did not work. Still show the default icon.
3) open the .rc file in text mode, manually point the IDR_MAINFRAME to the new icon file, rather than the default. Still show the default icon.
Note that I always do clean/rebuild all in case the image is still left in the exe file but still no luck.
I think I also tried some other stuff but better not to go on.
Eventually, (I do not remember what I did) the app suddenly is showing the right icon although the resolution is poor. However I could not reproduce the result.
Can any big expert shed some light for me??? Very frustrated...
|
|
|
|
|
Using the resource editor (as you tried) you can replace the icon. Be sure to change both the 32x32 and 16x16 icons (selected from a combo box near the top of the resource editor).
Good luck.
Karl - WK5M
PP-ASEL-IA (N43CS)
<kmedcalf@ev1.net>
PGP Key: 0xDB02E193
PGP Key Fingerprint: 8F06 5A2E 2735 892B 821C 871A 0411 94EA DB02 E193
|
|
|
|