Connecting Tech Pros Worldwide Help | Site Map

trying to run subroutine from a different file

Newbie
 
Join Date: Sep 2009
Posts: 15
#1: Oct 16 '09
I am trying to run the following code in dspMC_AxisWorksDlg.cpp from trial.h. I have a button and when I press the button, I want it to execute bool CdspMC_AxisWorksDlg::ValidExecData().

If anyone could give me direction on how to solve this problem it would be greatly appreciated.

Quote:
//trial.h

#pragma endregion
private: System::Void button1_Click(System::Object^ sender, System::EventArgs^ e) {
CdspMC_AxisWorksDlg::ValidExecData();
}

Quote:
//trial.cpp
#include "trial.h"

int main()
{

}

Quote:
// dspMC_AxisWorksDlg.cpp : implementation file

// include statements are here but not shown

bool CdspMC_AxisWorksDlg::ValidExecData()
{
//code
}
Reply

Tags
different .cpp, execute subroutine