Ytria
Essentials for IBM Notes Development
& IBM Domino Administration
IBM Lotus Software
Login
Printer Friendly Version
Automation

What is automation?


First introduced in version 12, automation holds a lot of promise for performing large, repetitive tasks in a quick and efficient manner. EZ Suite 16.5 sees the focus of the command language and the scope of possibilities greatly expanded.

But, how can you put this to work for you?


Following through this page will help your understanding of what you can do with automation and how you can get started doing it. We'll also introduce you to some key automation resources you'll want to keep handy for the future.

First, let's look at a quick-and-easy script.

Try out the script below in aclEZ with a server already loaded. You'll get a concise readout of all ACL entries, and their corresponding access levels for all databases on a loaded server.
1. Simply copy/paste the script shown here into any text editor and save it as an XML file.
2. Open aclEZ and load a server into the selection tree. Then, select the option 'Load Automation File…' from the Server (or use CTRL+X).
3. Find the file you just saved and click 'Open.'
That's all there is to it! You'll have a complete listing of all databases on the loaded server, as well as all applicable ACL entries grouped by access level and name.

back to top

<?xml version="1.0"?>
<ytriaAutomation Application="aclEZ" ApplicationVersion="16.5">

<RemoveAllColumns/>
<Add ColumnID="DB1" Position="1"/>
<Add ColumnID="ACL5" Position="1"/>
<Add ColumnID="ACL1" Position="1"/>

<GroupBy ColumnID="DB1"/>
<GroupBy ColumnID="ACL5"/>
<GroupBy ColumnID="ACL1"/>
<Collapse/>
</ytriaAutomation> 

1-

Want to learn more? Start here.

Our automation scripts are written in XML. If you are currently unfamiliar with XML, w3schools.com has some excellent tutorials to help kickstart your understanding.

To learn more about automation itself, visit our "XML Basics" page by clicking the link below. You'll find simple examples of the types of components found in a good automation script—including their structure and purpose.

Automation Basics

Tip: Once you start to get the general idea of what automation is all about, check out some commands that you'll want to know. Some of the concepts involved require a bit of familiarization, but once you have the knowledge under your belt, large scale operations are a cinch to handle:

  • Global Actions This section contains high-level commands used universally across all tools. For example, loading a server or database.
  • Logic Actions This section contains somewhat more advanced commands used in crafting the operation of the script itself. Set changeable variables, create branching conditions, and more.
  • Grid Actions Here you'll find the commands to handle most every function found in flexYGrid panels. See how to create groupings, add and remove columns, select columns and rows, and much more.

2-

Check out the full scope of functionality.

Check out the ever-expanding catalog of functions that you can automate. Some of these command tags will sound familiar, some will seem brand new. A vast amount of possibilities exist. Each tag has it's own page that contains an explanation of exactly what it will do, an example that puts it in context, and the technical information surrounding its use in a script.

Automation Tags

3-

Drill down into the specifics.

Every product has its own exclusive functions. Click the links below for a direct access to the pages describing the specific action tags that are used to automate the individual products' functionality.

scanEZ Automation aclEZ Automation agentEZ Automation databaseEZ Automation
consoleEZ Automation replicationEZ Automation viewEZ Automation actionBarEZ Automation
designPropEZ Automation

Have a question about automation that wasn't answered here? Just contact us; we'll be happy to help.


Let us work for you with these ready-made scripts.


Click below for some working scripts that you can put to work immediately. For your convenience, comments have been included as explanations of key functionalities. Feel free to change the values to meet your needs—when doing so, be sure to keep the Ytria Automation tag specifics in mind to ensure that your scripts function properly.


Script Level: Easy

Search multiple servers for all invalid ACL entries.


This script will automatically search three servers for any and all invalid ACL entries—entries for names not found in the NAB—and then export the results to a per-server report, one Excel file each.


<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<ytriaAutomation Application="aclEZ" ApplicationVersion="16.5">
<!-- Declarations: Change the Server values as needed.--> 
<OnError continue="True"/> 
<List name="ServerList" Action="Load" server="ACME01/ACME" Select="True"/>
<List name="ServerList" Action="Load" server="ACME02/ACME" Select="True"/>
<List name="ServerList" Action="Load" server="ACME03/ACME" Select="True"/>
<!-- Initialize --> 
<loop list="ServerList" OnError="Next">
<ExecuteListAction/>
<Option Type="PresenceInNAB" Value="True"/> 
<Filter columnID="NAB4" Value="Unchecked"/>
<Export> 
	<Echo value="Processing server {%Listname%}"/> 
	<SetParam field="FilePath" value="{%CurFilePath%}{%Listname%}"/> 
	<SetParam field="ExportType" value="Excel"/> 
	<SetParam field="Mode" value="Create"/> 
</Export> 
</loop>
<Echo value="Process Done"/> 
</ytriaAutomation> 


Script Level: Easy

Load a server and export all ACL information.


This script will load all databases on a server of your choice and then export all ACL attributes and roles to an HTML file.


<ytriaAutomation Application="aclEZ" ApplicationVersion="16.5">
<OnError continue="True"/> 
<Echo Mode="False"/>
<!--The variable in the next line will set the server to load. 
	Simply change this variable value to accommodate your needs.--> 
<SetVar srv="Enter your server name here."/> 
<!-- Initialize --> 
<Load Server="{%srv%}" select="true"/>
<Export Type="FlagsAndRoles">
		<SetParam target="ExportToFile" field="FilePath" value="aclEZ_export.html"/>
		<SetParam target="ExportToFile" field="ExportType" value="HTML"/>
		<SetParam target="ExportToFile" field="FileOutput" value="Unicode"/>
		<SetParam target="ExportToFile" field="OpenFileOnceGenerated" value="true"/>
</Export>
</ytriaAutomation> 


Script Level: Easy

Find and report all Mail Owner access levels and various connected properties and settings regarding their permissions across multiple databases on multiple servers.


This script can be used by itself in aclEZ to process a currently opened server, or with the new function found in replicationEZ that lets you launch a script on a selection of servers directly from within the interface.
Learn more about this function here.
This script will parse the entire mail directory folder on a given server to find all mail owners set side by side with a selection of key properties and settings that govern access and permissions to their respective mail databases. A report will be generated and exported into an Excel file. Each access level will be reported on its own sheet within the file.


<ytriaAutomation Application="aclEZ" ApplicationVersion="16.5">
	<!--This will set the script's behavior when encountering an error. 
		In this case, it will continue.-->
	<onerror continue="true" />
	
	<!--First it is specified that the NAB presence is NOT to be checked and groups are NOT 
		to be "expanded."-->
	<Option Type="PresenceInNAB" value="false"/>
	<Option Type="GroupExpander" value="ExpandNone"/>
	<TreeSelectionLive Value="True"/>
	<!--All databases on the current server will be deselected in the tree.-->
	<unselect target="tree" server="true"/>
	
	<!--Then the mail directory folder for the current server will be selected.-->
	<select target="tree" folder="mail"/>
	
	<!--The next part of the script defines the actions to be taken within the Audit grid.
		The grid layout will be set as stated below.
		A Suspend Grid Redraw function is added so the processing will be held off until 
		all columns are set.-->
	<SuspendRedraw value="true"/>
	
	<!--All columns are removed from the main grid in order to prepare for the columns 
		that will be added.-->
	<RemoveAllcolumns/>
	
	<!--The grid columns are moved to the first position in reverse order.
		The name of the columns are indicated.-->
	<Add ColumnID="DB6" Position="1"/><!-- Catalog Categories -->
	<Add ColumnID="DB4" Position="1"/><!-- Database Type -->
	<Add ColumnID="A9" Position="1"/><!-- Replicate or Copy Documents -->
	<Add ColumnID="A8" Position="1"/><!-- Write Public Documents -->
	<Add ColumnID="A7" Position="1"/><!-- Read Public Documents -->
	<Add ColumnID="A6" Position="1"/><!-- Create LS/Java Agents -->
	<Add ColumnID="A5" Position="1"/><!-- Create Shared Folder/Views -->
	<Add ColumnID="A4" Position="1"/><!-- Create Private Folders/Views -->
	<Add ColumnID="A3" Position="1"/><!-- Create Private Agents -->
	<Add ColumnID="A2" Position="1"/><!-- Delete Documents -->
	<Add ColumnID="A1" Position="1"/><!-- Create Documents -->
	<Add ColumnID="ACL4" Position="1"/><!-- Type -->
	<Add ColumnID="ACL1" Position="1"/><!-- Name -->
	<Add ColumnID="DB3" Position="1"/><!-- Database File -->
	<Add ColumnID="DB2" Position="1"/><!-- Database Path -->
	<Add ColumnID="STATUS" Position="1"/><!-- Status -->
	<!--Any residual grouping and sorting is cleared.-->
	<Reset/>
	
	<!--A new grouping configuration is set.-->
	<GroupBy ColumnID="ACL5"/><!-- Access -->
	<GroupBy ColumnID="DB7"/><!-- Server -->
	
	<!--And a new sorting configuration is set.-->
	<Sort columnID="DB2" Ascending="true"/><!-- Database Path -->
	<Sort columnID="DB4" Ascending="true"/><!-- Database Type -->
	<Sort columnID="DB3" Ascending="true"/><!-- Database Filename -->
	
	<!--A filter is added to isolate only mail owners,and then the grid processing is 
		reactivated by turning off
		the Suspend Grid Redraw state.-->
	<Filter columnID="ACL3" Empty="true"/><!-- Mail Owner -->
	<SuspendRedraw value="false"/>
	
	<!--The following If condition will test if the main grid has any rows loaded. 
		If there are any rows loaded (meaning that Mail Owners were found) the nested 
		child actions 
		will be carried out.-->
	<if target="Grid" test="VisibleRowsCount" Mode="GreaterThan" Value="0">
		
		<!--The following If condition declares that if this script is not being used in a 
			loop, the Excel file will be opened as soon as it is generated.
			This can't be done if a loop is being run since the Excel file still may need 
			to be worked on with the results of another server (depending on what you need
			to do). Keep in mind that we can't set an If condition with a SetParam value, 
			hence the use of this variable.
			The variable is initialised first, and it will be changed if not in a loop.-->
		<SetVar vOpenExcelFile="False"/>
		<if target="var" test="{%ListSize%}" mode="Equals" Value="">
			<SetVar vOpenExcelFile="true"/>
		</if>
		
		<!--Finally, any findings regarding the databases and their respective mail owners, 
			and the rights those mail owners hold, will be exported. 
			Note that this report will be generated in the same location that this file
			 is being run from.-->
		<Export>
			<SetParam field="FilePath" value="{%CurFilePath%}report_aclEZ.xlsx"/>
			<SetParam field="SelectedRowsOnly" value="false"/>
			<SetParam field="ExportType" value="Excel"/>
			<SetParam field="Mode" value="AppendRows"/>
			<SetParam field="ExcelSheetName" value="Email Owner Access"/>
			<SetParam field="OpenFileOnceGenerated" value="{%vOpenExcelFile%}"/>
		</Export>	
	</if>
</ytriaAutomation>


Script Level: Easy

Create a new item across all documents in a specific category—and across multiple databases.


This script can be used by itself in scanEZ to process a currently opened database, or with the new function found in databaseEZ that lets you launch a script on a selection of databases directly from within the interface.
Learn more about this function here.
Small in size, yet very flexible in where you can take it, this script will simply select a category of documents and create a new item across all documents within that focused selection.


<?xml version="1.0" encoding="UTF-8"?>
<ytriaAutomation Application="scanEZ" ApplicationVersion="16.5" Version="1.0">

<!--The following three lines let you specify the name and value of the item to be added, as well as the document category whose documents the item will be deployed to. Simply enter your desired values where indicated.--> <SetVar ItemToAdd="Enter your value here"/> <SetVar ItemValue="Enter your value here"/> <SetVar DocumentCategory="Enter your value here"/>
<!--The following Expand/Focus sequence will allow the focus to be placed on the documents within the selection tree category specified.--> <Expand target="tree" category="Documents" type="{%DocumentCategory%}"/> <focus target="tree" category="Documents" type="{%DocumentCategory%}"/>
<!--The CreateItem script block is where we define the item to be added. If the item already exists, it will not create a new one, instead it will skip the document and move on to the next. In this particular case, the item added will be a Text item that will use the name and value defined in the beginning of the script.--> <CreateItem OnExisting="skip"> <SetParam field="TypeList" value="Text"/> <SetParam field="FieldName" value="{%ItemToAdd%}"/> <SetParam field="FieldValue" value="{%ItemValue%}"/> <SetParam field="IsProtected" value="true"/> </CreateItem> </ytriaAutomation>

Script Level: Intermediate

Find all documents that match a given formula across a selection of databases, and export the findings into an Excel file.


This script can be used by itself in scanEZ to process a currently opened database, or with the new function found in databaseEZ that lets you launch an automation script on a selection of databases directly from within the interface.
Learn more about this function here.
This intermediate script allows you to specify desired values in the beginning of the script using variables, minimizing any changes to the body of the script itself. This script will search a selection of databases for all the documents that match a defined formula. The name of the database that they are found in, as well as their UNIDs, will be exported into an Excel report.


<ytriaAutomation Application="scanEZ" ApplicationVersion="16.5">
	
	<!--This will set the scripts behavior when encountering an error. 
		In this case, it will continue.-->
	<onerror continue="true" />
	<!--Use the following variables to adapt the script to your own needs.-->
	<!--TO SET :: this is THE FORMULA used. Note that the formula follows the general XML 
		rules of "escaping". -->
	<SetVar vSearchFormula="@Contains(Subject;&quot;Help us protect your account&quot;)"/>
	
	<!--TO SET :: This is the item to use as a main "key" for the report.-->
	<SetVar vItemToUseAsKey="Subject"/>
	<!--This script block will perform the search for the documents.-->
	<SearchBy Type="Formula">
		<Setparam Field="SetFormula" Value="{%vSearchFormula%}"/>
		<Setparam Field="SearchDocuments" Value="true"/>
		<Setparam Field="SearchDesigns" Value="false"/>
		<Setparam Field="PutSearchInSelCreateName" Value="All Docs Found"/>
	</SearchBy>
	
	<!--The following Focus line will place the focus on the newly created 
		My Selection folder named "All Docs Found".-->
	<Focus Target="Tree" Category="All Docs Found"/>
	
	<!--The following If condition declares that If the My Selection exists (i.e. something  
		has been found), the nested child actions will be carried out.-->
	<if Target="Tree" Test="FocusRoot" Mode="NotEquals" Value="True">
		
		<!--This will set the displayed document titles to the current database name, 
			for reference in the resulting report.-->
		<ChangeDocumentTitle>
			<Setparam Field="TitleOptionType" Value="Formula"/>
			<Setparam Field="TitleOptionFormula" Value="@Implode(@DbName;&quot;!!&quot;)"/>	
		</ChangeDocumentTitle>
		
		<!-- This will enact a Diff operation on the documents within the My Selection folder
			and select the main "key" item by the specified name.-->
		<Diff/>
		<Select target="DiffGrid" Lines="ByValue">
			<SetParam ColumnID="AI2" Value="{%vItemToUseAsKey%}"/>
		</Select>
		
		<!-- This opens the Values grid.-->
		<Values>
			
			<!-- This will remove the Type column.-->
			<ShowTypeColumns value="false"/>
			
			<!-- And this adds a custom column where the UNID will be displayed.-->
			<AddCustomColumn name="UNID">
				<SetParam field="TitleOptionType" Value="System"/>
				<SetParam field="TitleOptionSystem" Value="UNID"/>
			</AddCustomColumn>
			<Evaluate/>
			
			<!--Finally, the results of the search will be exported into a report titled 
				report_DeleteDoc.xlsx. If this script is to be executed as part of a 
				Loop/List, the newly found information will be exported and appended 
				to the same file.-->
			<Export>
				<SetParam field="FilePath" value="{%CurFilePath%}report_DeleteDoc.xlsx"/>
				<SetParam field="SelectedRowsOnly" value="false"/>
				<SetParam field="ExportType" value="Excel"/>
				<SetParam field="Mode" value="AppendRows"/>
				<SetParam field="ExcelSheetName" value="DOCS FOUND"/>
				<SetParam field="OpenFileOnceGenerated" value="False"/>
			</Export>
		</Values>		
	</if>
</ytriaAutomation>


Script Level: Advanced

Find and report all scheduled agents that have and have not run on a given server and create a concise report of agents in both conditions.


This script can be used by itself in agentEZ to process a currently opened server, or with the new function found in replicationEZ that lets you launch a script on a selection of servers directly from within the interface.
Learn more about this function here.
This advanced script will load all enabled and scheduled agents on a currently loaded server and designate those that did not run. Additionally, it will create an Excel report of all agents, putting those that did run and those that did not on two separate pages. The report's layout will be set up in a way so that it is easy to check the status.


<ytriaAutomation Application="agentEZ" ApplicationVersion="16.5">
	<!--This will set the script's behavior when encountering an error. 
		In this case, it will continue.-->
	<onerror continue="true" />
	
	<!--At this point, we don't want to automatically load the detailed agent information. 
		This will set it as "false". -->
	<Option Type="AutoLoadDetailedAgentInfo" value="False"/>
	
	<!--This will allow the automatic Check Presence in NAB feature to be carried out on 
		the agent signer for each agent loaded.-->
	<Option Type="PresenceInNAB" value="true"/>
	
	<!--This will set the option to use the Design Collection Note which is a much 
		faster loading option.-->
	<UseDesignCollection value="true"/>
	
	<!--This defines our search as looking only for scheduled agents.-->
	<AgentTriggerType value="Scheduled" />
	<!--This will select all databases on the loaded server.-->
	<TreeSelectionLive Value="False"/>
	<select target="tree" server="true"/>
	<TreeSelectionLive Value="True"/>
	<!--The next part of the script will handle the grid layout so the results are presented 
		in a clear order. A Suspend Grid Redraw function is added so the processing will 
		be held off until all columns are set.-->
	<SuspendRedraw value="true"/>
	
	<!--All columns are removed from the main grid in order to prepare for the columns that 
		will be added.-->
	<RemoveAllcolumns/>
	
	<!--Second, the columns that we want are added back into the first position 
		and in reverse order.-->
	<Add ColumnID="STATUS_LOAD" Position="1"/><!-- Is Agent Fully Loaded? -->
	<Add ColumnID="D33" Position="1"/><!-- Is background agent disabled on database -->
	<Add ColumnID="B6" Position="1"/><!-- Comment -->
	<Add ColumnID="D3" Position="1"/><!-- Database Type -->
	<Add ColumnID="R24" Position="1"/><!-- Run on week-ends -->
	<Add ColumnID="R23" Position="1"/><!-- Stop running agent on this date -->
	<Add ColumnID="R22" Position="1"/><!-- Start running agent on this date -->
	<Add ColumnID="R21" Position="1"/><!-- Running Interval -->
	<Add ColumnID="M13" Position="1"/><!-- Signer -->
	<Add ColumnID="B5" Position="1"/><!-- Last Alias -->
	<Add ColumnID="B4" Position="1"/><!-- Name -->
	<Add ColumnID="D2" Position="1"/><!-- Database Filename -->
	<Add ColumnID="D1" Position="1"/><!-- Database Path -->
	<Add ColumnID="L17" Position="1"/><!-- Last Run Duration -->
	<Add ColumnID="L15" Position="1"/><!-- Last Run Start Date -->
	<Add ColumnID="STATUS" Position="1"/><!-- Status -->
	
	<!--Then, all groupings are removed.-->
	<UngroupAll/>
	
	<!--And we will set a new grouping configuration.-->
	<GroupBy ColumnID="D46"/><!-- Server -->
	<GroupBy ColumnID="R9"/><!-- Run On -->
	<GroupBy ColumnID="R12"/><!-- Agent Schedule -->
	
	<!--Also, a new sorting configuration is set.-->
	<Sort columnID="L17" Ascending="false"/><!-- Last Run Duration -->
	<Sort columnID="D1" Ascending="true"/><!-- Database Path -->
	<Sort columnID="D3" Ascending="true"/><!-- Database Type -->
	<Sort columnID="D2" Ascending="true"/><!-- Database Filename -->
	<!--All existing filters are cleared, and then the grid processing is reactivated 
		by turning off the Suspend Grid Redraw state.-->
	<ClearFilters/>
	<SuspendRedraw value="false"/>
 
	<!--Note that the agent details don't need to be loaded in this situaiton, as this info is 
		provided without a full information load.-->
	<Filter columnID="R8" Value="checked"/><!-- Enable -->
	
	<!--The following If condition declares that if something is found (and thus making
		the grid count greater than 0), 	the nested child actions will be carried out.-->
	<if target="Grid" test="VisibleRowsCount" Mode="GreaterThan" Value="0">
		
		<!--All enabled agents will be selected (rows loaded in the grid).-->
		<Select lines="all"/>
		
		<!--Then, all the detailed agent information is loaded for all selected lines.-->
		<LoadMoreInfo/>
		<!--A filter is added to find all agents that are enabled and did run correctly.-->
		<Filter columnID="L17" Empty="true"/><!-- Last Run Duration not set... -->
		
		<!--These findings can now be exported. Note that this report will be generated 
			in the same location that this file is being run from.-->
		<Export>
			<SetParam field="FilePath" value="report_agentEZ.xlsx"/>
			<SetParam field="SelectedRowsOnly" value="false"/>
			<SetParam field="ExportType" value="Excel"/>
			<SetParam field="Mode" value="AppendRows"/>
			<SetParam field="ExcelSheetName" value="Enabled Scheduled Agents - LAST RUN"/>
			<SetParam field="OpenFileOnceGenerated" value="False"/>
		</Export>
		
		<!--All filters will be cleared from the Last Run Duration column.-->
		<ClearFilters columnID="L17"/><!-- Last Run Duration... -->
		
		<!--A filter is then added to find all agents that are enabled, but did not run 
			correctly. A small trick is used here: hiding anything that contains a 
			":" character (and thus indicating a duration).-->
		<Filter columnID="L17" Mode="NotContains" Text=":"/><!-- Last Run Duration... -->
		
		<!--The following If condition declares that if this script is not being used in a
			loop, the Excel file will be opened as soon as it is generated. This can't be done 
			if a loop is being run since the Excel file still may need to be worked on with the
			results of another server (depending on what you need to do).
			Keep in mind that we can't set an If condition with a SetParam value,
			hence the use of this variable.
			The variable is initialised first, and it will be changed if not in a loop.-->
		<SetVar vOpenExcelFile="False"/>
		<if target="var" test="{%ListSize%}" mode="Equals" Value="">
			<SetVar vOpenExcelFile="true"/>
		</if>
		
		<!--Finally, any findings regarding agents that did not run can be exported. 
			Note that this report will be generated in the same location that this file 
			is being run from.-->
		<Export>
			<SetParam field="FilePath" value="{%CurFilePath%}report_agentEZ.xlsx"/>
			<SetParam field="SelectedRowsOnly" value="false"/>
			<SetParam field="ExportType" value="Excel"/>
			<SetParam field="Mode" value="AppendRows"/>
			<SetParam field="ExcelSheetName" value="DID NOT RUN"/>
			<SetParam field="OpenFileOnceGenerated" value="{%vOpenExcelFile%}"/>
		</Export>
	</if>
	
</ytriaAutomation>


Script Level: Advanced

Find multiple different types of profile documents and create reports of each different type found.


This script can be used by itself in scanEZ to process a currently opened database, or with the new function found in databaseEZ that lets you launch an automation script on a selection of databases directly from within the interface. Learn more about this function here.
This advanced script will iterate over a List containing different user-definable profile document names, and, for each given name, conduct a regex search to find the profile documents that contain a matching name. A multi-faceted report containing a full breakdown of all the items and their values within each document will be exported to an Excel file; each document name's search results will be placed in its own page in the file.


<ytriaAutomation Application="scanEZ" ApplicationVersion="16.5">
	<!--This will set the script's behavior when encountering an error. In this case, 
		it will continue.-->
	<onerror continue="true" />
	<!--This will allow the script to run if called from databaseEZ by using the option 
			'Execute Automation File On...'-->
	<if target="var" test="{%ListSize%}" mode="NotEquals" Value="">
		<ExecuteListAction/>
	</if>
	<!--The script uses Loop and List actions. The Loop itself can be modified to fit your 
		needs.-->
	<!--TO SET: these variables define the profile you are looking for. You may change the 
		values to suit your needs and even add in more lines to the list keeping the format 
		shown.
		Note: Personal profile documents are arranged in a level further down in scanEZ's
		selection tree and must be selected in a different way.-->
	<List name="allProfileName" Action="SetVar" vProfileName="CalendarProfile"/>
	<List name="allProfileName" Action="SetVar" vProfileName="NotExistProfile"/>
	<List name="allProfileName" Action="SetVar" vProfileName="ColorProfile"/>
	<!--This line will expand the Profile Documents section of the selection tree.-->
	<Expand target="tree" Category="Profile Documents"/>
	<!--Beginning here, the rest of the script is the Loop setup. 
		All actions within this Loop section will be carried out in turn on all the lines in 
		the List section (above) that use the specified name. The Loop is set to call on
		the List name "allProfileName".-->
	<Loop list="allProfileName" OnError="Next">
		
		<!--This next action is mandatory in order for the action within the List lines 
			referenced to be carried out. In the case of the lines in the List 
			"allProfileName", the SetVar action is to be executed.-->
		<ExecuteListAction/>
		<!--Then, everything in the tree will be deselected.-->
		<UnSelect Target="tree" name="All"/>
		
		<!--This will place the focus on the Profile Documents category so that the 
			SelectByRegex action can be used on the first-level entries within.-->
		<Focus Target="Tree" Category="Profile Documents"/>
		
		<!--The following line will enact a regex search on the first-level profile documents
			to find any profile documents that contain the name provided.-->
		<SelectByRegex Regex="{%vProfileName%}"/>
		
		<!--As stated early on in this script, Personal Profile documents are arranged at a
			deeper level in the selection tree. If you want to be able to search through both
			of these levels at the same time to find both the first level profile documents 
			and personal profile documents with this name use this line in place of the regex 
			search above <Select Target="Tree" Category="Profile Documents" 
			Type="{%vProfileName%}"/> -->
		
		<!--This will create a new My Selection folder containing the found documents. 
			By doing this the displayed titles can be set to your desired form (titles 
			cannot be set within the Profile Documents category).-->
		<MySelection>
			<Setparam Field="MySelectionName" Value="Selection of {%vProfileName%}"/>
			<Setparam Field="TitleOptionType" Value="Formula"/>
			<Setparam Field="TitleOptionFormula" Value="@Implode(@DbName;&quot;!!&quot;)"/>	
		</MySelection>
		<!--Then the focus is placed on the newly created My Selection folder.-->
		<Focus Target="Tree" Category="Selection of {%vProfileName%}"/>
		
		<!--The following If condition declares that if the My Selection does exist,
			(meaning that something has been found) the nested child actions will be 
			enacted.-->
		<if Target="Tree" Test="FocusRoot" Mode="NotEquals" Value="True">
			
			<!--A Values function is carried out on the focused My Selection folder.-->
			<Values>
				
				<!--All items within the Values grid are selected.-->
				<SetParam Target="SelectDocumentItems" Field="All" value="true"/>
				
				<!--And finally all the findings are exported to an Excel file; the results
				    for each profile name will be placed on its own sheet within the file.
				    The file will be saved in the same location as the this Automation file.-->
				<Export>
				   <SetParam field="FilePath" value="{%CurFilePath%}report_FindProfile.xlsx"/>
				   <SetParam field="SelectedRowsOnly" value="false"/>
				   <SetParam field="ExportType" value="Excel"/>
				   <SetParam field="Mode" value="AppendRows"/>
				   <SetParam field="ExcelSheetName" value="{%vProfileName%}"/>
				   <SetParam field="OpenFileOnceGenerated" value="False"/>
				</Export>
			</Values>
			
		</if>
		
	</Loop>
</ytriaAutomation>



Make the most of automation through these new EZ Suite features.



These brand-new features, combined with a good handle on Ytria's automation ensures unmatched power when it comes to handling large scale tasks. Check out some of the functions in place to help you make the most of automation.

Record your actions to scripts with the powerful new Automation Recorder.

An all-new Automation Recorder takes performance optimization to another level by letting you record and "replay" actions you've performed in the EZ Suite tools. Simply hit Record at the beginning of your process, do your work, and the recorder will save the steps in an independent automation file that can be either recalled at a later time "as is," or modified to fit your needs.



Build your automation lists fast with the 'Create Automation List from Selection' feature.

Thanks to the new Create Automation List from Selection function, you can quickly "export" a selection of entries to a properly formatted List that can be used in an automation script Loop.

Thousands of organizations use Ytria software for faster Notes development and better Domino administration
 

This website require JavaScript for full functionality.
Please enable JavaScript in your Web browser.