Topic "How to use XML log with Powershell"

Author Message
justinchenjy@...

Guest


Hi support,

my OS: WIN2008
POWERTSHELL VERSION: V1.0
WINSCP VERSION: 5.92

i using below code is ok.
$sessionLogPath="C:\SinoPorject\Log\session.log"
$session.SessionLogPath = $sessionLogPath
$session.Open($sessionOptions)

i can got Log file.

but i use below code,

$sessionLogPath="C:\SinoPorject\Log\session.xml"
$session.SessionLogPath = $sessionLogPath
$session.Open($sessionOptions)

there are no xml file in the folder..
hoe to using XML log in powershell?

BR

Justin
justinchenjy@...

Guest


Hi Support,

i try change code like below:

$sessionLogPath="C:\SinoPorject\Log\session.log"
$session.SessionLogPath = $sessionLogPath
$XMLLogPath="C:\SinoPorject\Log\session.xml"
$session.xmlLogPath = $XMLLogPath
$session.Open($sessionOptions)

it still have log type file without xml type file.


br

justin
justinchenjy@...

Guest


Dear Support,


i solve it, i need copy the xml to onther folder before session close.


BR


Justin
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License