Description: unit Unit1
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls
type
TForm1 = class(TForm)
Button1: TButton
Edit1: TEdit
Button2: TButton
procedure Button1Click(Sender: TObject)
procedure Button2Click(Sender: TObject)
private
{ Private declarations }
public
{ Public declarations }
end
var
Form1: TForm1
implementation
{$R*.dfm}
uses Registry, MMSystem, DDEMAN, ClipBRD
procedure TForm1.Button1Click(Sender: TObject)
var
SerialNum:Dword
a,b: Dword
Buffer: array [0..255] of char
Num:string
begin
GetVolumeInformation( C:\ , nil,0,@SerialNum,a,b,nil,0)
Num:=IntToHex(HiWord(serialNum),4)+--+ IntToHex(LoWord(SerialNum),4)
Edit1.text:=(Num)
end
procedure TForm1.Button2Click(Sender: TObject)
Var
buffer:array [0..255] of char
buffsize:Dword
begin
buffsize:=sizeOf(Buffer)
GetUSERNAME(@buffer,buffsize)
ShowMessage(buffer)
end
end.
To Search:
File list (Check if you may need any files):
Project2.cfg
Project2.dof
Project2.dpr
Project2.exe
Project2.res
Unit1.dcu
Unit1.dfm
Unit1.pas
Unit1.~dfm
Unit1.~pas