Accept from environment in thin client



Running on a Citrix server with a thin Client I need to accept CLIENTNAME from the local computer. We normally use this line to accept Environment variables.

Accept w-clientname from Environment "CLIENTNAME"

But when we run this line, we got nothing in the var W-CLIENTNAME. When inspected the client in a Command prompt, I can see that the CLIENTNAME is filled  with name of the local computer. Therefor I think that the reason for not geting anything in the w-clientname, is that the Accept is executed on the server and not on the client. Could anybodt tell me how to force the accept to run on the client ?








  • Use C$SYSTEM with this flag .. CSYS-DESKTOP (value 128): This option is for applications running in the thin client environment. It indicates that the application wants to run the command on the client system rather than the application server. When the command executes, unless the CSYS-ASYNC option is also specified, the thin client appears to "hang" while the application waits for the command's termination status. This behavior can be avoided with the CSYS-ASYNC flag. The CSYS-ASYNC flag causes the command to be run asynchronously.

  • Thanks, but how do I get anything back from that c$system command?

    And the command


    is not a DOS command, I think I have to write to command in another way to get set SET parameter of CLIENTNAME



  • we also have Citrix and accept "Clientname" works for us:

              accept env-clientname from environment "CLIENTNAME".

              accept env-compname   from environment "COMPUTERNAME".

    Clientname is the Computer which is connected to the citrix-server

    Computername is the Citrix-Server-Name.

    If the Computer use no Citrix... Clientname is not set and only Computername is used.

    For that we Check if the Computername is a Citrix-Server (using Naming-Convention)

              if env-compname(4:3) = "CIX"

                 move env-clientname to env-compname.