| Description: | With new ClientCtrl option 'scComSAMLightClientCtrlModeFlagMarkOrderAsSpecifiedWithNames' - powerful marking sequences can now be generated:
New flag 'scComSAMLightClientCtrlModeFlagMarkOrderAsSpecifiedWithNames' ( must be always in combination with flag 'scComSAMLightClientCtrlModeFlagEntityNamesSeparatedBySemicolon' ), it is now possible to generate marking sequences, which are really generated as defined in the entity names string.
BUT: Every single name in the names string requires internally in the SAM library the complete job to be iterated. So, if you are using many names AND the job is big, this new mode will need some time to execute.
Before ( or without the new flag ), iteration was based to the job file - so, if you have a singular entity name of the job used e.g. twice in the entity names list ( separated by semicolon ), the second definition was ignored. ( Only one complete job iteration internally done ).
Now, iteration is based to the entity names list, so every single entity name of the names list ( separated by semicolon ) is taken - and for every single name, a complete job iteration internally is done. This allows e.g. to select different entities with the same name for marking.
Code Example ( case Mark Trigger marking ):
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Diagnostics;
using SAMLIGHT_CLIENT_CTRL_OCXLib;
namespace WindowsFormsApplication1 { public partial class Form1 : Form { int mode = 0; int markFlags = 0;
public Form1() { InitializeComponent();
axScSamlightClientCtrl1.ScGetMode( ref mode ); axScSamlightClientCtrl1.ScSetMode( mode | ( int )( ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagEntityNamesSeparatedBySemicolon | ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagMarkOrderAsSpecifiedWithNames ) );
markFlags = axScSamlightClientCtrl1.ScGetMarkFlags();
axScSamlightClientCtrl1.ScSetMarkFlags( markFlags | ( int )ScComSAMLightClientCtrlMarkFlags.scComSAMLightClientCtrlMarkFlagWaitForTrigger );
int result = axScSamlightClientCtrl1.ScMarkEntityByName( "1;2;3;1;2;3;1;1;1;2;2;2;3;3;3", 0 ); Debug.Assert( result == 1 ); }
private void Form1_FormClosing( object sender, FormClosingEventArgs e ) { axScSamlightClientCtrl1.ScSetMode( mode & ( int )~( ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagEntityNamesSeparatedBySemicolon | ScComSAMLightClientCtrlFlags.scComSAMLightClientCtrlModeFlagMarkOrderAsSpecifiedWithNames ) ); axScSamlightClientCtrl1.ScSetMarkFlags( markFlags & ( int )~ScComSAMLightClientCtrlMarkFlags.scComSAMLightClientCtrlMarkFlagWaitForTrigger ); axScSamlightClientCtrl1.ScStopMarking(); } } }
|