CreateProcessWithLogonW's process does not have the envrironmentvariables

A

ashu.nitc

Hi,
I am trying to create a process with the API: CreateProcessWithLogonW.
The
process (say, CMD.EXE) which gets created doesnt have the environment
variables which I have explicitly passed into it as the parameter. The
same
environment block works for CreateProcessAsUser, but doesnt give me
the same
results when used with CreateProcessWithLogonW(). The difference in
the list
of the environment variables could be seen using the "set" command in
the
command prompts that I am creating using the APIs. (I am getting only
a few environment variables, the rest are not getting available to the
newly created process)
I really would appreciate any help regarding this.

Many thanks in advance,
Ashish
 
W

Willy Denoyette [MVP]

Hi,
I am trying to create a process with the API: CreateProcessWithLogonW.
The
process (say, CMD.EXE) which gets created doesnt have the environment
variables which I have explicitly passed into it as the parameter. The
same
environment block works for CreateProcessAsUser, but doesnt give me
the same
results when used with CreateProcessWithLogonW(). The difference in
the list
of the environment variables could be seen using the "set" command in
the
command prompts that I am creating using the APIs. (I am getting only
a few environment variables, the rest are not getting available to the
newly created process)
I really would appreciate any help regarding this.

Many thanks in advance,
Ashish



Impossible to help you out without seeing your code.

Willy.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top