ActiveX Image Edit and Twain Control - csXImage

ActiveX / OCX image control for the display, edit and manipulation of images. Add image processing functions to compiled or web based applications. Acquire images from Twain scanner devices.

This control can be used in Windows programming environments that support ActiveX, such as Visual Basic or Delphi as well as .NET and VBA driven applications such as Access. It can read and write a variety of file formats allowing for conversions to be made between them. Functions allow images to be manipulated, enhanced and edited. Images can be imported from TWAIN compliant scanners and webcams. The online manual provides a full listing of available properties and methods.

There are functions to save the image to file or copy the image to the Windows clipboard. The image can be exported in a binary format (a variant array), which can be used to place the image into a database field or stream the image to a web browser if used in a server-side application. An edited image can be posted to a web server as an HTTP upload, or by FTP.

The image editing functions include simple resize and scale methods for reducing image size or creating thumbnails. Images can be cropped, flipped and rotated. Colour depth can be adjusted, as can brightness, sharpness, contrast and HLS components (hue, lightness and saturation). Lines, shapes and text can be drawn. Images can be merged using optional transparency to create watermarks. Alpha transparency in PNG images is supported.

The installation is supplied as two OCX files, one is 32 bit and the other is 64 bit. The OCX file used will depend on the application calling the control. Some development environments, such as VB6, are 32 bit and so only the 32 bit control will be used. Visual Studio for .NET and Delphi can produce 32 bit or 64 bit applications. Internet Explorer is currently supplied as 32 bit. In scanning applications it may be preferable to use 32 bit for compatibility with existing scanner drivers.

Getting Started

Download the trial version of csXImage and run the installer to unpack the OCX file and register it on your computer. This will also unpack sample projects in Visual Basic 6, VB.NET, C# and a simple web page using the control in Javascript. After running the installer these sample projects will appear in your Start Menu, as well as the PDF version of the csXImage Instructions. For uninstall instructions - Click Here.

Note that the trial version writes a line of text on each image produced. This is the main limitation and the trial contains most of the other functions and properties of the full version. See the instructions for full details.

We have a number of examples, tips and troubleshooting for VB6, VB.NET, C# and client side Javascript.

Web Browser Applications

csXImage can be used in a browser as a client side control using Javascript. The Twain scanning and image uploading features are very useful in client side web based applications. We provide a digitally signed CAB file with the full version of csXImage. We have some additional explanation for use with ASP.NET, especially to describe the differences between client side and server side scripting.

Please note that the only browser which supports the use of ActiveX controls is Microsoft Internet Explorer, running on Windows.

Downloadable examples using the csXImage ActiveX control:

csXImage has similar functionality to our popular ASP component, csImageFile. csXImage is licensed by the design seat with no restrictions on the OCX file. csImageFile is licensed by the number of installations of the DLL. There are also differences in syntax and names of properties and methods. Both components can be used in server side applications, and both components can be used in a visual environment although with csImageFile this is more difficult because it has no visual design interface. Follow this link for a full comparison of the two components.

Click Here for more on csImageFile.

We can recommend WebTwainX as an ActiveX control with a built in user interface allowing images to be scanned and uploaded from a web application. It is published by Ciansoft.