Welcome to the SRP Forum! Please refer to the
SRP Forum FAQ post
if you have any questions regarding how the forum works.
SRP_Run_Command exit code
Is there a way to see the exit code for a command executed using the SRP_Run_Command?
Not, currently, no. I'll add the feature to the list, but I can't give you an ETA.
Thanks Kevin. I want to call 7-Zip to perform a zip backup and then get exit code to know if the zip creation was successful. If not, I want to capture the output to see why it failed. I can get the exit code using OI's RUNWIN but I can't seem to capture the output or get it to generate a log file. I know this is a different forum, but I see that SRP has a Zip Utility as well. Will that do what I need?
Yes, probably. The caveat is that the SRP Zip Utility only works for the traditional zip archive format, i.e., .zip files. It won't work on other formats, such as .7z. If that fits your requirements, then the SRP Zip Utility works a lot like OSRead or OSWrite, where you can read archived files from a ZIP file directly into an OI variable. It includes a method for getting the last known error when reading or writing fails.
This is a commercial product, but you can
the product for free for testing. It will show an evaluation nag screen, but it is otherwise fully featured.
Okay, thanks again Kevin. Although I am using 7-Zip, I am creating ZIP files, so I will try out the Zip Utility.
edited July 5
deleted post as I can see you have already tried runwin
, I think he understands this based on this statement:
I can get the exit code using OI's RUNWIN but I can't seem to capture the output or get it to generate a log file.
Thanks Josh and Don. Yes, I was using RUNWIN but when I wanted to add the log I ran into the issue capturing the output log.