Windows Vista Forums
Vista Forums Home Join Vista Forums Donate Vista Tutorials Tags

Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
Register at Vista forums...the world biggest Windows Vista resource Join Vista Forums Now

Go Back   Vista Forums > Microsoft Technical Newsgroups > PowerShell

PS Bug: The OS handle's position is not what FileStream expected.

Update your Vista Drivers Update Your Drivers Now!!
Closed Thread
 
Thread Tools Display Modes
Old 07-03-2008   #1 (permalink)
Twisha
Guest


 

PS Bug: The OS handle's position is not what FileStream expected.

Hi All,

I wanted to know the fix to following PS bug:
out-lineoutput : The OS handle's position is not what FileStream expected.
Do not use a handle simultaneously in one FileStream and in Win32 code or
another FileStream. This may cause data loss.

I have a command file(say mybatch.cmd) which in-turn calls a command
file(say RunAll.cmd) where-in I exec PS Script file (say myPSScript.ps1). The
PS script file in-turn need to exec bat files (say RunMe1.bat, RunMe2.bat).

The issue is: When I run them from command prompt it works fine. However,
when I redirect the output of mybatch.cmd file to an output file, the
execution stops abruptly after running the first bat file(RunMe1.bat). The
error output is mentioned above. I am using pushd and popd commands as my
files are located in different places.

Help me out.

Thanks,
Twisha


My System SpecsSystem Spec
Closed Thread

Thread Tools
Display Modes



Similar Threads
Thread Thread Starter Forum Replies Last Post
Stdout Redirection Causes the Exception "The OS handle's position javacavaj PowerShell 1 05-06-2008 04:52 PM
When is the next update expected? Any news? KonstantinDK Live Mail 3 04-12-2008 06:37 PM
When is a new release expected? Seansan Live Mail 4 01-30-2008 09:37 PM
split works much different than expected Frank PowerShell 5 05-23-2007 10:28 AM
April CTP Expected in the next few weeks Andre Da Costa [Extended64] Vista General 7 04-12-2006 03:00 AM


Update your Vista Drivers Update Your Drivers Now!!

Vistax64.com is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media 2005-2008