# Retrieving remote environment variables

**URL:** https://www.finalbuilder.com/forums/t/retrieving-remote-environment-variables/105
**Category:** Discussion
**Created:** [June 8, 2006, 3:10am UTC](https://www.finalbuilder.com/forums/t/retrieving-remote-environment-variables/105 "2006-06-08T03:10:50Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![nirsilgi](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/a6a055/32.png) [@nirsilgi](https://www.finalbuilder.com/forums/u/nirsilgi)
#### Post date: [June 8, 2006, 3:10am UTC](https://www.finalbuilder.com/forums/t/retrieving-remote-environment-variables/105/1 "2006-06-08T03:10:50Z")

</div>

Hi,  
  
I am running a dos command on a remote computer and I want to access the remote WINDIR environment variable? How can I achieve that? If I use %windir% I get the local one.  
  
Thanks,  
NirS

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [June 13, 2006, 3:10am UTC](https://www.finalbuilder.com/forums/t/retrieving-remote-environment-variables/105/2 "2006-06-13T03:10:40Z")

</div>

When you specify the command line for the remote machine, escape the %WINDIR% so that it is not evaluated by finalbuilder, e.g. : %%WINDIR%%
