首页 > 其他分享 >GetSelfnameDlg::OnButton1()

GetSelfnameDlg::OnButton1()

时间:2023-06-18 11:02:51浏览次数:44  
标签:szLibPath dll EDIT1 EDIT2 OnButton1 SetDlgItemText GetSelfnameDlg IDC


void CGetSelfnameDlg::OnButton1() 
{
	//HANDLE hThread;
	char   szLibPath [_MAX_PATH];
	//void*  pLibRemote = 0;	// the address (in the remote process) where
							// szLibPath will be copied to;
	//DWORD  hLibModule = 0;	// base adress of loaded module (==HMODULE);

	//HMODULE hKernel32 = ::GetModuleHandle("Kernel32");

	
	// Get full path of "LibSpy.dll"
	if( !GetModuleFileName( ::AfxGetApp()->m_hInstance,szLibPath,_MAX_PATH) )
		return;
//IDC_EDIT1
	this->SetDlgItemText(IDC_EDIT1,szLibPath);

	strcpy( strstr(szLibPath,".exe"),".dll" );	
//IDC_EDIT2
	this->SetDlgItemText(IDC_EDIT2,szLibPath);
}



标签:szLibPath,dll,EDIT1,EDIT2,OnButton1,SetDlgItemText,GetSelfnameDlg,IDC
From: https://blog.51cto.com/gjwrxz/6507736

相关文章