Hello Michel!
Does the following code the job?
*-- Retrieves local computer name from registry
PROCEDURE retrievecomputername
local lcMachineName,lnLen,llRetVal
declare GetComputerName in WIN32API string @,long @
lcMachineName=space(200)
lnLen=200
llRetVal=GetComputerName(@lcMachineName,@lnLen)
return
iif(llRetval,left(alltr(lcMachineName),len(alltr(lcMachineName))-1),.Null.)
ENDPROC
Have a happy day,
Vladimir Shevchenko
P.S. Sorry, if too late ;), i'm not have permanent connection
> This maybe done by using WIN32API and/or NET32API. However, NET32API will
> only work under NT. But, as mentioned by Tony, you can get the user name
> with the sample he gave you. You can also find a similar sample in the
> Knowledge Base WIN32API category. As for the machine name, I'm not sure
if
> this is doable.
>
* Human is a question asked by birth and answered by death. Machine is another kind of question with another kind of answer