Click here to Skip to main content
15,942,756 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: ISSUE - TCP/IP sockets in MFC VS2017 Pin
Victor Nijegorodov22-Nov-17 10:07
Victor Nijegorodov22-Nov-17 10:07 
QuestionFiguring Out How to Test Code Pin
Member 1352762517-Nov-17 16:48
Member 1352762517-Nov-17 16:48 
AnswerRe: Figuring Out How to Test Code Pin
Richard MacCutchan17-Nov-17 21:43
mveRichard MacCutchan17-Nov-17 21:43 
GeneralRe: Figuring Out How to Test Code Pin
Member 1352762519-Nov-17 10:34
Member 1352762519-Nov-17 10:34 
GeneralRe: Figuring Out How to Test Code Pin
Victor Nijegorodov19-Nov-17 21:07
Victor Nijegorodov19-Nov-17 21:07 
GeneralRe: Figuring Out How to Test Code Pin
Richard MacCutchan19-Nov-17 21:49
mveRichard MacCutchan19-Nov-17 21:49 
GeneralRe: Figuring Out How to Test Code Pin
CPallini21-Nov-17 21:51
mveCPallini21-Nov-17 21:51 
AnswerRe: Figuring Out How to Test Code Pin
jschell20-Nov-17 6:26
jschell20-Nov-17 6:26 
Between your subject and your post it is not clear what you want to do.

If you want to formally 'test' your code then
1. Research unit test libraries and select one
2. Add the library to your project (not part of production delivery)
3. Use the library and write unit test code to test both happy path, boundaries and failure cases.
4. Run the unit tests.

If you want to information test your code then
1. Create ANOTHER project
2. COPY your class to it
3. Add a second class with a main method
4. Write a number of methods that exercise the code.
5. Build and run it.
6. If you make changes copy it back.

If you already know the class has a problem and you cannot not determine what the problem is
1. Find a way to replicate the problem (see two above examples.)
2. As per the other posts find a debugger and figure out how it works.
3. Step through your code in the debugger to find the problem.

Note that if you have large application and you already know that your class is failing then attempting to debug the entire application just so you get to the class is not very effective.
AnswerRe: Figuring Out How to Test Code Pin
ThatsAlok20-Nov-17 20:10
ThatsAlok20-Nov-17 20:10 
QuestionC++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 3:15
charlieg16-Nov-17 3:15 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Jochen Arndt16-Nov-17 3:51
professionalJochen Arndt16-Nov-17 3:51 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 5:20
charlieg16-Nov-17 5:20 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Richard MacCutchan16-Nov-17 4:00
mveRichard MacCutchan16-Nov-17 4:00 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 5:21
charlieg16-Nov-17 5:21 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Richard MacCutchan16-Nov-17 21:28
mveRichard MacCutchan16-Nov-17 21:28 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Maximilien16-Nov-17 5:45
Maximilien16-Nov-17 5:45 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg16-Nov-17 11:11
charlieg16-Nov-17 11:11 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
jschell16-Nov-17 13:27
jschell16-Nov-17 13:27 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg17-Nov-17 7:17
charlieg17-Nov-17 7:17 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
jschell17-Nov-17 10:45
jschell17-Nov-17 10:45 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
CPallini23-Nov-17 22:29
mveCPallini23-Nov-17 22:29 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
charlieg29-Nov-17 11:19
charlieg29-Nov-17 11:19 
GeneralRe: C++ formatting into a buffer - why so elephanting difficult? Pin
CPallini29-Nov-17 11:42
mveCPallini29-Nov-17 11:42 
AnswerRe: C++ formatting into a buffer - why so elephanting difficult? Pin
Rick York25-Nov-17 19:53
mveRick York25-Nov-17 19:53 
QuestionCStatic::Drawitem gets called repeatledly Pin
ForNow15-Nov-17 16:35
ForNow15-Nov-17 16:35 

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.