rag84dec
Jul 3, 2007, 08:32 PM
Hi,
I want to know from where my executable been executed... For example...
If I execute it from USB I can use the following thing
if(GetDriveType(Exe_name)== DRIVE_CDROM ||
GetDriveType(Exe_name)== DRIVE_REMOVABLE)
print("Not from the local disk");
If I execute it from a directory "like"
Go to start->run->type "\\ip_address\exe_name"... If I execute this then how I will get to know from where I am executing?
The "Winbase.h" has the following things or options
#define DRIVE_UNKNOWN 0
#define DRIVE_NO_ROOT_DIR 1
#define DRIVE_REMOVABLE 2
#define DRIVE_FIXED 3
#define DRIVE_REMOTE 4
#define DRIVE_CDROM 5
#define DRIVE_RAMDISK 6
Which one to select??
Thanks
I want to know from where my executable been executed... For example...
If I execute it from USB I can use the following thing
if(GetDriveType(Exe_name)== DRIVE_CDROM ||
GetDriveType(Exe_name)== DRIVE_REMOVABLE)
print("Not from the local disk");
If I execute it from a directory "like"
Go to start->run->type "\\ip_address\exe_name"... If I execute this then how I will get to know from where I am executing?
The "Winbase.h" has the following things or options
#define DRIVE_UNKNOWN 0
#define DRIVE_NO_ROOT_DIR 1
#define DRIVE_REMOVABLE 2
#define DRIVE_FIXED 3
#define DRIVE_REMOTE 4
#define DRIVE_CDROM 5
#define DRIVE_RAMDISK 6
Which one to select??
Thanks