Mincom LinkOne WinView Technical Reference
Mincom LinkOne WinView Technical Reference
5.11
Copyright 2010 by Mincom®. All rights reserved.
No part of this document may be reproduced, transferred, sold, or otherwise disposed of without the
written permission of Mincom Pty Ltd.
All trademarks are the copyright of their respective owners.
LinkOne is a registered trademark of Mincom Pty Ltd.
Microsoft, Windows, and the .NET Framework are registered trademarks of Microsoft Corporation.
Every effort has been made to ensure the accuracy of this manual. However, Mincom Pty Ltd makes
no warranties with respect to this documentation and disclaims any implied warranties of
merchantability and fitness for a particular purpose. Mincom Pty Ltd shall not be liable for any errors or
for incidental or consequential damages in connection with the furnishing, performance, or use of this
manual or the examples herein. The information in this document is subject to change without notice.
Contents
Technical Reference Copyright ................................................................................................................3
Technical Reference Requirements .........................................................................................................4
Overview ...................................................................................................................................................5
Working With Plugins ...............................................................................................................................6
Plugin Licensing ....................................................................................................................................7
Plugin Development Guidelines ............................................................................................................8
Using the LinkOne Dom ........................................................................................................................9
Overview of the Dom Library .............................................................................................................9
Reading Parts List Entries .................................................................................................................9
Reading an Entire Book ..................................................................................................................16
Conclusion .......................................................................................................................................21
Listening to LinkOne Events ...............................................................................................................22
Overview of LinkOne Controls ........................................................................................................22
Creating the Custom Control ...........................................................................................................22
Plugging in the control .....................................................................................................................28
Testing the control ...........................................................................................................................28
Customizing the Selection List ............................................................................................................30
Overview of the Selection List .........................................................................................................30
Creating the Selection List Plugin ...................................................................................................30
The ISelectionListService ................................................................................................................33
The Complete Plugin Source Listing ...............................................................................................35
Testing the Plugin............................................................................................................................37
Automating LinkOne WinView ................................................................................................................39
Remoting Configuration ......................................................................................................................40
Automation Reference ........................................................................................................................41
Connect ...........................................................................................................................................41
Execute ...........................................................................................................................................41
GetValue .........................................................................................................................................42
SetValue ..........................................................................................................................................42
HookEvent .......................................................................................................................................42
UnhookEvent ...................................................................................................................................43
HasEvent .........................................................................................................................................44
CreateEventHandler ........................................................................................................................44
LinkOne Configuration Manager ............................................................................................................45
Overview of IConfigurationManager ...................................................................................................46
Connecting to External Systems .....................................................................................................46
Slots ................................................................................................................................................46
IConfigurationManager Reference......................................................................................................47
ResolveObject .................................................................................................................................47
ResolveLink .....................................................................................................................................47
ResolveSlot .....................................................................................................................................48
DBMan ................................................................................................................................................49
The DBMan Database .....................................................................................................................49
Database Diagram of DBMan .........................................................................................................52
Dynamic Derived Books .........................................................................................................................53
The Book Structure .............................................................................................................................54
Book.Net.dll Assembly Requirements ................................................................................................55
Book.Net Methods ..............................................................................................................................56
DynamicDerivedBookProvider ........................................................................................................56
PrepareBook ...................................................................................................................................56
BookXML .........................................................................................................................................57
ii Contents
3
LinkOne WinView Technical Reference
4
LinkOne WinView Technical Reference
Overview
The articles in this document demonstrate the power and flexibility of LinkOne WinView and how
developers can take advantage of functionality within the LinkOne .Net development libraries and
integrate this into other applications.
5
LinkOne WinView Technical Reference
6
LinkOne WinView Technical Reference
Plugin Licensing
Creating a plugin for Linkone WinView requires either:
a publisher linked plugin license, which lets your plugin work only with books from a specific
publisher (you must have a Publisher Linked Viewer license or Media Linked Viewer license for
the same publisher installed as well)
an open plugin license, which lets your plugin work with all published books (you must have an
Open Viewer license installed as well)
Please contact your LinkOne reseller for details and associated costs of these two licenses.
Mincom can issue a plugin license when it obtains a copy of a signed plugin assembly from you.
Mincom extracts your signature from your plugin assembly and uses that signature within the plugin
license in order to differentiate your plugin from someone else's plugin.
If you have never signed an assembly, then follow the steps below:
1. use Visual Studio 2005 or later to create your first plugin from one of the coding examples in this
document
2. open up the properties window of your plugin project
3. select the Signing tab
4. select Sign the assembly option
5. select the <New..> option
6. enter a key file name, say key.snk
7. select OK and rebuild your plugin project to create the signed assembly
Once you have sent us your signed assembly, and you have received your license in return, you then
have two options on how to use it. Either:
install your plugin with LinkOne WinView and then add your license to the licenses in the
Configuration window, or
compile your license into your plugins.
If you choose the later method, then in your plugin projects, you will decorate your plugin classes with
[Plugin(License="......")]
public class MyPluginClass
{
}
7
LinkOne WinView Technical Reference
8
LinkOne WinView Technical Reference
9
LinkOne WinView Technical Reference
N.b. You will also need to add the following Microsoft .Net libraries: System.Windows.Forms
using System.IO;
using System.Windows.Forms;
using Mincom.LinkOne.Dom;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell.Services;
5. Add a Plugin attribute to the PartsListReader class to identify the class as a plugin to LinkOne.
[Plugin]
public class PartsListReader
public PartsListReader()
{
}
7. Create a new method called ExtractPartsList. It should accept a single argument of type object
which will be the LinkOne WinView graphical shell object passed to you, and it should not return
anything (i.e. void). Add the following code to your method:
The IBookService is a LinkOne WinView service that provides access to the Linkone content.
You can access the library, pages, pictures, formats, notes, etc of the currently opened book
and control the current view state of the viewer. We need to access to PageObject property
which will return the currently viewed Mincom.LinkOne.Dom.IPage object. We will then read
the parts list entries from the page and format these into a CSV file.
8. Add a new method to your class called ReadPage which returns a string and accepts a
Mincom.LinkOne.Dom.IPage object as a single argument. This method will be responsible for
10
LinkOne WinView Technical Reference
reading through the current page entries and tabulating them into CSV format. Enter the following
code into the method:
9. Now we need a method to write our CSV values to a file. In this example we will use a basic
StreamWriter object and create a temporary file on C:\. We will name the file in the following
format Publisher Code - Book Code - Page References.csv. Please note that we have not included
proper exception handling - this is only for brevity's sake. You should always follow Microsoft's
guidelines for exception handling.
10. Create a new method called WriteToCsvFile that accepts two arguments, the first being a string
named data, the second also a string named fileName. It should not return anything (i.e. void).
Enter the following code into the method:
11. We now need to go back to our original ExtractPartsList method and call our newly created
methods. After you have retrieved the IBookService object, add the following lines:
// we now have our entry data, stream this to a new .csv file
string fileName = bookService.View.PublisherCode + "-" + bookService.View.BookCode
+ "-" + bookService.View.PageReference;
WriteToCsvFile( entryData, fileName );
MessageBox.Show( @"Parts list written to c:\" + fileName + ".csv" );
}
else
{
MessageBox.Show( "You must first open a page with a parts list" );
}
11
LinkOne WinView Technical Reference
// we now have our entry data, stream this to a new .csv file
string fileName = bookService.View.PublisherCode + "-" +
bookService.View.BookCode + "-" + bookService.View.PageReference;
WriteToCsvFile( entryData, fileName );
MessageBox.Show( @"Parts list written to c:\" + fileName + ".csv" );
}
else
{
MessageBox.Show( "You must first open a page with a parts list" );
}
}
}
using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Windows.Forms;
using Mincom.LinkOne.Dom;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell.Services;
namespace PartsListReader
{
[Plugin]
public class PartsListReader
{
/// <summary>
/// Constructor.
/// </summary>
public PartsListReader()
{
}
/// <summary>
/// Extracts a parts list into a formatted CSV file
/// </summary>
/// <param name="shell">The IShellForm containing the book that parts list
resides on.</param>
public void ExtractPartsList( object shell )
{
IShellForm shellForm = shell as IShellForm;
if( shellForm != null )
{
IBookService bookService = (IBookService)shellForm.Services.GetService(
typeof( IBookService ) );
if( bookService.PageObject != null )
{
string entryData = ReadPage( bookService.PageObject );
// we now have our entry data, stream this to a new .csv file
string fileName = bookService.View.PublisherCode + "-" +
bookService.View.BookCode + "-" + bookService.View.PageReference;
WriteToCsvFile( entryData, fileName );
MessageBox.Show( @"Parts list written to c:\" + fileName + ".csv" );
}
else
{
MessageBox.Show( "You must first open a page with a parts list" );
}
}
12
LinkOne WinView Technical Reference
/// <summary>
/// Reads page data into a csv string.
/// </summary>
/// <param name="page">The Mincom.LinkOne.Dom.IPage object to read entries
from.</param>
/// <returns>A formatted csv string containing the entry data.</returns>
private string ReadPage( IPage page )
{
// add initial entry headings
StringBuilder csvString = new StringBuilder( "Item ID, Part Number,
Description" + Environment.NewLine );
return csvString.ToString();
}
/// <summary>
/// Writes our CSV data out to a file.
/// </summary>
/// <param name="data">The formatted csv data to write out.</param>
/// <param name="fileName">The filename of the file to write to.</param>
private void WriteToCsvFile( string data, string fileName )
{
using( StreamWriter writer = new StreamWriter( @"c:\" + fileName + ".csv" )
)
{
try
{
writer.Write( data );
}
catch( IOException )
{
// ignore error for now - you should normally handle these errors.
}
}
}
}
13
LinkOne WinView Technical Reference
<tools>
</tools>
4. You now have a section for adding customized tool buttons. Add the following tool definition inside
the tools section.
<tool type="ToolButton"
name="ExtractPartsList"
title="Send Parts List to CSV"
tooltip="Write parts list entries to csv file..."
handler="PartsListReader.PartsListReader.ExtractPartsList"
/>
14
LinkOne WinView Technical Reference
15
LinkOne WinView Technical Reference
6. Open a book and a page with some parts list information. Click you new command button, and
then you should see a message box telling you the file name and location of where it was saved.
Open this file from Windows Explorer and you will see your parts list in Microsoft Excel.
using System.IO;
using System.Xml;
using System.Windows.Forms;
using Mincom.LinkOne.Dom;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell.Services;
2. Add an empty constructor and a new method called ExtractBookToXml that accepts an object
named shell. Declare a variable and set it to the IShellForm and IBookService in the
ExtractBookToXmlMethod and add the following code to your method.
public BookXmlWriter()
{
}
16
LinkOne WinView Technical Reference
3. We now need to implement the new method ExtractBookToXml. This method will iterate through
the book's pages and start writing out XML data to an XmlDocument. The ExtractBookToXml
method should look like the following code excerpt.
4. After we have written our book information to XML, we need to get all of our pages from the book.
Page information is stored in the IBook.Pages property. We will pass this to a new method called
ExtractPages, along with our XmlDocument to extract this information. Complete the new method
with the following code.
5. For each page inside the book, the ExtractEntries method will extract all entries on that page. Add
the following method to complete our XML generation.
entries.AppendChild( newEntry );
}
return entries;
}
6. Lastly, we need a method called WriteXmlToFile which we are calling from our WriteBookToXml
method.
{
writer.Write( doc.OuterXml );
}
catch( IOException )
{
// ignore error for now - you should normally handle these errors.
}
}
}
using System.IO;
using System.Xml;
using System.Windows.Forms;
using Mincom.LinkOne.Dom;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell.Services;
namespace PartsListReader
{
public class BookXmlWriter
{
public BookXmlWriter()
{
}
entries.AppendChild( newEntry );
}
return entries;
}
<tool type="ToolButton"
name="ExtractBookXml"
title="Write Book to XML"
tooltip="Write book structure to xml file..."
handler="PartsListReader.BookXmlWriter.WriteBookToXml"
/>
19
LinkOne WinView Technical Reference
20
LinkOne WinView Technical Reference
2. Save your Mincom.LinkOne.WinView.config file and start LinkOne WinView. Open a book and
click your new tool button on the Navigation toolbar. Open your new file from Windows Explorer
and you will see the contents of your book in XML format.
Conclusion
The LinkOne Dom library provides access to LinkOne content and it is easy to extract this information
quickly and to any file format. You could try developing an extension to these samples to write the data
from notes out to a database and use this information to keep all of the notes on your LinkOne
installations synchronized.
We encourage all LinkOne customers to harness the potential of the LinkOne Document Object Model
and the Mincom Windows Shell framework to integrate LinkOne WinView into their applications.
21
LinkOne WinView Technical Reference
22
LinkOne WinView Technical Reference
[Plugin]
[Description( "DB Lookup" )]
public class PartsListDBLookup
using System.ComponentModel;
using System.Xml;
using System.Drawing;
using Mincom.LinkOne.WinView.Services;
6. Our class also needs to inherit from UserControl. Alter the class declaration statement as shown
below. You will notice that we do not have a typical form in our designer. Instead we have a
container which holds all visual controls that we will be placing on our form later. When LinkOne
WinView loads our plugin it will display all of the container's controls inside a plugin form which
can be a tabbed or floating control in the same way as the parts control can be.
7. Switch to Designer mode in the Visual Studio Editor so we can place our controls on the form. You
can do this by pressing Shift + F7 in the PartsListDBLookup.cs code window.
8. Add the following controls:
Type Name Properties to Change
label label1 Text = "Item ID"
label label2 Text = "Qty in Stock"
label label3 Text = "Price ($)"
label _itemId Text = ""
label _qty Text = ""
label _price Text = ""
9. Our control should look like the following:
<parts>
<part itemid="1" price="34.23" qtyinstock="27" />
<part itemid="2" price="673.21" qtyinstock="5" />
<part itemid="3" price="4.99" qtyinstock="193" />
<part itemid="4" price="59.32" qtyinstock="41" />
<part itemid="5" price="9.79" qtyinstock="85" />
<part itemid="6" price="33.89" qtyinstock="32" />
</parts>
23
LinkOne WinView Technical Reference
Note: We have used simple Item ID's in this example - The test book we are using has a
number of entries in the parts list that number from 1 to 5. If you wish to use this sample with
another book, you should use item id's that correspond to those in your book.
public PartsListDBLookup()
{
if( File.Exists( @"plugins\XmlDB.xml" ) )
{
_xml.Load( @"plugins\XmlDB.xml" );
}
else
{
MessageBox.Show( @"Cannot find XML - Please place XmlDB.xml in your LinkOne
Bin\Plugins directory" );
}
InitializeComponent();
}
14. When LinkOne WinView loads each plugin, it is Sited which allows the LinkOne WinView Shell to
communicate with our plugin component. We need to override the Site property exposed by
UserControl and then get references the required services from the shell form. Add the following
property definition to your PartsListDBLookup.cs file:
/// <summary>
/// The Component Site
/// </summary>
public override ISite Site
{
get
{
return base.Site;
}
set
{
base.Site = value;
if( value != null )
{
// hook services
_shell = (IShellForm)GetService( typeof( IShellForm ) );
_bookService = (IBookService)GetService( typeof( IBookService ) );
// there must be a shell to add ourselves to when shown
if( _shell == null )
{
MessageBox.Show( "Cannot find LinkOne - shutting down" );
throw new Exception();
}
_shell.Shown += delegate( object sender, EventArgs args )
{
_shell.Panels.Add( this );
24
LinkOne WinView Technical Reference
15. In the property defined above, we have hooked up an anonymous method to show ourselves as a
panel in the Shells panel collection, and also set our title to be "Parts List Data". We have then
defined another anonymous method to synchronize data with our form using the current entry item
id.
16. Lastly, we need to implement our Synchronize method which will take the EntryItemId and search
for in our xml file. Alternatively, we could search for it in a database or text file. Add the following
method to your PartsListDBLookup.cs file:
17. In the Synchronize method we first make sure that we are visible, and if we aren't, we ask the
ShellForm to show us. We then find the correct corresponding node from our XML file and show
the part information from it. This method could also connect to a database however the goal here
is only to illustrate how to listen and respond to LinkOne events.
18. Build your project and copy the PartsListDBLookup.dll file and the XmlDB.xml file to your LinkOne
WinView Bin|Plugins folder.
using System;
using System.ComponentModel;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Xml;
using System.Drawing;
using System.Windows.Forms;
using Mincom.LinkOne.WinView.Services;
25
LinkOne WinView Technical Reference
using Mincom.Windows.Shell.Services;
namespace PartsListDBLookup
{
[Plugin]
[Description( "DB Lookup" )]
public class PartsListDBLookup : UserControl
{
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label _qty;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label _price;
private System.Windows.Forms.Label _itemId;
private IShellForm _shell;
private IBookService _bookService;
private XmlDocument _xml = new XmlDocument();
/// <summary>
/// Constructor.
/// </summary>
public PartsListDBLookup()
{
/// <summary>
/// The Component Site
/// </summary>
public override ISite Site
{
get
{
return base.Site;
}
set
{
base.Site = value;
if( value != null )
{
// hook services
_shell = (IShellForm)GetService( typeof( IShellForm ) );
_bookService = (IBookService)GetService( typeof( IBookService ) );
/// <summary>
/// Syncronize entry item id data with xml data.
/// </summary>
private void Synchronize( string itemId )
{
if( !Visible )
{
_shell.Panels.Show( this );
}
_itemId.Text = itemId;
XmlNode node = _xml.SelectSingleNode( "//parts/part[@itemid='" + itemId + "']"
);
if( node != null )
{
_price.Text = "$" + node.Attributes[ "price" ].Value;
_qty.Text = node.Attributes[ "qtyinstock" ].Value;
}
else
{
_price.Text = "Item not found...";
_qty.Text = "Item not found...";
}
}
/// <summary>
/// Designer Generated Code
/// </summary>
private void InitializeComponent()
{
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this._itemId = new System.Windows.Forms.Label();
this._qty = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this._price = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point( 28, 5 );
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size( 41, 13 );
this.label1.TabIndex = 0;
this.label1.Text = "Item ID";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point( 3, 29 );
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size( 66, 13 );
this.label2.TabIndex = 1;
this.label2.Text = "Qty In Stock";
//
// _itemId
//
27
LinkOne WinView Technical Reference
this._itemId.AutoSize = true;
this._itemId.Location = new System.Drawing.Point( 77, 5 );
this._itemId.Name = "_itemId";
this._itemId.Size = new System.Drawing.Size( 0, 13 );
this._itemId.TabIndex = 2;
//
// _qty
//
this._qty.AutoSize = true;
this._qty.Location = new System.Drawing.Point( 77, 29 );
this._qty.Name = "_qty";
this._qty.Size = new System.Drawing.Size( 0, 13 );
this._qty.TabIndex = 3;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point( 23, 52 );
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size( 46, 13 );
this.label3.TabIndex = 4;
this.label3.Text = "Price ($)";
//
// _price
//
this._price.AutoSize = true;
this._price.Location = new System.Drawing.Point( 77, 52 );
this._price.Name = "_price";
this._price.Size = new System.Drawing.Size( 0, 13 );
this._price.TabIndex = 5;
//
// PartsListDBLookup
//
this.Controls.Add( this._price );
this.Controls.Add( this.label3 );
this.Controls.Add( this._qty );
this.Controls.Add( this._itemId );
this.Controls.Add( this.label2 );
this.Controls.Add( this.label1 );
this.Name = "PartsListDBLookup";
this.Size = new System.Drawing.Size( 310, 83 );
this.ResumeLayout( false );
this.PerformLayout();
}
}
}
2. You will now see our control, however no information will be displayed as we have not yet
selected an entry from the parts list.
29
LinkOne WinView Technical Reference
30
LinkOne WinView Technical Reference
1. Start Visual Studio and create a new C# Windows Class Library. Call your project
MySelectionListPlugin and click OK to create your project. Once the project has been created,
rename Class1.cs to MySelectionListPlugin.cs.
using System.ComponentModel;
using System.IO;
using System.Xml;
using Mincom.LinkOne.Dom.SelectionList;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell;
using System.Reflection;
4. Add the [Plugin] attribute above your class declaration. This signals to LinkOne WinView that we
are a plugin and can be loaded. Take note that all plugins must have an empty constructor.
5. Inherit from the Component class by adding : Component after your class declaration.
6. Your class should now build with no errors or warnings. If it does not, please refer to the skeletal
class below to locate any errors.
using System;
using System.Collections.Generic;
using System.Text;
using System.ComponentModel;
using System.IO;
31
LinkOne WinView Technical Reference
using System.Xml;
using Mincom.LinkOne.Dom.SelectionList;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell;
using System.Reflection;
namespace MySelectionListPlugin
{
[Plugin]
public class MySelectionListPlugin : Component
{
public MySelectionListPlugin()
{
}
}
}
2. Inside the constructor we will need to load the files contents into our XML document.
ISelectionListService _selectionListService;
32
LinkOne WinView Technical Reference
2. Next, override the Site property and we will obtain a reference to the selection list service running
in LinkOne WinView.
The ISelectionListService
The ISelectionListService interface exposes events and properties that can be accessed by other
plugins inside the LinkOne WinView application. When we are sited we can ask the LinkOne WinView
hosting shell to find services that may be running and then reference these from our plugin. When we
find the SelectionListService service, we will do the following:
Add our new custom columns to the selection list.
Hook the event for when a selection list is loaded.
Hook the event for when a part is added to the selection list.
Hook the event for when a part is changed within the selection list.
2. We next need to have a method called AddColumns which will check that our columns are not
currently existing in the selection list and if not, add them.
3. Next we need to call AddColumns when we are sited, and then hook our events in the setter.
set
{
33
LinkOne WinView Technical Reference
base.Site = value;
if( Site != null )
{
_selectionListService = (ISelectionListService)GetService( typeof(
ISelectionListService ) );
if( _selectionListService == null )
{
throw new Exception( "Selection List Service is not present" );
}
AddColumns();
_selectionListService.PartAdding += new PrePartEventHandler(
_selectionListService_PartAdding );
_selectionListService.PartChanged += new PostPartEventHandler(
_selectionListService_PartChanged );
_selectionListService.SelectionListLoaded += new EventHandler(
_selectionListService_SelectionListLoaded );
}
}
4. To handle our events, we have defined a number of methods. If a part is added or changed, we
need to populate our column information each time and update it. If a new selection list is loaded
however, we only need to make sure that our columns are present in the selection list.
{
// Just a simple message to let the user know we couldn't find the part in the
data source
part.Fields[ "SOH" ].Value = "Not Found";
part.Fields[ "Total" ].Value = "Not Found";
}
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.IO;
using System.Text;
using System.Xml;
using Mincom.LinkOne.Dom.SelectionList;
using Mincom.LinkOne.WinView.Services;
using Mincom.Windows.Shell;
using System.Reflection;
/// <summary>
/// This sample demonstrates adding user defined fields to the selection list.
/// The plugin will add stock-on-hand (soh) and a total (price * quantity) fields.
/// When a part is added to the selection list, the price and soh fields
/// are populated from an external data source (an XML file).
/// </summary>
[Plugin]
public class MySelectionListPlugin : Component
{
ISelectionListService _selectionListService;
/// <summary>
/// Creates an instance of the <see cref="MySelectionListPlugin"/>.
/// </summary>
public MySelectionListPlugin()
{
// Read the data
string selectionsDbPath = Path.Combine( Path.GetDirectoryName(
Assembly.GetExecutingAssembly().Location ), "selectionsDB.xml" );
if( File.Exists( selectionsDbPath ) )
{
_xml.Load( selectionsDbPath );
}
else
{
throw new FileNotFoundException( @"Cannot find XML - Please place
selectionsDB.xml in your LinkOne Bin\Plugins directory" );
}
}
/// <summary>
/// Gets or sets the site that hosts us.
/// </summary>
public override ISite Site
{
get
35
LinkOne WinView Technical Reference
{
return base.Site;
}
set
{
base.Site = value;
if( Site != null )
{
_selectionListService = (ISelectionListService)GetService( typeof(
ISelectionListService ) );
if( _selectionListService == null )
{
throw new Exception( "Selection List Service is not present" );
}
AddColumns();
_selectionListService.PartAdding += new PrePartEventHandler(
_selectionListService_PartAdding );
_selectionListService.PartChanged += new PostPartEventHandler(
_selectionListService_PartChanged );
_selectionListService.SelectionListLoaded += new EventHandler(
_selectionListService_SelectionListLoaded );
}
}
}
/// <summary>
/// Handles the selection list loaded event.
/// </summary>
private void _selectionListService_SelectionListLoaded( object sender, EventArgs
e )
{
AddColumns();
}
/// <summary>
/// Handles a part being added to the selection list.
/// </summary>
private void _selectionListService_PartAdding( object sender, PrePartEventArgs e
)
{
PopulateSelectionList( e.Part );
}
/// <summary>
/// Handles a part being changed.
/// </summary>
private void _selectionListService_PartChanged( object sender, PostPartEventArgs
e )
{
PopulateSelectionList( e.Part );
}
/// <summary>
/// Adds the columns to the selection list.
/// </summary>
private void AddColumns()
{
// If the selection list was loaded it may already have definitions for these
columns
// only add them if they don't already exist
if( !_selectionListService.CurrentSelectionList.Columns.Contains(
_stockOnHandColumn ) )
{
_selectionListService.CurrentSelectionList.Columns.Add( _stockOnHandColumn
);
}
if( !_selectionListService.CurrentSelectionList.Columns.Contains(
_totalColumn ) )
{
36
LinkOne WinView Technical Reference
_selectionListService.CurrentSelectionList.Columns.Add( _totalColumn );
}
}
/// <summary>
/// Populate our user-defined columns with data.
/// </summary>
/// <param name="part">The selection list part entry to update.</param>
private void PopulateSelectionList( IPart part )
{
if( part != null && part.Fields.Count > 0 )
{
string partNumber = part.Fields[ "Part Number" ].Value;
XmlElement node = _xml.SelectSingleNode( "//parts/part[@partnumber='" +
partNumber + "']" ) as XmlElement;
37
LinkOne WinView Technical Reference
38
LinkOne WinView Technical Reference
39
LinkOne WinView Technical Reference
Remoting Configuration
Your external application will connect to LinkOne WinView using Microsoft .Net remoting, and then talk
directly to the Automation plugin. The configuration of the remoting communications for the
Automation plugin is found in the LinkOne.exe.config file, and by default, the section looks like:
<system.runtime.remoting>
<application>
<channels>
<channel ref="ipc" portName="Mincom.LinkOne.WinView">
<!--channel ref="http" port="8080"-->
<clientProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</clientProviders>
<serverProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</serverProviders>
</channel>
</channels>
</application>
</system.runtime.remoting>
You need an equivalent matching remoting configuration for any controlling client application, similar
to:
<system.runtime.remoting>
<application>
<client>
<!--wellknown type="Mincom.LinkOne.WinView.Common.Automation,
Mincom.LinkOne.WinView.Common" url="http://localhost:8080/Automation" /-->
<wellknown type="Mincom.LinkOne.WinView.Common.Automation,
Mincom.LinkOne.WinView.Common" url="ipc://Mincom.LinkOne.WinView/Automation" />
</client>
<channels>
<!--channel ref="http" port="0" -->
<channel ref="ipc" portName="Mincom.LinkOne.WinView.Client">
<clientProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</clientProviders>
<serverProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</serverProviders>
</channel>
</channels>
</application>
</system.runtime.remoting>
This default configuration is useful for controlling LinkOne WinView when it is running on the same PC
as the controlling client application. By commenting out the ipc channel tags, and uncommenting the
http channel tags, you will instantly get the ability to control LinkOne WinView over a HTTP channel
between different PCs. You can experiment with controlling multiple instances of LinkOne WinView
on the same server PC by altering the port name (ipc) or port number (http) between instances.
40
LinkOne WinView Technical Reference
Automation Reference
Connect
Method Overview
Connect to the LinkOne WinView Process.
Exceptions
RemotingException - An error trying to connect to LinkOne WinView.
TimeoutException - A connection could not be established in time.
FileNotFoundException - LinkOne WinView could not be found to start.
Method Signatures
Method Parameters
timeoutSeconds - The time to wait while trying to connect. Supplying a value of:
less than 0, means don't start LinkOne WinView if needed
0, means do start LinkOne WinView if needed, but don't wait for a connection
greater than 0, means do start LinkOne WinView if needed, and then wait up until the
specified time to connect
applicationFileName - The full path where the LinkOne WinView application is found if it is to be
started, or null to use the application found in the directory this assembly is in.
arguments - The command line arguments for the LinkOne WinView application if it is to be started, or
null or empty string for no arguments.
Example
Execute
Method Overview
This method executes a LinkOne command on the connected LinkOne WinView.
It is possible that a call to Execute could block with a dialog popping up on LinkOne WinView. It is
also possible that events could also be fired during the execution.
Method Signature
Method Parameters
command - The LinkOne Command to execute, enclosed in square brackets (i.e. '[' and ']'). Please
refer to the LinkOne Command Strings reference for details of all LinkOne commands that can be
executed.
41
LinkOne WinView Technical Reference
Example
automation.Execute( "[APP.MINIMIZE]" )
GetValue
Method Overview
This method gets a named value from LinkOne WinView for the current view state. The value can be a
pre-defined value or a user defined value.
Method Signature
Method Parameters
name - The name of the value to return. Please refer to the Mincom LinkOne WinView 5.11 API
Reference for details of all predefined value names.
Example
SetValue
Method Overview
This method sets a named value into LinkOne WinView.
Method Signature
Method Parameters
name - The name of the value to set. The only available name is "SELECTIONS" to set the selection
list content.
value - The value to set.
Example
HookEvent
Method Overview
This method hooks an event on LinkOne WinView and calls the given event handler.
The event handler will usually be called a background thread, so any user interface manipulation will
need to be invoked through to the foreground thread.
The event will also be received asynchronously during a call to other methods on the Automation
class. For example, during a call to
42
LinkOne WinView Technical Reference
Automation.Execute( "[Go.Direct(MyPublisherCode,MyBookCode)]")
the
BookService.ViewChanged
ATTENTION.CLICKED
BOOKSERVICE.CATEGORIESCHANGED
BOOKSERVICE.NOTESCHANGED
BOOKSERVICE.VIEWCHANGED
SELECTIONLISTSERVICE.PARTADDED
SELECTIONLISTSERVICE.PARTCHANGED
SELECTIONLISTSERVICE.PARTREMOVED
SELECTIONLISTSERVICE.SELECTIONLISTCLEARED
SELECTIONLISTSERVICE.SELECTIONLISTLOADED
SHELLFORM.CLOSED
Please refer to the Mincom LinkOne WinView 5.11 API Reference for details on when these events
are fired.
Method Signature
Method Parameters
eventName - The name of the event to hook.
eventHandler - The event handler to call when the event is fired on LinkOne WinView.
Example
UnhookEvent
Method Overview
This method unhooks an event on LinkOne WinView that was previously hooked with a call to
HookEvent.
Method Signature
Method Parameters
eventName - The name of the event to unhook.
eventHandler - The event handler used in the prior call to HookEvent for the same event name.
Example
43
LinkOne WinView Technical Reference
HasEvent
Method Overview
This method determines if the given event can be hooked.
Method Signature
Method Parameters
eventName - The name of the event to test for.
Example
CreateEventHandler
Method Overview
Creates an event handler for remoting.
Method Signature
Method Parameters
eventHandler - The event handler to be called when an event is hooked with HookEvent.
Example
44
LinkOne WinView Technical Reference
45
LinkOne WinView Technical Reference
Overview of IConfigurationManager
The IConfigurationManager interface provides a link interface to the LinkOne DOM by means of three
methods; ResolveObject, ResolveLink, and ResolveItem. The purpose of each implemented method is
to dynamically link information from a database or a LinkOne book to a point in a LinkOne book.
This provides developers with a common interface which allows them to develop an adapter which
provides a bridge to send information from an external ERP/EAM system to and from LinkOne
applications.
Because the bridge allows LinkOne to receive and send information an external application can also
provide links to dynamic content inside a LinkOne book. This allows a books content to change without
the need to republish LinkOne content.
Slots
A slot is a dynamic entry inside a parts list which contains a link to information that is provided from an
external source such as a database from an ERP/EAM system. When a user clicks on the entry inside
a LinkOne Viewer, instead of accessing information from the book, LinkOne will pass the request to
any component implementing the IConfigurationManager interface.
This allows the configuration manager component to determine where the slot should link to, and then
pass this information back into the Viewer to open the appropriate location, thus making it a dynamic
entry.
An example of where using slots is useful is a Materials Plant which contains a range of equipment
each of which have their own LinkOne book. A master book that describes the entire plant will contain
a number of slots for each piece of equipment inside the plant.
If a piece of equipment breaks down, for example a water pump, and a different model and type of
water pump is installed in its place, you will need to change the book location that the slot entry points
to. This information can be stored inside a database which is managed by your ERP/EAM system.
Using configuration manager you can request information about the equipment location where the
water pump resides and re-direct the link to the correct LinkOne book.
46
LinkOne WinView Technical Reference
IConfigurationManager Reference
ResolveObject
Method Overview
This method resolves a link between an object identifier (often referred to as an equipment id) and a
LinkOne book. The method can supply the publisher code, book code, page reference and filters for
the book.
If a publisher and book can be found using the object identifier the method will return the boolean
value true and all method out parameters will be populated with the values of the publisher, book,
page and filters collection. If a book cannot be found the method will return the boolean value false and
all method out parameters will be empty.
Method Signature
Method Parameters
objectIdentifier - The object identifier to resolve.
includeFilters - True to also return the option filters, False to ignore option filters.
publisherCode - The resolved publisher code of the object identifier.
bookCode - The resolved book code of the object identifier.
pageReference - The resolved page reference of the object identifier, or null or an empty string if there
is no specific page.
filters - The resolved filters of the object identifier, or null or an empty collection if there are no specific
filters.
ResolveLink
Method Overview
This method resolves a link between a slot on a page and an object identifier (often referred to as an
equipment id). A slot is a single entry on a page which is identified by a page reference and an item id.
If a slot can be found, then linkObjectIdentifier will be supplied and the method will return the boolean
value true. If a slot cannot be found, then the method will return the boolean value false.
Method Signature
Method Parameters
objectIdentifier - The object identifier to resolve.
pageReference - The page reference of the page that contains the item that is to be resolved.
itemIdentifier - The item id of the item to be resolved.
linkObjectIdentifer - The equipment code of the resolved item.
47
LinkOne WinView Technical Reference
ResolveSlot
Method Overview
This method dynamically substitutes cross reference links on a slot in a LinkOne book. A slot
represents a unique item on a page and is identified by a page reference and an item id. The method
looks at where the component (in this case a linked entry on a page) links to, and if the component slot
that is linked to exists, then the method will supply linkObjectIdentifier.
If the linked component can be found, then linkObjectIdentifier will be supplied and the method will
return true. If the linked component cannot be found, then method will return false.
Method Signature
Method Parameters
objectIdentifier - The object identifier that the component belongs to.
slotIdentifier - The slot identifier where the component links to.
linkObjectIdentifier - The object identifier the slot links to.
48
LinkOne WinView Technical Reference
DBMan
DBMan is an example implementation of the IConfigurationManager interface which uses CSV files as
a database to store configuration manager data.
In this release we have included DBMan pre-compiled along with full source. You will find both listed
as optional features when you select to perform a Custom installation. Your can look through the
DBMan source code and we encourage you to customize it to suit your business needs.
Due to the open architecture of the latest LinkOne Viewers and the supplied development libraries we
are encouraging all users of DBMan to use the IConfigurationManager interface to leverage the power
of the LinkOne development framework and closely couple their existing Enterprise Systems with
LinkOne Viewers directly.
BOOK Table
Overview
The book table relates an equipment class or id to a book or page inside a library.
Fields
Field Name Required Description
Object Yes The equipment ID or the equipment class (which is a
foreign key reference the CLASS table).
Publisher Yes The publisher code of the book which contains
Code information about the equipment ID or class.
Book Code Yes The book code of the book which contains information
about the equipment ID or class.
Reference No The page reference of the page which contains
information about the equipment ID or class.
Example
Assume that we have two equipment classes, one called TRUCK for all trucking equipment and one
called EARTH for all earth moving equipment. We will also use equipment id's CRANE, ENGINE1,
ENGINE2 and ENGINE3 for direct links to books containing information about engine types.
Our CSV file would look something like the following:
TRUCK,KOMATSU,KOM-TRUCK
EARTH,KOMATSU,KOM-EARTH,REF-EARTH01
CRANE,KOMATSU,KOM-CRANE
ENGINE1,KOMATSU,BK_E1
ENGINE2,KOMATSU,BK_E2
49
LinkOne WinView Technical Reference
ENGINE3,KOMATSU,BK_E3
CLASS Table
Overview
The class table creates a relationship between an equipment class and an equipment ID. This allows
you to create a relationship between a class and a book in the BOOKS table, and refer to this book
from more than one equipment ID.
Fields
Field Name Required Description
Equipment Id Yes The equipment ID which will belong to the equipment
class.
Equipment Yes The equipment class which is related to the equipment
Class ID.
Example
Assume that we have an equipment class called TRUCK for all trucking equipment and another class
called EARTH for all earth moving equipment. We can assign a number of equipment codes to each
class. Our CSV file will look something like the following:
BIGTRUCK,TRUCK
SMALLTRUCK,TRUCK
MEDTRUCK,TRUCK
BIGEXCAVATOR,EARTH
SMALLEXCAVATOR,EARTH
BOBCAT,EARTH
Notice that we have now created a link between an equipment ID and a book by using the equipment
class to look up the book in the BOOK table.
OPTION Table
Overview
The option table allows you to define option filters for an equipment class or ID. When a book is
opened via an equipment class or ID, its option filters from this table will be applied. Where a piece of
equipment has a class, both the equipment ID and equipment class option filters are selected, with
precedence given to the equipment ID option filters if a value is set for the same option filter.
Fields
Field Name Required Description
Object Yes The equipment ID or the equipment class to apply the
option filter to.
Option Filter Yes The name of the option filter to apply the value to.
Value Yes The value to apply to the option filter.
Example
Assume that we have an equipment class called TRUCK for all trucking equipment and an option filter
CNTRY which determines the country that a part number applies to, along with the default option
filters SN and PSN. Our CSV file would look something like the following:
TRUCK,SN,4400
50
LinkOne WinView Technical Reference
TRUCK,PSN,4000
CRANE_AUS,CNTRY,AUS
CRANE_USA,CNTRY,USA
CRANE_JPN,CNTRY,JPN
CRANE_SMALL,SN,6593
SLOT Table
Overview
The slot table allows you to define a dynamic link from an item in a book, which is exchangeable for a
different item. An example would be a truck that has a parts list entry called engine which is a link to
another book containing information about that engine. Because the truck can have a number of
different engines each with their own LinkOne book, a slot is defined on the engine entry and will
determine which engine book the link will point to. When a different engine is used in the truck, the slot
can be updated and the correct book will be displayed when following the link from the parent truck
book to the engine part list entry link.
Whenever a book is opened via the equipment ID or class in the Object field and a link is followed
from the parts list, this table will be checked to see if a slot exists on the current part entry.
Fields
Field Name Required Description
Object Yes The equipment ID or the equipment class which will be
used for the slot.
Slot Name Yes The unique name for the slot.
Page Yes The page reference of the page that contains the link
Reference origin.
Item Id Yes The item id of the item that contains the link origin.
Example
Assuming that we have an equipment class called TRUCK for all trucking equipment and we want to
map the engine entry in page reference 5 on item id 12. Our CSV file would look something like the
following:
TRUCK,TRUCK_ENGINE,PGREF5,12
COMPONENT Table
Overview
The component table defines information about a slot that is defined in the SLOT table. When an entry
link is followed from LinkOne, DBMan will look up the component table to check the equipment ID or
class that contains link information about where to link to. This information is then used to find the
publisher code, book code, and page reference from the BOOK and CLASS tables. A link will be
constructed and the viewer will be forwarded to the final link location.
Fields
Field Name Required Description
Object Yes The equipment ID or the equipment class that the slot
belongs to.
Slot Name Yes The unique name for the slot.
51
LinkOne WinView Technical Reference
Example
In this example below, a user has clicked on a slot TRUCK_ENGINE which resides on item ID 12 from
page reference PGREF5 in the book from the TRUCK class. DBMan will now look for ENGINE3 in the
BOOK table and link to the KOMATSU book with book code BK_E3.
TRUCK,TRUCK_ENGINE,ENGINE3
52
LinkOne WinView Technical Reference
53
LinkOne WinView Technical Reference
Publisher-Directory
- MAN.DEF
- Base Book Folder
- BOOK.DEF
- BOOK.BBI
- *.PIX
- *.ILG
- *.BLI
- Dynamic Derived Book Folder
- BOOK.DEF
- book.net.dll
- Publisher Specific Data Files
54
LinkOne WinView Technical Reference
55
LinkOne WinView Technical Reference
Book.Net Methods
DynamicDerivedBookProvider
Overview
The DynamicDerivedBookProvider class must contain a public constructor with no arguments.
LinkOne WinView will use this constructor to create a DynamicDerivedBookProvider instance.
Signature
public DynamicDerivedBookProvider()
Parameters
None.
PrepareBook
Overview
This method will attempt to prepare the book based upon publisherCode, bookCode, pageReference,
itemId, currentPublisherCode, currentBookCode and filters parameters passed to the method. The
assembly can then use these values to create a dynamic derived book, for example through user
interaction or database interaction, which can be used by LinkOne WinView. The method will return
an integer value describing the result of the preparation.
Signature
Parameters
publisherCode The publisher code of the wanted book.
bookCode The book code of the wanted book.
pageReference The page reference of the wanted page.
itemId The item id of the wanted item.
currentPublisherCode The publisher code of the current book.
currentBookCode The book code of the current book.
currentFilters The current filters.
The filters are comma delimited, the format of each filter is
FilterName:FilterValue:FilterType:FilterScope:FilterAccess.
For more information on the formatting of the filters see
Mincom.LinkOne.Dom.FilterCollection in the LinkOne WinView
API documentation.
languageCode The language code of the current file provider's library.
56
LinkOne WinView Technical Reference
Return Type
int The return type signifies the outcome of preparing the book.
The return value can be:
0 if the book was prepared successfully.
1 if loading the book failed.
2 if the loading was aborted by the user.
BookXML
Overview
The BookXml property will get the book XML for the derived book. LinkOne WinView will access this
property only after it has called PrepareBook() and if that call was successful in preparing a derived
book. The string that is returned must be properly formatted XML, which is then parsed by LinkOne
into a derived book.
Sample Output
57
LinkOne WinView Technical Reference
using System;
namespace Mincom.LinkOne
{
/// <summary>
/// Summary description for DynamicDerivedBookProvider.
/// </summary>
public class DynamicDerivedBookProvider
{
/// <summary>
/// Constructor.
/// </summary>
public DynamicDerivedBookProvider ()
{
//
// TODO: Add constructor logic here
//
}
/// <summary>
/// Prepare the Dynamic Derived Book
/// </summary>
/// <param name="publisherCode">The publisher code of the wanted book.</param>
/// <param name="bookCode">The book code of the wanted book.</param>
/// <param name="pageReference">The wanted page.</param>
/// <param name="itemId">The wanted item.</param>
/// <param name="currentPublisherCode">The wanted publisher code.</param>
/// <param name="currentBookCode">The current book code.</param>
/// <param name="currentFilters">The currently applied filters.</param>
/// <returns>
/// The outcome of preparing the book, LinkOne expected values are:<br/>
/// 0 for success<br/>
/// 1 for failure<br/>
/// 2 for aborted.<br/>
/// </returns>
public int PrepareBook(
string publisherCode,
string bookCode,
string pageReference,
string itemId,
string currentPublisherCode,
string currentBookCode,
string currentFilters )
{
//
// TODO: Add PrepareBook Logic here
//
}
/// <summary>
/// Gets the book xml.
/// </summary>
public string BookXml
{
get
{
//
// TODO: add return string here.
//
}
}
58
LinkOne WinView Technical Reference
#endregion
}
}
59
LinkOne WinView Technical Reference
60
LinkOne WinView Technical Reference
61
LinkOne WinView Technical Reference
62
LinkOne WinView Technical Reference
Figure 19: The Default Splash Screen and its Customizable Components
63
LinkOne WinView Technical Reference
2 Version version versionlocation The text value that is placed inside the
configuration file will replace '{versiontext}'
in the image above. The 'Version' text in
the image above is static and cannot be
changed.
3 File Version fileversionlocation The content can't be customized.
4 Status statuslocation The content can't be customized.
5 Copyright copyright copyrightlocation The text value that is placed inside the
configuration file will replace
'{copyrighttext}' in the image above.
6 Copyright copyrightlegallocatio The content can't be customized.
Legal n
Company company Not shown on the About dialog or splash
screen, but used elsewhere in the product.
Product product Not shown on the About dialog or splash
screen, but used elsewhere in the product.
Icon iconfile Not shown on the About dialog or splash
screen, but used elsewhere in the product.
You can replace the product icon by
supplying:
an absolute path
e.g. C:\myicon.ico
e.g. \\server\share\myicon.ico
a path relative to the LinkOne.exe
folder
e.g. myicon.ico
e.g. ..\icons\myicon.ico
You can also use environment variables in
this path.
If the icon file can't be loaded then the icon
will be left blank.
64
LinkOne WinView Technical Reference
<mincom.linkone>
<winview>
....
<plugins>
<about>
<imagefile value="myimage.png" />
<version value="1.0" />
<copyright value="(C) 2006 My Company" />
<versionlocation value="140,10" />
<fileversionlocation value="140,35" />
<copyrightlocation value="140,50" />
<copyrightlegallocation value="999,999" />
</about>
</plugins>
...
</winview>
</mincom.linkone>
65
LinkOne WinView Technical Reference
The configuration file which contains settings for the individual user is found in the following file.
These are settings that an administrator has not locked down.
<add key="PrivateConfigurationFile"
value="%appdata%\OurCompany\Product\user.config" />
<add key="PublicConfigurationFile" value="%allusersprofile%\Application
Data\OurCompany\Product\user.config" />
The value string will also be resolved for any environment variables (e.g. %appdata%).
66
LinkOne WinView Technical Reference
The second folder relates to the individual user (private documents) and is the following default.
The value string will also be resolved for any environment variables (e.g. %appdata%).
67
LinkOne WinView Technical Reference
The -lc command line argument must be the first argument specified after LinkOne.exe.
If you require LinkOne WinView in a language that was not listed above, please contact us to discuss
the options.
68
LinkOne WinView Technical Reference
Renaming Files
When re-branding LinkOne WinView, it is common to rename files to names that correspond to those
of your organization. The table below lists the files that can be renamed when re-branding. The default
installation directory is C:\Program Files\Mincom\LinkOne WinView\5.11. All locations in the table
below are given with respect to the installation folder.
69
LinkOne WinView Technical Reference
Installation
Mincom LinkOne WinView 5.11 uses Microsoft Installer technology for its install process. The
installation program is a multi-lingual application which includes modify, repair, redundancy checking
and command line support.
70
LinkOne WinView Technical Reference
/a Option
Causes WinView511.exe to perform an administrative installation. An administrative installation
copies (and uncompresses) data files to a directory specified by the user, but it does not create
shortcuts, register COM servers, or create an uninstallation entry in the Add/Remove programs list.
/j Option
Causes WinView511.exe to perform an advertised installation. An advertised installation creates
shortcuts, registers COM servers, and registers file types, but does not install your product's files until
the user invokes one of these
/x Option
Causes WinView511.exe to uninstall a previously installed product.
/s Option
Suppresses the WinView511.exe initialization window only. The Installation user interface will still be
shown. To prevent any user interface from being shown, run the command line WinView511.exe /s
/v/qn.
/v Option
Passes options to the Msiexec.exe process that WinView511.exe creates to run the embedded MSI
install program.
The following table lists commonly used MsiExec.exe command line arguments that may be used in
the context of a Mincom LinkOne WinView installation. For a complete list of the MsiExec.exe
command Line arguments, please search the Microsoft web site.
71
LinkOne WinView Technical Reference
/l Writes logging information into a log file at the specified existing path. The path to the
log file location must already exist, but the file will be created if it does not exist. Flags
indicate which information to log. If no flags are specified, the default is 'iwearmo.'
/l Option
Users can use the /L option with the decimal language ID to specify the language used by a
multi-language installation program. For example, the command to specify German is
WinView511.exe /L1031
Language codes supported in Mincom LinkOne WinView include:
Language Language Code
Chinese (Simplified) 2052
Danish 1030
Dutch 1043
English 1033
72
LinkOne WinView Technical Reference
Finnish 1035
French (Canada) 3084
French (France) 1036
German 1031
Italian 1040
Japanese 1041
Korean 1042
Norwegian 1044
Portuguese (Brazil) 1046
Russian 1049
Spanish 1034
Swedish 1053
The following table is a list of common public install properties that might be used in the context of a
LinkOne installation. Note that property names are case sensitive
INSTALLDIR This is the target folder when LinkOne WinView will be installed by
default. If not specified, it defaults to the \Mincom\LinkOne
WinView\5.11\ folder within the Program Files folder structure. The user
can change this value in the install user interface. Alternatively, a new
value can be specified on the command line by providing a new folder for
the INSTALLDIR property. It is typically used for silent installs.
COMPANYNAME This is the name of the company to show in the install user interface. If
not specified on the command line, the install gets the value from the
operating system.
USERNAME This is the name of the user to show in the install user interface. If not
specified, the install gets the value of the currently logged on user from
the operating system.
ALLUSERS This property defines if the installation if for All Users or only the current
user. If set to 1 it is for all users. If set to blank, it is only for the current
user.
73
LinkOne WinView Technical Reference
L1SETTINGSFILE This is the path and name of the Installation Configuration file to use
during the install.
L1DISABLESHORTC Specifies that LinkOne menu shortcuts should not be created by the
UTS install. This is useful when LinkOne is integrated with another system,
which will provide the access to the application files.
ADDLOCAL The ADDLOCAL property identifies a list of all the features that are to be
installed locally on the machine. It can either contain the value ALL, or
a comma separated list of the feature names.
Feature names include:
WinView
TechnicalReference
Samples
COMControl
COMControlSample
DBMan
DBManSource
EllipseIntegration
Specifying a feature, selects that feature and its parents to be installed.
WinView511.exe /s /v”/qn”
The following command line silently installs WinView and the COM Control, using a custom target
folder.
A good way to test if the command line arguments will have the right effect is the specify them with out
the /s and /qn arguments. This will allow the user interface to display and allow you to confirm that
the correct properties have been set. For example if you specify the following command line
arguments, then you would expect to see John Smith as the user name, Global Limited as the
company name and the install will default to current user for the install type.
To generate a log file of the installation process, saving the log file to C:\Temp Files\WinView.log, use
the following command line:
Note that in the above example, the C:\Temp Files\ folder must already exist. If the WinView.log file
does not exist, it will be created, and if it does exist, it will be overwritten.
To specify additional configuration settings to apply during the installation, such as adding licenses, or
library locations, create an Installation Configuration file, and specify the name of the file in the
L1SETTINGSFILE property, as shown in the following example:
75
LinkOne WinView Technical Reference
<configeditor> Element
This is the root element of the installation configuration file.
The <configeditor> element indicates the root node of the installation configuration file. There can be
only one instance of this element in the configuration file.
Attributes: None
Possible parent elements: None (Root element)
Possible child elements: <changeset>
<changeset> Element
A <changeset> element defines a set of actions that must be applied to a specific target configuration
file, and the context upon which they should be applied. Change sets are useful for isolating one
group of changes from another, or for applying one set of changes only during an install process, while
a different set might only be applied during an uninstall process. Additionally, a change set could be
related to a specific installation feature. There can be many change sets in a configuration file, acting
on a combination of different target files or the same target file.
Attributes:
filename The filename of the target configuration file to apply the settings to. If not
specified, the change set is ignored. If the target file and folder do not exist, then
they will be created automatically.
Action Adding - indicates that the change set should only be applied when settings are
being added.
Removing - indicates that the change set should only be applied when settings are
being removed.
If not specified the default is adding.
condition True - this is an optional condition that can be used to indicate if the change set
should be applied. If not specified, the change set is applied. If specified, it must
be set to true or use a property that may have a value of true. Any other value
indicates false, and the changeset will not be applied. This is useful when you
only what the change set applied when a specific installation feature is installed or
uninstalled.
76
LinkOne WinView Technical Reference
<set> Element
The <set> element identifies the target configuration file node that must be modified. If the target
node does not exist, then it is automatically created, including any missing parent nodes. Other <set>
elements can be nested inside parent <set> elements to further identify the specific node to modify.
This allows changes in the child set element to be scoped to that element only.
Attributes:
xpath The XPath string which identifies the target configuration node to operate on. If the
target node is not found, then it is automatically created. If the element is a child of
a parent <set> element, then the xpath should not repeat the parents xpath
component. It should only include the additional component.
For example,
<set xpath=”mincom.linkone/winview”>
<set xpath=”forms/selectbook”>
<set xpath=”publishercode” />
</set>
<set xpath=”plugins/recentbooks” />
</set>
identifies 4 set references where:
the first set refers to xpath=”mincom.linkone”;
the second set refers to xpath=”mincom.linkone/forms/selectbook”
the third set refers to xpath=”mincom.linkone/forms/selectbook/publishercode”
the forth set refers to xpath=”Mincom.linkone/winview/plugins/recentbooks”
The xpath is a required attribute. If not specified, then the set is ignored.
The xpath attribute uses standard XML XPath syntax, and can also include attribute
and value references. Refer to the Microsoft XML specification for more information
Possible parent elements: <changeset>, <set>
Possible child elements: <set>, <attribute>, <value>, <xml>
<remove> Element
The <remove> element identifies the target configuration file nodes that must be removed if they exist.
Attributes:
xpath The XPath string which identifies the configuration node to remove. Only that node
and child nodes can be removed. Any parent nodes will not be removed, unless
explicitly specified in their own <remove> element.
The xpath is a required attribute. If not specified, then the remove is ignored.
The xpath uses standard XML XPath syntax, and can also include attribute and value
references. Refer to the Microsoft XML specification for more information
when Always - indicates that the target node if found should always be removed, even if it
includes child nodes.
Empty - indicates that the target node should only be removed if it does not include
any child nodes.
Possible parent element: <set>
Possible child element: None
77
LinkOne WinView Technical Reference
<attribute> Element
The <attribute> element is used to create, modify or delete an attribute of a target node in the context
of the current set element.
Attributes:
name The name of the attribute of the target element to set or remove. This is a required
attribute. If not specified, then the attribute element is ignored. The <attribute>
element requires either the value and/or remove attribute also be specified,
otherwise the element is ignored.
value The value of the attribute of the target element to set.
remove True - indicates that the attribute should be removed. Any other value indicates that
the attribute should remain. Can be used with installer properties to conditionally
remove a target attribute.
Possible parent element: <set>
Possible child element: None
<value> Element
The <value> element is used to create or modify the value associated with a target node in the context
of the current set element. If multiple value elements are specified in the same set context, then only
the last value is applied. The value of the <value> element is the value that will be applied as the
value of the target node.
Attributes: None
Possible parent element: <set>
Possible child element: None
<xml> Element
The <xml> element is used to identify a block of XML that should be copied to the target node
identified in the context of the current set. The XML to copy is enclosed in the <xml> elements, and
can include installer properties that are resolved at install time.
Attributes:
action Append - indicates that the enclosed xml should be appended to any existing xml in
the target file at the element specified in the current set context.
Prepend - indicates that the enclosed xml should be inserted before any existing xml
in the target file at the element specified in the current set context.
Replace - indicates that the enclosed xml should replace any existing xml in the
target file at the element specified in the current set context.
If not specified, the default action is to append the xml.
Possible parent element: <set>
Possible child element: None
78
LinkOne WinView Technical Reference
<changeset filename=”{L1DataFolder}{L1DataFileName}”>
It is useful to first run the install and capture the install log to get a list of all the properties that are
available during the install process. The available properties are typically listed towards the end of
the log files as either 'Property(C)' client properties or 'Property(S)' server properties. The installation
configuration file is applied during the install process, and in the context of server properties, therefore
only server properties should be referenced in the installation configuration files. Most client
properties are also available as server properties.
The following table lists a selection of installer properties that are useful with Installation Configuration
files:
L1CommonDataFolder
The path to the 'All Users' LinkOne configuration folder for the version of LinkOne being installed.
So for version 5.11 on Windows XP this would be:
'C:\Documents and Settings\All Users\Application Data\Mincom\LinkOne WinView\5.11\'
L1DataFolder
The path to the current users LinkOne configuration folder for the version of LinkOne being
installed. So for a user named John installing version 5.11 on Windows XP, this would be:
'C:\Documents and Settings\John\Application Data\Mincom\LinkOne WinView\5.11\'
L1DataFileName
This is the name of the configuration file that would be located in the above paths, typically
'user.config'
INSTALLDIR
INSTALLDIR.EF142472_A861_4D34_B822_3C7F5BFBBD28
The path to the installation folder of the version of LinkOne being installed. So for a default
installation of version 5.11 on Windows XP, this would be:
'C:\Program Files\Mincom\LinkOne WinView\5.11\'
BIN
BIN.EF142472_A861_4D34_B822_3C7F5BFBBD28
The path to the installation Bin folder of the version of LinkOne being installed. So for a default
installation of version 5.11 on Windows XP, this would be:
'C:\Program Files\Mincom\LinkOne WinView\5.11\Bin\'
79
LinkOne WinView Technical Reference
PLUGINS.EF142472_A861_4D34_B822_3C7F5BFBBD28
The path to the installation Plugins folder of the version of LinkOne being installed. So for a
default installation of version 5.11 on Windows XP, this would be:
'C:\Program Files\Mincom\LinkOne WinView\5.11\Bin\Plugins\'
L1AddWinViewMM.EF142472_A861_4D34_B822_3C7F5BFBBD28
This property equals 'True' when the LinkOne feature is selected for installation, or blank when
not selected for installation.
L1RemoveWinViewMM.EF142472_A861_4D34_B822_3C7F5BFBBD28
This property equals 'True' when the LinkOne feature is selected for uninstallation, or blank when
not selected for uninstallation.
L1AddCOMControlMM.DD86978A_1CD4_4699_94A3_8299EAF11E76
This property equals 'True' when the LinkOne COM Control feature is selected for installation, or
blank when not selected for installation.
L1RemoveCOMControlMM.DD86978A_1CD4_4699_94A3_8299EAF11E76
This property equals 'True' when the LinkOne COM control feature is selected for uninstallation,
or blank when not selected for uninstallation.
L1AddDBManMM.23683AA4_79FE_49CC_8999_4A28DEB353E1
This property equals 'True' when the LinkOne DBMan feature is selected for installation, or blank
when not selected for installation.
L1RemoveDBManMM.23683AA4_79FE_49CC_8999_4A28DEB353E1
This property equals 'True' when the LinkOne DBMan feature is selected for uninstallation, or
blank when not selected for uninstallation.
L1AddEllipseMM.84BE8020_1EF6_40BC_AA89_5A443A2C7296
This property equals 'True' when the LinkOne Ellipse Integration feature is selected for
installation, or blank when not selected for installation.
L1RemoveEllipseMM.84BE8020_1EF6_40BC_AA89_5A443A2C7296
This property equals 'True' when the LinkOne Ellipse Integration feature is selected for
uninstallation, or blank when not selected for uninstallation.
<configeditor>
<changeset filename="{L1DataFolder}{L1DataFileName}" action="adding">
<set xpath="mincom.linkone/winview/services/bookservice/licenses">
<xml action="replace">
<license id="7317cc3d53604541b37871d15f8efb2d" licensee="Dummy License"
type="ViewerLicense" version="5." issued="20070321"
signature="amaHqboIdROtvQY3vpwoxJ0Bg/VWjufmkufbekynreDmLZHVZI85sOFVsrVDX4v6LkK37
9FC3yOWe3gWhdSK73igsC0SO22wI2Ql0XmWJa1Ik+NVLSH63m6XrQOKBhpa73BAdO5GvO0qAjfSkP3qb
h2HkBtJnq8yQ8+C5XGptBM35M=" restriction="Open" />
</xml>
</set>
</changeset>
</configeditor>
The following example removes a MyPlugin entry in the plugin configuration and updates it with new
plugin details.
80
LinkOne WinView Technical Reference
<configeditor>
<changeset filename="{L1DataFolder}{L1DataFileName}" action="adding">
<!-- Remove any previous instance of MyPlugin control -->
<remove
xpath="mincom.linkone/winview/shell/plugins/plugin[@type='MyCompany.MyPlugin.MyC
ontrol, MyPlugins']" when="always" />
<!-- Update plugins configuration -->
<set xpath="mincom.linkone/winview/shell/plugins">
<!-- Enable the tracer control -->
<set xpath="plugin[@type='Mincom.LinkOne.WinView.Controls.Tracer,
Mincom.LinkOne.WinView.Plugins']">
<attribute name="disable" remove="true" />
</set>
<!-- Add MyPlugin control -->
<set xpath="plugin[@type='MyCompany.MyPlugin.MyControl, MyPlugins']">
<attribute name="disable" value="False" />
</set>
</set>
</changeset>
</configeditor>
81
LinkOne WinView Technical Reference
Network Installation
Mincom LinkOne WinView 5.11 can be installed to a network location. When following the install
wizard, choose a custom configuration and change the target directory to the desired network location.
82
LinkOne WinView Technical Reference
Configuration
83
LinkOne WinView Technical Reference
Optimization
Mincom LinkOne WinView 5.11 memory usage can be optimized by configuring the maximum allowed
cache memory allocation. To optimize the cache memory usage, add the following to the configuration
element in the linkone.exe.config file located in the bin folder of the Mincom LinkOne WinView 5.11
installation:
<system.web>
<caching>
<cache percentagePhysicalMemoryUsedLimit="20"/>
</caching>
</system.web>
The percentagePhysicalMemoryUsedLimit attribute may be configured to best suite the end users'
requirements. The example above allows a 20% maximum allowable usage of the users' physical
memory for the Mincom LinkOne WinView 5.11 cache.
Note: The percentagePhysicalMemoryUsedLimit setting does not limit the total amount of memory used
for the whole linkone application, merely the amount used for caching frequently accessed data.
Note: When Mincom LinkOne WinView 5.11 is run from a network location and memory is optimized
using the above configuration setting, the user must ensure the the Microsoft .Net Code Access
Security settings for the network location allow the full execution of Managed applications. For more
information regarding the management of Microsoft .Net Code Access Security settings please see
http://msdn.microsoft.com/en-us/library/930b76w0(VS.80).aspx
84
LinkOne WinView Technical Reference
<mincom.linkone>
<winview>
<plugins>
<configuration>
<pages>
<page value="~Mincom.LinkOne.WinView.Configure.ConfigurePlugins" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureLicenses" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureCommonLicenses"
/>
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureLayouts" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureNotes" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureNoteDefaults"
/>
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureLayoutPaths" />
<page
value="~Mincom.LinkOne.WinView.Configure.ConfigureInternetConnection" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureContent" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureNotesPaths" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureProvider" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigurePrint" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureSearchSet" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureSelectionList"
/>
<page
value="~Mincom.LinkOne.WinView.Configure.ConfigureSelectionListPaths" />
<page
value="~Mincom.LinkOne.WinView.Configure.ConfigureConfigurationManager" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureParts" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigurePictures" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureStartup" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureRecentBooks" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureCaption" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureHistory" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigurePosition" />
<page value="~Mincom.LinkOne.WinView.Configure.ConfigureShell" />
</pages>
</configuration>
</plugins>
<winview>
<mincom.linkone>
85
LinkOne WinView Technical Reference
86
LinkOne WinView Technical Reference
Command [APP.ACTIVATE]
Arguments None
Description Sets focus to the LinkOne WinView window.
Command [APP.EXIT]
Arguments None
Description Causes LinkOne WinView to immediately terminate and exit. If there are
unsaved selections you will be asked if you wish to save these.
Command [APP.MAXIMIZE]
Arguments None
Description Maximizes the LinkOne WinView window.
Command [APP.MINIMIZE]
Arguments None
Description Minimizes the LinkOne WinView window to the taskbar.
Command [APP.RESTORE]
Arguments None
Description Restores the LinkOne WinView window from a minimized status.
87
LinkOne WinView Technical Reference
Command [APP.WINDOWPOS(left,top,width,height,z-order)]
Arguments left
Determines the location of the left edge of the LinkOne WinView
window.
top
Determines the location of the top edge of the LinkOne WinView
window.
width
Determines the width in pixels of the LinkOne WinView window.
height
Determines the height in pixels of the LinkOne WinView window.
z-order
Determines the z-order of the window.
Description Determines the position and size of the LinkOne Viewer on the Display
Monitor.
Example [APP.WINDOWPOS(10,10,50,100,1)]
This will place the LinkOne WinView window at the location 10,10 on the
Windows Desktop with a width of 50 pixels and height of 100 pixels. It will
be placed in the foreground of the desktop.
88
LinkOne WinView Technical Reference
Command [BACKUP]
Arguments None
Description Executes the navigate back command button.
Command [CLEAR.SEL]
Arguments None
Description Clears all entries in the selection list.
Command [COPY.SEL]
Arguments None
Description Copies all entries in the selection list to the Windows Clipboard in
tabulated format.
Command [CUT.SEL]
Arguments None
Description Copies all entries in the selection list to the Windows Clipboard in
tabulated format and deletes them from the selection list.
89
LinkOne WinView Technical Reference
Command [EDIT.SEL]
Arguments None
Description Selects the first editable field in the selection list and allows it to be
edited.
90
LinkOne WinView Technical Reference
Command [FLOAT.NAV(float)]
Arguments None
Description This command is no longer supported.
91
LinkOne WinView Technical Reference
Command [HIGHLIGHT.ITEM(item)]
Arguments item
The item id of the parts list item to be highlighted.
Description Highlights the specified item in the parts list.
Example [HIGHLIGHT.ITEM(5)]
This will highlight the item number 5 in the parts list if it exists.
92
LinkOne WinView Technical Reference
Command [MORE]
Arguments None
Description Runs the 'More' command button function.
Command [NEXTPAGE]
Arguments None
Description Runs the 'Next Page' command button function.
Command [NEW.SEL]
Arguments None
Description Clears the existing selection list entries and creates a new blank selection
list.
Command [OPEN.SEL(filename)]
Arguments filename
The path and filename to the .sel file to open
Description Opens the selection list file and loads its contents into the selection list.
Example [OPEN.SEL(c:\temp\newsel.sel)]
This will open the selection list from the c:\temp folder\newsel.sel file.
Command [PREVPAGE]
Arguments None
Description Runs the 'Previous Page' command button function.
93
LinkOne WinView Technical Reference
94
LinkOne WinView Technical Reference
Command [SAVE.PICTURE]
Arguments None
Description Opens a Save Picture dialog allowing the user to save the current picture
to a file.
Command [SAVE.SEL]
Arguments None
Description Saves the selection list to the current selection list file.
Command [SAVE.SEL.AS(filename)]
Arguments filename
The path and filename of the file to save the selection list contents to.
Description Saves the selection list to the selection list file supplied and sets this file
to the current selection list file for further save commands.
Example [SAVE.SEL.AS(c:\temp\newsel.sel)]
This will save the current selection list to newsel.sel in the c:\temp folder.
Any further changes that are saved will be saved to this file.
95
LinkOne WinView Technical Reference
Command [SEARCH(set, search, multi, do, goto, key1, exact1, match1, key2, exact2,
match2, multi-pub, multi-books, save-file, save-flags, category-code)]
96
LinkOne WinView Technical Reference
Arguments set
The name of the search set to be used. Use DEFAULT_SEARCHES,
or blank for the default search set.
search
The name of the search within the search set to be used.
multi
0 = perform a single book search (default). 1 = performs a multi-book
search.
do
0 = do not execute the search (default). 1 = execute the search
immediately.
goto
0 = only show the search results (default). 1 = go to the first found
search result.
key1
The value for key1 of the search.
exact1
0 = key1 may be a partial match (default). 1 = key1 must be an exact
match.
match1
0 = key1 may match upper or lower case (default). 1 = key1 must
match on case.
key2
The value for key2 of the search. This is only valid for a multi-key
search.
exact2
0 = key2 may be a partial match (default). 1 = key2 must be an exact
match.
match2
0 = key2 may match upper or lower case (default). 1 = key2 must
match on case.
multi-pub
Deprecated and ignored - Must be left blank.
multi-books
Deprecated and ignored - Must be left blank.
save-file
Valid only when the search has been executed, i.e. “do=1” (optional).
Specifies the name of the file to which the search results will be
saved.
save-flags
Specifies the actions to take when saving the search results
(optional). May be one or more of the following strings, combined with
a “+”. ALL, LOCN, APPEND, CLOSE e.g. ALL+CLOSE
category-code
The category used to restrict multi-book searches to a set of books in
a category (optional).
Multi-book search must also be specified, i.e. “multi=1”.
The category is listed as an entry in the book.def file:
CAT,PUB,category
or is listed as an entry in the book.lst file:
book,bookdescription,category
The books chosen for searching will belong to the specified category
and its sub-categories, e.g. specifying CategoryA will choose all
books in CategoryA and CategoryA\CategoryAA and 97
CategoryA\CategoryAB, etc.
If the category does not exist, the search will default to a normal
multi-book search and choose all books of the current publisher.
LinkOne WinView Technical Reference
Description Displays the LinkOne Search dialog which is populated with the current
following settings as supplied in the arguments.
Command [SELECT]
Arguments None
Description Runs the 'Select' command button function and adds the currently
selected entry in the parts list to the selection list if this action can be
performed.
Command [SELECT.FITTED]
Arguments None
Description Runs the 'Select Qty Fitted' command button and adds the currently
selected entry in the parts list to the selection list using the 'Qty Fitted'
function.
Command [SELECTIONS.DOCK]
Arguments None
Description Docks the selection list control to the main LinkOne WinView shell.
Command [SELECTIONS.HIDE]
Arguments None
Description Hides the selection list control. To open it again, the user can go to the
View menu and check the Selections option.
Command [SELECTIONS.REFRESH]
Arguments None
98
LinkOne WinView Technical Reference
Command [SELECTIONS.SHOW]
Arguments None
Description Shows the selection list control if the control is previously hidden.
Command [TOOLBAR.DOCK(toolbar-name)]
Arguments toolbar-name
The name of the toolbar. This is the name of the toolbar as seen in
the customize tools dialog.
Description Docks the toolbar to the top edge of the window.
Example [TOOLBAR.DOCK(navigation)]
This will dock the Navigation toolbar to the top of the LinkOne WinView
application window.
Command [TOOLBAR.HIDE(toolbar-name)]
Arguments toolbar-name
The name of the toolbar. This is the name of the toolbar as seen in
the customize tools dialog.
Description Hides the toolbar. The toolbar can be shown again by right clicking on
another toolbar and selecting the hidden toolbar from the menu list.
Example [TOOLBAR.HIDE(navigation)]
This will hide the Navigation toolbar.
99
LinkOne WinView Technical Reference
Command [TOOLBAR.SHOW(toolbar-name)]
Arguments toolbar-name
The name of the toolbar. This is the name of the toolbar as seen in
the customize tools dialog.
Description Shows the toolbar if the toolbar is hidden. previously hidden.
Example [TOOLBAR.SHOW(navigation, 10, 10, 50, 10)]
This will show the Navigation toolbar at its default docked location if it has
been hidden.
Command [TOP]
Arguments None
Description Runs the 'First Book View' command button function which opens the first
page in the table of contents control.
Command [UP]
Arguments None
Description Runs the 'Parent Page' command button function which opens the parent
page of the currently selected page in the table of contents control.
Command [VIEW.LIST-ONLY]
Arguments None
Description Hides the picture control ensuring that only the parts list control is visible.
Command [VIEW.PICTURE-AND-LIST]
Arguments None
Description Ensures that both the parts list and pictures controls are visible.
Command [VIEW.PICTURE-ONLY]
Arguments None
Description Hides the parts list control ensuring that only the pictures control is
visible.
Command [ZOOM.BY(zoom-factor)]
Arguments zoom-factor
The zoom factor to zoom the picture by
Description Zooms the current picture by the specified zoom factor (i.e. 1 = 100%, 2 =
200%, 0.25 = 25%).
Example [ZOOM.BY(2)]
This will zoom the current picture to 200%
100
LinkOne WinView Technical Reference
Command [ZOOM.FIT]
Arguments None
Description Zooms the current picture to fit within the current picture control
dimensions.
Command [ZOOM.FULL]
Arguments None
Description Zooms the current picture to its default scale as specified in the book.
101