Include file semantics?
Compiler error output, 1>MainFrm.cpp 1>z:\. . . . viewswitchview.h(19) : error C2143: syntax error : missing ';' before '*' 1>z:\. . . . viewswitchview.h(19) : error C4430: missing type...
View Articlespiral matrix
Hi guys.Although it may sound like a noob question ,how can i make a function that generates a spiral matrix but it MUST have this prototype void f(int *a,int m,in n).My program works fine but like i...
View Articlecreating an instance of a mfc derived class.
I need to create an object of a mfc derived CFormView class that's not in the doc/template (a second view class). but it was generated with a protected ctor. Here's the code explanation with comments....
View ArticleWatch Window is Gone
Forum, Visual c++ 2010 Express Somehow the watch window is no longer shown in the debugger. It used to be available and I am stopped at a breakpoint. Is there a way to turn it back on or restore it?...
View ArticleProblem with PostMessage() in CView derived class
Hello, I am trying to use PostMessage() to send a message to my CView derived class. I have a project that is SDI and my view class is called CMyView, which is derived from CFormView. Here is the...
View ArticleMaximized MDI Window Title Bar Behaviour
I'm writing an MDI Window and trying to get it's behaviour similar to what I thought was the default. I have attached two images as an example. The images on the left are examples of what I'm trying to...
View ArticleDebug-only AfxMessageBox
Hi, I am looking for a function like AfxMessageBox, but will only available in Debug Version, to display some error messages. I have thought of TRACE, but it will only dump the error message in the...
View ArticleWhere are the MSBuild Error Codes?
Hello, :) I'm using VC++ 2010 express, on Windows 7, 64 bit OS. I'm getting MSBuild errors, specifically MSB6006. However, when I looked for error codes, I could not find MSBuilt error codes that go...
View ArticleLoading bitmap in particular way
I have a function that essentially takes a screen shot and saves a pointer to it as a structure. I would like to use the same structure for bitmaps that I load from files. Code: typedef struct...
View ArticleHashing problem with overloaded operator
I've got a hasing template function that is giving me the error '!=' : no operator found which takes a left-hand operand of type 'StateData' (or there is no acceptable conversion). I have a StateData...
View Article[RESOLVED] Creating DialogBar with my own controls (MFC)
I'm turning mad with a little problem with Visual Studio 2008 and MFC. I'm working on a project actually and I'm trying to create an SDI Application. Right, now I want to add a dockable DialogBar....
View ArticleHow to search for an object that has been hashed
Ran into a logic issue with my hashing program that stores a state object. It's storing the object just fine now but I need to be able to search for it. The user enters a state name and I'm supposed to...
View ArticleFurther Reading
Ok, so I've just finished reinforcing my basics by reading C++ Primer Plus, also have taken a few introductory courses ( which frankly,were a bit lacking) and Now I want to further enhance my knowledge...
View ArticleHeap Corruption during run time.
Hello, I am having a problem with my code. I am trying to delete an array, after I created a bigger one, and copied all the values from the previous to the new one, but when i try to delete the old...
View ArticleHelp! ambiguous symbol error
Hello, Here is the error I am getting: 1>d:\testproject\gdiplusrenderer.h(61): error C2872: 'Font' : ambiguous symbol 1> could be 'c:\program files (x86)\microsoft visual studio...
View ArticleAfxRegisterWndClass() causes crash
Hello, My app crashes when I attempt to create a CWnd as shown below. I am attempting to create the CWnd with a a parent of type CFormView. Does anyone know why this might be crashing? Code:...
View ArticleHelp getting started in making simple drag-and-drop application in C++
Hey guys. First of all, GUI is not my thing - all of the programming I've done in the past has been pretty back-end systems/algorithms, etc. Have been out of it for a few years, and want to get back...
View ArticleCreateInstance fails on xp
i created an com client that try to create com server with the command CreateInstance. at win 7 it works fine (both 32 and 64 bit). but with xp it fails. someone know what is the problem? i created the...
View ArticleMFC and visual studio 8
PL guide that .. Is MFC-AppWizard included in visual studio 2010 and 2012 professional ?
View Article