Print Page | Close Window

Follow-on script log

Printed From: ForensiT
Category: ForensiT Support
Forum Name: Domain Migration
Forum Discription: User Profile Wizard questions, suggestions, comments and bug reports
URL: http://forum.ForensiT.com/forum_posts.asp?TID=717
Printed Date: 21 Nov 2019 at 3:00pm


Topic: Follow-on script log
Posted By: lavoied
Subject: Follow-on script log
Date Posted: 31 Jan 2013 at 10:41am
Hello,
Is it possible to add line the the log file in the follow-up script?

thanks



Replies:
Posted By: Support
Date Posted: 31 Jan 2013 at 12:34pm
Yes, it is quite easy. With vbscript you would use something like this:
Option Explicit
Const ForReading = 1, ForWriting = 2, ForAppending = 8

Dim objFSO, LogFile, objFile
LogFile="C:\Users\Public\Documents\migrate.log"

Set objFSO=CreateObject("Scripting.FileSystemObject")
Set objFile = objFSO.OpenTextFile(LogFile, ForAppending, True)

objFile.Write "Write Something" & vbCrLf
objFile.Close

You can get the log file path from the <Log> value in Profwiz.config.


Posted By: lavoied
Date Posted: 31 Jan 2013 at 1:57pm
It work well...
Thanks



Print Page | Close Window