Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > PowerShell

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

Reply
 
Old 07-03-2008   #1 (permalink)
Twisha


 
 

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
Reply

Thread Tools


Similar Threads
Thread Forum
Tab completion not what I expected PowerShell
Stdout Redirection Causes the Exception "The OS handle's position PowerShell
Expected release date for PS 2.0? PowerShell
When is a new release expected? Live Mail
April CTP Expected in the next few weeks Vista General


Vista Forums 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 Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46