Groups | Search | Server Info | Keyboard shortcuts | Login | Register
Groups > comp.lang.basic.misc > #281
| From | ralph <nt_consulting64@yahoo.com> |
|---|---|
| Newsgroups | comp.lang.basic.misc |
| Subject | Re: Environment variables in Visual Basic (Vb5E, W7/64) |
| Date | 2012-06-25 10:43 -0500 |
| Organization | Aioe.org NNTP Server |
| Message-ID | <ni1hu799q84b2tjpoboojui59glmpib2gr@4ax.com> (permalink) |
| References | <op.wggsfgtr3zwgbm@w7-pc> |
On Mon, 25 Jun 2012 17:10:18 +0200, Helge <w4h@nurfuerspam.de> wrote:
>Hallo NG!
>I need to open PathA = "%USERPROFILE%\Documents\paper\pp.csv"
> Open PathA for Output as #FiNu
>But it does not work that easy. Any ideas? Thanks!
>Vy 73! Helge
The "%" delimiters are for use with shells. At the command line, in
batch files, Windows Shells (Explorer) etc.
In VB use the Environ() function without the delimiters.
Dim sRoot As String : sRoot = Environ("userprofile")
PathA = PathA = sRoot & "\Documents\paper\pp.csv"
-ralph
Back to comp.lang.basic.misc | Previous | Next — Previous in thread | Next in thread | Find similar
Environment variables in Visual Basic (Vb5E, W7/64) Helge <w4h@nurfuerspam.de> - 2012-06-25 17:10 +0200
Re: Environment variables in Visual Basic (Vb5E, W7/64) ralph <nt_consulting64@yahoo.com> - 2012-06-25 10:43 -0500
Re: Environment variables in Visual Basic (Vb5E, W7/64) "Auric__" <not.my.real@email.address> - 2012-06-25 18:17 +0000
Re: Environment variables in Visual Basic (Vb5E, W7/64) Helge <w4h@nurfuerspam.de> - 2012-06-26 09:59 +0200
csiph-web