• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1466
  • Last Modified:

Cannot read user environment variables within Citrix Xenapp 6

Dear Experts,

I'm trying to script some stuff to configure a user's printer settings based on the physical location (subnet) of a workstation.

I've found a great tool called "ReconnAct" that is started in a loginscript. This tool creates 2 variables under the "user environment variables" called CURRENT_CLIENTIP and CURRENT_CLIENTNAME. I can use these variables to compare somebody's subnet so I can change his printing preferences accordingly.

After I login I can see that these variables are indeed created (visible in the system properties->Environment Variables"). However, if i try to read them from a script, they seem to be non-existent. Also, when I type the SET command in a commandprompt these values do not appear.

Does Citrix somehow invoke with these settings or am I missing something else?

The server is a Windows Server 2008 R2 with Citrix Xenapp 6, all 64 bit.

  • 3
1 Solution
I would normally create a citrix policy that is applied to a subnet that creates the printers.

So you would create a policy for each subnet and inside each policy you would have the printers for that subnet and then apply it only to that subnet or range.

SupracomAuthor Commented:

Thanks for your response. However, creating printers is not the only thing I would like to do. I must also import some config files and load various registry entries.

So, any other ideas?

Kind regards
SupracomAuthor Commented:
I ended up using Kixstart to read out the user environment variables direct from the registry. Works very well, just had to dig in on how to do that.

SupracomAuthor Commented:
Found another way of fixing this myself.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now