GetUserName

The 'name' field (in a login dialog) can be initialized with the name by which the user is known in Windows.
You can try to find this name in the registry but you better let Windows do it for you, using the GetUserName function.

{windows.i}
 
   DEFINE VARIABLE NAME AS CHARACTER NO-UNDO.
   RUN WinUserName(OUTPUT NAME).
   fill-in_name:SCREEN-VALUE = NAME.
 
PROCEDURE WinUserName :
   DEFINE OUTPUT PARAMETER NAME AS CHARACTER.
 
   DEFINE VARIABLE nr AS INTEGER NO-UNDO INITIAL 100.
   DEFINE VARIABLE ReturnValue AS INTEGER NO-UNDO.
   NAME = FILL(" ", nr).
   RUN GetUserName{&A} IN hpApi (INPUT-OUTPUT NAME,
                                 INPUT-OUTPUT nr,
                                 OUTPUT ReturnValue).
END PROCEDURE.

notes

The 'fill' statement is important because it allocates memory. Windows hardly ever allocates memory for you.
There is one important drawback: the function GetUserName does not exist in 16-bit windows. If you are using a Progress version prior to 8.2 on Windows 95 you can still use this function but you will have to thunk it.