Kinook Software Forums

Go Back   Kinook Software Forums > Visual Build Professional > [VBP] General Discussion

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 05-06-2010, 11:07 AM
louwho louwho is online now
Registered User
 
Join Date: 04-15-2010
Posts: 3
Question How to output SCM info to a file from VBScript?

Currently, we have this line in a VBScript step...

objShell.Run chr(34) & strSurround & "\SSCM" & chr(34) & " GET " & chr(34) & MyPath & chr(34) & " -e -f -wreplace -d" & strSDKPath & " -p" & strBranchConfCtl & " -z" & strSurrSvr & ":4900", 0

We would like to capture the information to a text file at the same time. I have tried the following, and while the output .txt file is created, it is always blank...

strFile = "C:\lou.txt"
strCommand = "%comspec% /c " & Chr(34) & strSurround & "\SSCM" & chr(34) & " GET " & chr(34) & MyPath & chr(34) & " -j -e -f -wreplace -d" & strSDKPath & " -p" & strBranchConfCtl & " -z" & strSurrSvr & "4900 > " & strFile
' InputBox "Running", "Command", strCommand
objShell.Run strCommand,0,true

I have tried it with and without the "%Comspec% /c"...what am I doing wrong?
Reply With Quote
  #2  
Old 05-06-2010, 12:32 PM
kinook kinook is online now
Administrator
 
Join Date: 03-06-2001
Location: Colorado
Posts: 5,851
Make sure you have permissions to write to C:\ (for instance, on Windows 7, unelevated users don't have write permission to C:\). %TEMP% is a safer path to write to. The attached sample worked as expected.
Attached Files
File Type: bld run.bld (501 Bytes, 779 views)
Reply With Quote
  #3  
Old 05-06-2010, 01:29 PM
louwho louwho is online now
Registered User
 
Join Date: 04-15-2010
Posts: 3
Being that I am able to create the file (even if it is empty), I do not think that it is a permissions problem. I am thinking that perhaps this is a question for the surround SCM forum.
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



All times are GMT -5. The time now is 07:12 PM.


Copyright 1999-2022 Kinook Software, Inc.