Subject Re: Computer serial number
From Mervyn Bick <invalid@invalid.invalid>
Date Fri, 19 Apr 2024 23:27:46 +0200
Newsgroups dbase.getting-started

On 2024/04/19 19:14, RACHHPAL S GILL wrote:
> Thanks Akshat
> The command works but could not find serial.txt file

I suggest a different approach.

To save the serial number to a file

set procedure to :duflp:miscapi.prg
f = new file()
f.create('serialno.txt')
f.puts(getSerialNumber())
f.close()
close procedure :duflp:miscapi.prg


To check the serial number

f = new file()
if f.exists('serialno.txt')
    f.open('serialno.txt')
    cNo = f.gets()
endif
?cNo
f.close()

You need to add code to deal with the serialno.txt not found or with the
incorrect serial number returned.

Mervyn.