VC 代码解释

来源:百度知道 编辑:UC知道 时间:2024/05/21 16:49:49
// TODO: Add the initialization
HINSTANCE hDLL = DX2_Open ();

// TODO: Create the DicomXpress object
m_ppCDicomXpress = new CDicomXpress ((DWORD) this, 1);
m_pDicomXpress = m_ppCDicomXpress->pDicomXpress;

// TODO: Unload the DLL
DX2_Close (hDLL);

// *********************************************************************************************************
// The configuration files are installed to the <Installation Root>\MedX-Config. The path beloww might
// need to be changed based on your individual installation to point to this location.
// *********************************************************************************************************
m_pDicomXpress->InitializeDX("C:\\MedX-Config\\dx.ini");
//Register DICOMXpress
if( m_pDicomXpress->StatusCode == DX_NORMAL_COMPLETION ) m_pDicomXpress->RegisterApplicati

// TODO: Add the initialization
/*
既然下面是关闭dll,那这里应该是打开DLL
不过为什么打开就不知道了,没用过什么MedX
不过这种公式化的东西根本没必要知道为什么
总之必须要做的,直接拷贝就可以了。
*/
HINSTANCE hDLL = DX2_Open ();

// TODO: Create the DicomXpress object
/*
下面2个是创建m_pDicomXpress变量,结构是CDicomXpress中的pDicomXpress,后面的操作主要以CDicomXpress中的pDicomXpress为主
*/
m_ppCDicomXpress = new CDicomXpress ((DWORD) this, 1);
m_pDicomXpress = m_ppCDicomXpress->pDicomXpress;

// TODO: Unload the DLL
/*
关闭DLL,不过创建变量的时候没有用到hDLL,为什么要打开它呢?不能理解,可能在DX2_Open中打开了什么DLL文件,在那个DLL文件中的初始化部分又有什么特殊的代码吧?!谁知道呢!
*/
DX2_Close (hDLL);

// *********************************************************************************************************
// The configuration files are installed to the <Installation Root>\MedX-Config. The path beloww might
// need to be changed based on your individual installation to point to this location.
// *********