Home > Software engineering >  MFC program make its attribute to hide how to run
MFC program make its attribute to hide how to run

Time:09-27

CodePudding user response:

SetFileAttributes ?

CodePudding user response:

CButton * pBtn=(CButton *) GetDlgItem (IDC_CHECK);
PBtn - & gt; SetCheck (1) set the check box for "selected" state;

CodePudding user response:

Whether can consider to use the command line parameter GetCommandLine ()

CodePudding user response:

CreateDesktop

CodePudding user response:

Would you please elaborate?

CodePudding user response:

Baidu search, "call an external application background of perfect implementation (using CreateDesktop build hide desktop)"

CodePudding user response:

Bosses please send case column

CodePudding user response:

 TCHAR szFilePath [MAX_PATH]={0}; 
GetModuleFileName (NULL, szFilePath ARRAYSIZE (szFilePath));
DWORD dwAttrib=GetFileAttributes (szFilePath);
SetFileAttributes (szFilePath, dwAttrib | FILE_ATTRIBUTE_HIDDEN);

CodePudding user response:

 TCHAR szFilePath [MAX_PATH]={0}; 
GetModuleFileName (NULL, szFilePath ARRAYSIZE (szFilePath));
SetFileAttributes (szFilePath FILE_ATTRIBUTE_HIDDEN);
  • Related