ImageGear .NET
Server-Side API

Using the Server-Side API for Viewing

Three server-side web controls support viewing: PageView Class web control, ThumbnailView Class web control, and the ImGearThumbnailList web control. The PageView and the ThumbnailView web controls primarily encapsulate the current state of a client-side image viewer or thumbnail. The ImGearThumbnailList web control maintains only the selected state of the thumbnails when the ImGearThumbnailList control property DataBindingType is set to ImageGear.Web.UI.ImGearDataBindingType.Page.

During an initial page lifecycle (i.e., not a postback), set the properties of the PageView Class, ThumbnailView Class and ImGearThumbnailList web controls to the desired state, and they will create instances of client-side control with matching properties.

During a postback, the PageView Class properties will acquire the current state of the associated client-side properties listed below. (All other PageView Class properties revert to default values.)

The ThumbnailView Class properties will acquire the current state of the associated client-side properties listed below. (All other ThumbnailView Class properties revert to default values.)

Server-Side Annotation Support

The ASP.NET services support six of the ImageGear annotation types:

The annotations are read from either a NotateExpress or ImageGear XML file but can only be saved to the ImageGear XML format. Refer to ImageGear.Web.UI Namespace Client API Library : ImageGear.Web.UI Namespace.

Enabling Annotation Support with the Server-Side API

The server-side API allows the programmer to specify the level of annotation support that should be enabled by setting the PageView.ArtEnableMode and the ThumbnailView.ArtEnableMode properties. The ImGearThumbnailList control uses services for annotations. The service option can be selected using the property ImGearThumbnailList.ArtDataServiceOption of the type ImGearArtDataServices enumeration.

When annotations are enabled via the ArtEnableMode properties and a document page is loaded, ImageGear ASP.NET will check for a corresponding artwork document identifier source (containing the annotations) such as a same document name file ending in an ".xml" extension. The default action for every post back is to save the current art work annotations and then load the requested document page and its associated artwork for the page. 

If the user's application needs to read and save the annotation artwork to a different document identifier or wishes to draw and save art without all the overhead of a post back, then the ImageGear.Web.UI.ArtConnection Class public API may be used to read and write XML source files.

Debugging the Server-Side

ImageGear ASP.NET components make use of the ImageGear RESTful services to respond to viewing and annotations requests made by the client web controls. These services and other server side modules include extensive logging to help you track down any problems that may occur. ImageGear uses the System.Diagnostics.TraceListener facility built into ASP.NET and the .NET framework. You can control the amount of logging ImageGear does by editing web.config. See Error Logging Configuration Settings

 

 


©2016. Accusoft Corporation. All Rights Reserved.

Send Feedback