Click here to Skip to main content
15,908,111 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralODBC - dbf files - strange error msg Pin
Qadddd13-Jan-04 2:07
Qadddd13-Jan-04 2:07 
GeneralSockets and Memory leak Pin
Member 81460313-Jan-04 2:03
Member 81460313-Jan-04 2:03 
GeneralRe: Sockets and Memory leak Pin
Antti Keskinen13-Jan-04 3:07
Antti Keskinen13-Jan-04 3:07 
GeneralRe: Sockets and Memory leak Pin
Member 81460313-Jan-04 3:53
Member 81460313-Jan-04 3:53 
GeneralRe: Sockets and Memory leak Pin
Antti Keskinen13-Jan-04 6:35
Antti Keskinen13-Jan-04 6:35 
GeneralSimulating copy to clipboard Pin
Anonymous13-Jan-04 1:03
Anonymous13-Jan-04 1:03 
Questiondeveloping a small scripting langauge in VC++ ?? Pin
cyberiafreak13-Jan-04 0:54
cyberiafreak13-Jan-04 0:54 
AnswerRe: developing a small scripting langauge in VC++ ?? Pin
Antti Keskinen13-Jan-04 7:04
Antti Keskinen13-Jan-04 7:04 
If you are trying to build a complete scripting engine, you're in too deep.

I'd suggest that you first attempt to create a simple program that reads text files and draws graphic according to those. When you succeed in this, just implement text-editing and row-manipulation routines to your program and you have precisely what you need.

For a start, first create the specification. Decide what graphic routines you are planning to use: Win32, DirectX, OpenGL or what. Then decide what drawing routines your scripting language supports: can you draw a circle, a rectangle, a triangle or all of these ?
If you resort to Win32, then your task becomes even simpler: just create a parsing function that is able to intepret the scripting language's commands. Then the intepreter calls the appropriate Win32 routine to draw the requested graphic. As the program itself will worry about creating the target window, pencils, brushes etc, then the parser should be quite simple.

For more complex object support, just add a more logic to the parser and make it call several drawing routines if required.

If you are new to Windows-programming, then I suggest purchasing a book by Charles Petzold called Programming Windows. This book is "The Bible" of Windows-programming: it explains every little detail deeply enough for anyone familiar with C/C++ to understand.

If you're out of luck and can't get this book, there are several articles available here at CodeProject. Here is a good place to start looking http://www.codeproject.com/gdi/[^]

-Antti Keskinen

----------------------------------------------
The definition of impossible is strictly dependant
on what we think is possible.
GeneralEMF to SWF Convertor Pin
WzR13-Jan-04 0:53
WzR13-Jan-04 0:53 
GeneralRe: EMF to SWF Convertor Pin
Antti Keskinen13-Jan-04 7:17
Antti Keskinen13-Jan-04 7:17 
GeneralHelp in MDI (reply needed as soon as possible) Please.. Pin
Ruchit Sharma13-Jan-04 0:37
Ruchit Sharma13-Jan-04 0:37 
GeneralRe: Help in MDI (reply needed as soon as possible) Please.. Pin
Roger Allen13-Jan-04 0:54
Roger Allen13-Jan-04 0:54 
GeneralRe: Help in MDI (reply needed as soon as possible) Please.. Pin
Ruchit Sharma13-Jan-04 1:21
Ruchit Sharma13-Jan-04 1:21 
QuestionHow to write ftp server and client for windows in c Pin
shan1213-Jan-04 0:22
shan1213-Jan-04 0:22 
AnswerRe: How to write ftp server and client for windows in c Pin
Selvam R13-Jan-04 1:05
professionalSelvam R13-Jan-04 1:05 
QuestionHow to fix this? Pin
Anthony_Yio13-Jan-04 0:08
Anthony_Yio13-Jan-04 0:08 
AnswerRe: How to fix this? Pin
Prakash Nadar13-Jan-04 0:13
Prakash Nadar13-Jan-04 0:13 
GeneralRe: How to fix this? Pin
Anthony_Yio13-Jan-04 0:24
Anthony_Yio13-Jan-04 0:24 
AnswerRe: How to fix this? Pin
jhwurmbach13-Jan-04 0:23
jhwurmbach13-Jan-04 0:23 
GeneralDifference between nested conditional statements vs non-nested dito Pin
Anonymous12-Jan-04 23:52
Anonymous12-Jan-04 23:52 
GeneralI asked the question, not Anonymous... Pin
Johann Gerell12-Jan-04 23:55
Johann Gerell12-Jan-04 23:55 
GeneralRe: Difference between nested conditional statements vs non-nested dito Pin
Prakash Nadar13-Jan-04 0:07
Prakash Nadar13-Jan-04 0:07 
GeneralRe: Difference between nested conditional statements vs non-nested dito Pin
Anthony_Yio13-Jan-04 0:14
Anthony_Yio13-Jan-04 0:14 
GeneralRe: Difference between nested conditional statements vs non-nested dito Pin
berndg13-Jan-04 2:16
berndg13-Jan-04 2:16 
GeneralRe: Difference between nested conditional statements vs non-nested dito Pin
Johann Gerell13-Jan-04 22:28
Johann Gerell13-Jan-04 22:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.