Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
. . .
compuser
call setUser.bat
. . .
Attribute VB_Name = "login9x"
Declare Function GetComputerName Lib "kernel32" Alias "GetComputerNameA" (ByVal lpBuffer As String, nSize As Long) As Long
Declare Function GetUserName Lib "advapi32.dll" Alias "GetUserNameA" (ByVal lpBuffer As String, nSize As Long) As Long
Sub Main()
comp$ = String$(300, 0): User$ = comp$
k& = GetComputerName(comp$, 300): trimit comp$
k& = GetUserName(User$, 300): trimit User$
Open "SetUser.bat" For Output As #1
Print #1, "set username=" + User$
Print #1, "set computername=" + comp$
Close
End Sub
Sub trimit(a$)
j = InStr(a$, Chr$(0))
If j Then a$ = Left$(a$, j - 1)
End Sub
[code]