Table of Contents

Example

System - Lock Console

by: Mike Vandevoort
published: February 2018, edited for v15: 2022, Sebastian Beutel
description: locks the desk
remarks: put your own unlock code into the macro

functions

Code

LockConsole.xml
<?xml version="1.0" encoding="utf-8"?>
<avolites.macros>
 
  <!-- M-V Rental 12/07/2017 created by Mike Vandevoort -->
  <macro id="Avolites.Macros.LockConsole" name="LockConsole">
    <sequence>
      <step pause="0.01">
        <!-- change 1009 with the lock code that you want -->
        System.LockConsole("1009")
      </step>
    </sequence>
  </macro>
 
  <macro id="Avolites.Macros.LockConsolev15" name="LockConsole v15">
    <sequence>
      <step>
        <!-- change 1009 with the lock code that you want -->
        LockMode.LockConsole("1009", false)
      </step>
    </sequence>
  </macro>
 
</avolites.macros>

Explanation

This explains the functional steps within the sequence. For all the other XML details please refer to Formats and syntax

This macro uses the system function System.LockConsole() resp. LockMode.LockConsole() to lock the console. There are two reaons why this may come in very handy:

How to use it

  1. depending from software version you need to use the first or the second macro (the other simply does nothing)
  2. replace 1009 with your own unlock code