home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.ms-windows.programmer.misc
- Path: sparky!uunet!mcsun!news.funet.fi!funic!nntp.hut.fi!kaira.hut.fi!v37262d
- From: v37262d@kaira.hut.fi (Mancko H|glund)
- Subject: Re: Environ or getenv() from a DLL
- Message-ID: <1992Aug31.053449.10183@nntp.hut.fi>
- Keywords: Windows, DLL, AAAAArgh!
- Sender: usenet@nntp.hut.fi (Usenet pseudouser id)
- Nntp-Posting-Host: kaira.hut.fi
- Reply-To: ebbe@shsibm.shh.fi
- Organization: Helsinki University of Technology, Finland
- References: <1992Aug27.222425.9328@serval.net.wsu.edu>
- Date: Mon, 31 Aug 1992 05:34:49 GMT
- Lines: 21
-
- In article <1992Aug27.222425.9328@serval.net.wsu.edu>
- mwoodwar@yoda.eecs.wsu.edu (woodward matthew d - CS350) writes:
-
- >I'm sure that this is in a FAQ somewhere, but is it at all possible
- >to get environ or call getenv() from a windows DLL? If so, how would
- >one go about it?
-
- Use GetDOSEnvironment(). It returns a pointer to a string array corresponding
- to all of your current environment variables. The array is a memory block of
- standard 'C' strings; the end of the block is signalled by an extra 0x00 char
- after the end of the last string.
-
- I've got the code that looks up a specified variable; holler if you'd like
- a copy.
-
- ...ebbe@shsibm.shh.fi
-
- +----------------------------------------------------------------------------+
- v37262d@kaira.hut.fi: Mancko H|glund (mancko@shsibm.shh.fi) or
- Ebbe Jonsson (ebbe@shsibm.shh.fi)
- +----------------------------------------------------------------------------+
-