| | |
Visual c++.net MFC question
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Jan 2007
Posts: 15
Reputation:
Solved Threads: 0
Does anyone use MFC?
I have a problem executing graphics functions.
Any thoughts?
Ross
I have a problem executing graphics functions.
void CMainFrame::OnTimer(UINT idEvent) { idEvent++; //when a time event occurs do some pointG2.y-=3; //graphics pointG=pointG2; TimerEvent(); InvalidateRect(NULL, TRUE); //to call OnDraw } void Csail_boatView::OnDraw(CDC* pDC) { //graphics functions here //they compile OK //OnDraw is called by the even timer above //the graphic funtions fail to work }
Ross
Last edited by ~s.o.s~; Mar 10th, 2007 at 11:25 pm. Reason: Added code tags, learn to use them.
•
•
Join Date: Jan 2007
Posts: 15
Reputation:
Solved Threads: 0
•
•
•
•
>>Any thoughts?
Nope, since you didn't post any relevant code.
void CMainFrame::OnTimer(UINT idEvent) { idEvent++; pointG2.y-=3; pointG=pointG2; TimerEvent(); InvalidateRect(NULL, TRUE); } void Csail_boatView::OnDraw(CDC* pDC) { pDC->MoveTo(pointG); //example fn of many CPoint pt2; //they execute fine when OnDraw pt2.x=xb-x; //is called at window creation pt2.y=yb+3*x; pDC->LineTo(pt2); //they don't work when OnDraw is //called by the OnTimer event above }
Last edited by ~s.o.s~; Mar 10th, 2007 at 11:25 pm. Reason: Added code tags, learn to use them.
![]() |
Similar Threads
- Is "Visual Basic 2005" Express edition .NET? (VB.NET)
- Learning Visual C++ .net 2003 (C++)
- MFC or no MFC that is the question (C++)
- MFC File I/O Philosophy questions/clarifications (C++)
- programming in C using Visual C++.net (C++)
- I need a solution for a opengl thing (C++)
- Microsoft .NET FAQ (ASP.NET)
Other Threads in the C++ Forum
- Previous Thread: sugestion for a project on c
- Next Thread: wireless network programming in c++
| Thread Tools | Search this Thread |
api array arrays based beginner binary c++ c/c++ calculator char char* class classes code compile compiler console conversion count delete deploy desktop directshow dll download dynamic dynamiccharacterarray email encryption error file forms fstream function functions game givemetehcodez google graph gui homeworkhelp homeworkhelper iamthwee ifstream input int integer java lib linkedlist linker linux list loop looping loops map math matrix memory news numbertoword output parameter pointer problem program programming project python random read recursion recursive reference return rpg sorting string strings struct temperature template templates test text text-file tree unix url variable vector video visual visualstudio win32 windows winsock wordfrequency wxwidgets






