Getting the Serial Number of the User's computer
userev at canelasoftware.com
Wed Dec 10 13:30:46 CST 2008
On Dec 9, 2008, at 10:59 AM, Paul Looney wrote:
> How can I retrieve the computer serial number in OS X, Vista and
> Linux from Rev?
> Thanks in advance, I appreciate it.
This is how we get the serial on OS X using shell. It is very fast
and has the added benefit of identifying refurb macs.
put empty into tSerial
put shell("/usr/sbin/system_profiler SPHardwareDataType")
repeat with x=1 to the number of lines of tResult
if "Serial Number" is in line x of tResult then put
line x of tResult into tSerial
if tSerial is not empty then put the last word of tSerial
if tSerial is empty then put "Refurb Mac" into tSerial
More information about the use-livecode