473,320 Members | 1,990 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

.NET Environment Variables

Here is MY QUESTION:
We have an old COBOL application that presently writes out text flat files to the hard disk using Windows environment variable settings to represent D:\folder\filename.

We have created a similar .NET application and would like to see a code snippet or get instruction on how to have .NET use the Windows ennvironment variables.

(We have SAN drives and Microsoft Cluster environment and need to have a way to address "the drive" to write out data flat files to it. We then manually copy them and use "sneaker net" to an "air gap" LAN for security reasons. thanks.)

--------------------------------
From: BartA Simpson
--------------------------------
From: BartA Simpson

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>c8oqLjA/H0yEU2az8gZQ4A==</Id>
Jul 21 '05 #1
2 1535
BartA Simpson via .NET 247 wrote:
Here is MY QUESTION:
We have an old COBOL application that presently writes out text flat
files to the hard disk using Windows environment variable settings to
represent D:\folder\filename.

We have created a similar .NET application and would like to see a
code snippet or get instruction on how to have .NET use the Windows
ennvironment variables.

(We have SAN drives and Microsoft Cluster environment and need to
have a way to address "the drive" to write out data flat files to it.
We then manually copy them and use "sneaker net" to an "air gap" LAN
for security reasons. thanks.)


static string System.Environment.GetEnvironmentVariable(string). Pass in
the name of the variable you want and this method will return the value of
that variable.
--
Tom Porterfield
MS-MVP MCE
http://support.telop.org

Please post all follow-ups to the newsgroup only.

Jul 21 '05 #2
BartA Simpson via .NET 247 wrote:
Here is MY QUESTION:
We have an old COBOL application that presently writes out text flat
files to the hard disk using Windows environment variable settings to
represent D:\folder\filename.

We have created a similar .NET application and would like to see a
code snippet or get instruction on how to have .NET use the Windows
ennvironment variables.

(We have SAN drives and Microsoft Cluster environment and need to
have a way to address "the drive" to write out data flat files to it.
We then manually copy them and use "sneaker net" to an "air gap" LAN
for security reasons. thanks.)


static string System.Environment.GetEnvironmentVariable(string). Pass in
the name of the variable you want and this method will return the value of
that variable.
--
Tom Porterfield
MS-MVP MCE
http://support.telop.org

Please post all follow-ups to the newsgroup only.

Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Greg Lindstrom | last post by:
Hello- I am running python 2.3. on an HP-9000 box running Unix and have a POSIX script that sets up my production environment. I would like to run the script from inside a python routine and...
28
by: Christian | last post by:
Another question from a not even newbie: In Unix you can set an environment variable with the command export PYTHONPATH but I would like to set the variable from at .py script. So my question...
4
by: Bill Davidson | last post by:
All: I've found the 'Environment.GetEnvironmentVariable()' method; but how do I create and/or set an environment variable? Thanks, Bill
4
by: Ron Clarke | last post by:
I have an application that starts other processes. The app needs to create/set a few environment variables when a process starts, let the process run, then remove the environment variables when the...
6
by: Fuzzyman | last post by:
Hello all, I would like to set a Windows Environment variable for another (non-child) process. This means that the following *doesn't* work : :: os.environ = value In the ``win32api``...
1
by: pagates | last post by:
Hi All, What's the "best" way to get System Environment Variables (VS2003)? Environment.GetEnvironmentVariable("xxx") only gets user Environment variables. Thanks, pagates
2
by: ANarula | last post by:
I am running into a strange problem. I have perl script which reads the "APPDATA" environment variable, and does some work on that directory. When I a launch this script from Command Prompt, it...
3
by: Tristan | last post by:
Hello community: I post this because I could not find satisfactory answers in the posts generated by this nice group. I work on winXP. I have many little python applications in different folders,...
3
by: smitty1e | last post by:
Just a fun exercise to unify some of the major input methods for a script into a single dictionary. Here is the output, given a gr.conf file in the same directory with the contents stated below: ...
4
by: Stephen Cattaneo | last post by:
Hello all, I am attempting to execute an automated test (written in Python) via cron. I have to check the HOSTNAME variable as part of the test, oddly under cron the HOSTNAME environment...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.