Click here to Skip to main content
15,917,702 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Maskededit control Pin
David Crow15-Apr-04 10:14
David Crow15-Apr-04 10:14 
GeneralRe: Maskededit control Pin
C++NewBe15-Apr-04 10:19
C++NewBe15-Apr-04 10:19 
GeneralRe: Maskededit control Pin
David Crow15-Apr-04 10:33
David Crow15-Apr-04 10:33 
GeneralRe: Maskededit control Pin
C++NewBe15-Apr-04 10:42
C++NewBe15-Apr-04 10:42 
GeneralSerialize Pin
Demian Panello15-Apr-04 5:48
Demian Panello15-Apr-04 5:48 
GeneralMulti threading Pin
dreamerzz15-Apr-04 5:13
dreamerzz15-Apr-04 5:13 
GeneralRe: Multi threading Pin
David Crow15-Apr-04 7:16
David Crow15-Apr-04 7:16 
GeneralRe: Multi threading Pin
dreamerzz15-Apr-04 20:38
dreamerzz15-Apr-04 20:38 
Hi,

I have read the article that you gave me and have tried implementing the methods into my program.. however, that are still one error which i hope u could help me..

<br />
void CUpdateView::OnUpdatedb() <br />
{<br />
        // TODO: Add your control notification handler code here<br />
        running = true;<br />
        AfxBeginThread(run, this);<br />
<br />
}<br />
<br />
UINT CUpdateView::run(LPVOID p)<br />
{<br />
	CUpdateView* pView = (CUpdateView*)p;<br />
	pView->run();<br />
<br />
	double propa_update = 0.814;<br />
	double resp_update = 0.205;<br />
	double link_update = 1.19;<br />
<br />
	do<br />
	{<br />
		//get a pointer to the recordset<br />
		CUpdateDoc* pDoc = GetDocument();		UseRecordset* pUseRecordset	= &pDoc->m_UseRecordset;<br />
<br />
		//Allows the current record to be edited<br />
		pUseRecordset->Edit();<br />
			<br />
		//increment in the values from the database<br />
		pUseRecordset->m_propatime = pUseRecordset->m_propatime*propa_update;<br />
		pUseRecordset->m_respondtime = pUseRecordset->m_respondtime*resp_update;<br />
		pUseRecordset->m_link = pUseRecordset->m_link*link_update;<br />
		<br />
		//Saves the current changes to the database<br />
		pUseRecordset->Update();<br />
<br />
		//Reruns the current SQL query to refresh the recordset<br />
		pUseRecordset->Requery();<br />
	}while(check_exit!=0);<br />
<br />
	return 0;<br />
}<br />
<br />
void CUpdateView::OnExit() <br />
{<br />
	running = false;<br />
}


The part that i have it bold is giving mi the error..

the error message is :

'CUpdateView::GetDocument' : illegal call of non-static member function
This problem is it because i have the UINT CUpdateView::run(LPVOID p) declare as static?


see declaration of 'GetDocument'
My declaration is CUpdateDoc* GetDocument(); in CUpdateView Class

GeneralRe: Multi threading Pin
David Crow19-Apr-04 2:28
David Crow19-Apr-04 2:28 
GeneralRe: Multi threading Pin
dreamerzz20-Apr-04 2:14
dreamerzz20-Apr-04 2:14 
QuestionVisual Basic-like editor for VC++ 6.0? Pin
AAntix15-Apr-04 4:55
AAntix15-Apr-04 4:55 
AnswerRe: Visual Basic-like editor for VC++ 6.0? Pin
toxcct15-Apr-04 6:54
toxcct15-Apr-04 6:54 
GeneralRe: Visual Basic-like editor for VC++ 6.0? Pin
David Crow15-Apr-04 7:13
David Crow15-Apr-04 7:13 
GeneralRe: Visual Basic-like editor for VC++ 6.0? Pin
AAntix15-Apr-04 7:21
AAntix15-Apr-04 7:21 
AnswerRe: Visual Basic-like editor for VC++ 6.0? Pin
Prakash Nadar15-Apr-04 17:55
Prakash Nadar15-Apr-04 17:55 
QuestionPlug-in to read HTML page for IE? Pin
Pauwll15-Apr-04 4:41
Pauwll15-Apr-04 4:41 
Generalvoid main Pin
dreamerzz15-Apr-04 4:38
dreamerzz15-Apr-04 4:38 
GeneralRe: void main Pin
jmkhael15-Apr-04 4:55
jmkhael15-Apr-04 4:55 
GeneralRe: void main Pin
dreamerzz15-Apr-04 5:17
dreamerzz15-Apr-04 5:17 
GeneralRe: void main Pin
jmkhael15-Apr-04 5:25
jmkhael15-Apr-04 5:25 
GeneralRe: void main Pin
dreamerzz15-Apr-04 5:30
dreamerzz15-Apr-04 5:30 
GeneralRe: void main Pin
David Crow15-Apr-04 7:11
David Crow15-Apr-04 7:11 
GeneralRe: void main Pin
basementman15-Apr-04 5:29
basementman15-Apr-04 5:29 
GeneralRe: void main Pin
Joan M15-Apr-04 5:47
professionalJoan M15-Apr-04 5:47 
GeneralRe: void main Pin
dreamerzz15-Apr-04 5:52
dreamerzz15-Apr-04 5:52 

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.