Table of Contents

Example

Off/On Attribute in Palette

by: Alex del Bondio, November 2018
published: http://forum.avolites.com/viewtopic.php?f=20&t=5928
description: macro to turn an attribute group off resp. on in a palette
remarks: Idea/request by PascalvE

This macro assumes that group 999 and palette 999 exist. Group 999 is used as temporary store for the selected fixtures. The macro turns colour values in palette 999 off resp. on.

There is a follow-up thread in the forum explaining how this can be done entirely with coded functions: http://forum.avolites.com/viewtopic.php?f=20&t=5936

This has been reproduced in this wiki here: Off/On Attribute (snippets)

functions

affected properties

Code

offOnAttributeInPalette.xml
<?xml version="1.0" encoding="utf-8"?>
<avolites.macros>
 
  <macro id="adb.Macros.colourvaluesoffblind" name="adb set colour values off in blind">
    <sequence>
      <step>Group.ReplaceGroupOnHandle(userNumber: 999)</step>
      <step pause="0.01">ActionScript.SetProperty.Boolean("Programmer.BlindActive", true)</step>	
      <step pause="0.01">Programmer.SetBlindMode(false, 0)</step>
 
      <step>Group.RecallGroup(userNumber: 999)</step>
      <step pause="0.001">Menu.Stack.PushOrReloadMenu("Primary", "Expert.Root.Program")</step>
      <step pause="0.001">Menu.InjectInput("OnSelect","AttributeGroup","NoGroup",4)</step>
      <step pause="0.001">Menu.InjectInput("OnButtonDown","Off","",0)</step>
      <step pause="0.001">Menu.InjectInput("OnButtonUp","Off","",0)</step>
      <step pause="0.001">Menu.InjectInput("OnSelect","Softkey","NoGroup",2)</step>
      <step pause="0.001">Palette.QuickMergePalette(userNumber: 999)</step>
      <step>Programmer.Editor.Clear(All, true, false, 0)</step>
 
      <step pause="0.01">ActionScript.SetProperty.Boolean("Programmer.BlindActive", false)</step>
      <step pause="0.01">Programmer.SetBlindMode(false, 0)</step>
    </sequence>
  </macro>
 
  <macro id="adb.Macros.colourvaluesonblind" name="adb set colour values on in blind">
    <sequence>
      <step>Group.ReplaceGroupOnHandle(userNumber: 999)</step>
      <step pause="0.01">ActionScript.SetProperty.Boolean("Programmer.BlindActive", true)</step>	
      <step pause="0.01">Programmer.SetBlindMode(false, 0)</step>
 
      <step>Group.RecallGroup(userNumber: 999)</step>
      <step pause="0.001">Menu.Stack.PushOrReloadMenu("Primary", "Expert.Root.Program")</step>
      <step pause="0.001">Menu.InjectInput("OnSelect","AttributeGroup","NoGroup",4)</step>
      <step pause="0.001">Menu.InjectInput("OnButtonDown","Off","",0)</step>
      <step pause="0.001">Menu.InjectInput("OnButtonUp","Off","",0)</step>
      <step pause="0.001">Menu.InjectInput("OnButtonDown","Off","",0)</step>
      <step pause="0.001">Menu.InjectInput("OnButtonUp","Off","",0)</step>
      <step pause="0.001">Menu.InjectInput("OnSelect","Softkey","NoGroup",2)</step>
      <step pause="0.001">Palette.QuickMergePalette(userNumber: 999)</step>
      <step>Programmer.Editor.Clear(All, true, false, 0)</step>
 
      <step pause="0.01">ActionScript.SetProperty.Boolean("Programmer.BlindActive", false)</step>
      <step pause="0.01">Programmer.SetBlindMode(false, 0)</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 assumes that group 999 and palette 999 exist. Group 999 is used as temporary store for the selected fixtures. The macro turns colour values in palette 999 off resp. on.

How to use it