MSI Factory 2.3

Drive.GetInformation

Drive.GetInformation

This is the first topic This is the last topic  

Drive.GetInformation

This is the first topic This is the last topic  

OverviewExamples

table Drive.GetInformation (

string Drive )

Example 1

tDriveInfo = Drive.GetInformation("C:\\");

Gets the drive information from the 'C:' drive, and stores it in the table "tDriveInfo".

Example 2

-- Set this value to the expected serial number of the

-- drive that the script will run from.

Expected_Serial = 123456789;

 

-- Gets the source drive's current serial number

Current_Serial = Drive.GetInformation(_SourceDrive).SerialNumber;

 

-- Compares the two serials and, if different, terminates the app.

if (Current_Serial ~= Expected_Serial) then

   Dialog.Message("ERROR", "This is an unauthorized copy of the original application, and will shut down.", MB_OK, MB_ICONSTOP);

   Application.ExitScript();

end

Gets the source drive's serial number and compares it to the 'expected' serial number.  If they don't match, the script is terminated.

See also: Related Actions


Learn More: Indigo Rose Software - MSI Factory - Buy Now - Contact Us