Search Tools Links Login

Return Error Level


How to return an error level to a batch file. This is a good way to hand off processing from a batch file, to an executable, and back again, performing rudimentary sharing of information.

For example, you could have an automated task that runs a batch script to, say, get some files from a remote location. Then execution gets handed off to an executable to process those files.

After the executable does whatever processing it needed to do, it hands back off to the batch file, setting an errorlevel. That errorlevel can alter the flow in the batch file to perform various tasks based upon the value returned.

Return Error Level Demo

About this post

Posted: 2017-07-20
By: BlackBeltVB
Viewed: 545 times

Categories

Visual Basic 6

Attachments

ERRLEVEL.ZIP
Posted: 7/20/2017 7:31:47 AM
Size: 2,028 bytes

Requirements

This code originally appeared on BlackBeltVB.com, and has been republished here with the permission of Matt Hart.

Special Instructions

Uses the following API function:


Loading Comments ...

Comments

No comments have been added for this post.

You must be logged in to make a comment.