
Research
NPM targeted by malware campaign mimicking familiar library names
Socket uncovered npm malware campaign mimicking popular Node.js libraries and packages from other ecosystems; packages steal data and execute remote code.
ImageComponents.MVC.Imaging
Advanced tools
Supported Platforms: • NETFramework Image Components for ASP.Net MVC is an imaging SDK that allows the view, edit, capture, creation and data manipulation. Some of the Image Components functions are: opening file or directory and saving most common images file types (*.jpg;*.jpeg;*.tif;*.tiff;*.bmp;*.gif;*.png;*.cut;*.dds;*.g3;*.hdr;*.ico;*.iff;*.lbm;*.jng;*.koa;*.mng;*.pbm;*.pcd;*.pcx;*.pgm;*.ppm;*.psd;*.ras;*.sgi;*.tga;*.targa;*.wbmp;*.xbm;*.xpm;*.wmf;*.pdf;*.xps) and convert between them. Thumbnail view of the image multi or single page. Navigation between the pages, by thumbnail click or by toolbar. Image fit to the screen (original, best and width). Rotate left, right, flip and mirror. Zoom + and Zoom -. Inserting, appending, deleting or moving pages. Cropping by selection or auto cropping, resizing, undo, redo, copy and paste. Many filters like invert, grayscale, etc. Image enhance (color, brightness, smooth, sharpen, etc.). Many edge detectors. Glass tool to zoom a particular part of the image. Thumbnail viewing, navigation and position management. Twain and WIA support using ADF or flat bed, multi page or single page. Save and Scanner options by image type or compression (None, JPG, CCITT3, CCITT4, LZW, PDF...) . Access to the most common Capabilities and ICapabilities. Document, page, zone OCR and text search, supporting some common languages. PDF reading and export, multi, single or selected page. PDF text search and extraction. Full customized image annotations including, Note, Stamps, Highlight, Hide, Ellipse, Line, Arrow and Image. Barcode encoder and decoder. Supports Code11, Code 39, Interleaved 2 of 5, Codabar, Code 93, EAN8, EAN13, UPCA, Code128, PDF417, QRCODE. Automatic barcode detection and scan direction.
This NuGet package must be compiled and configured for x86 platforms. Open the configuration manager dialog and set your project platform to x86. After that, the application can run on both x86 and x64 platforms. You can also download the x64 assemblies version from our site: http://www.imagecomponents.net/Downloads/Index/4 Run the example by pressing F5. Navigate to the controller /iccsharpexample or the /icvbexample.
###################################### - Using Image Components Web ImgEdit Component - ######################################
Open visual studio and create a new ASP.NET MVC 4 project.
Select the 'Basic' template and the 'Razor' view engine.
Add a reference to the ImageComponents.Web.Mvc.ImgEdit.dll and to the ImageComponents.Web.Utilities.dll assemblies that can be found on the SDK installation folder\Examples\Assemblies\Web\Mvc\
Add a new Controller named HomeController and select the Empty MVC controller template.
On the controller code view right click the Index method, press the 'Add View' menu item and uncheck the 'Use a layout or master page'.
Include the ImgEdit-vsdoc.js file in the 'Scripts' project folder. This file can be found on the SDK installation folder\Examples\Web\Version4\CSharp\Mvc\IC.Web.Mvc.ImageEditor\Scripts\
Add a new JavaScript file to the 'Scripts' folder and name it index.cshtml.js.
Open the Index.cshtml view in order to display the HTML source code.
Add the following @using or @Imports expression at the top of the Index view: @using ImageComponents.Web.Imaging.Mvc;
Add the following script elements to the head of the page:
Insert in the beginning of the body element the configuration of the ImgEdit control: @Html.ImgEditManager().ScriptResource().Include(); @Html.ImgEditManager().SetWidth("100%"); @Html.ImgEditManager().SetHeight("100%");
Add the ImgEdit control to the div element: @Html.ImgEditManager().Render("imgEdit1")
Add an Input (Button) element as:
Append the following JavaScript element at the bottom of the Index view: @System.Web.Optimization.Scripts.Render("~/bundles/jquery")
The full Index view code may look like this: @using ImageComponents.Web.Imaging.Mvc; Index @Html.ImgEditManager().ScriptResource().Include() @Html.ImgEditManager().SetWidth("400px") @Html.ImgEditManager().SetHeight("500px")
@Html.ImgEditManager().Render("imgEdit1") | |
Open and add the following JavaScript code to the index.cshtml.js file: /// var _webServiceURL = "http://localhost/IC.Web.Imaging/ImageManagerService.svc"; var _imgEdit = null; //Comment this line on release. This is just for intellisense purposes. _imgEdit = new ImgEdit(); function pageLoad() { //Get the ImgEdit control. _imgEdit.set_WebServiceURL(_webServiceURL); _imgEdit.addEventListener("ErrorOccurred", onErrorOccurred); }
function openImage() {
_imgEdit.DisplayUrl('http://www.imagecomponents.net/Documentation/Doc.tif');
_imgEdit.FitTo(ImgEdit.ICImageFit.BESTFIT, true);
}
function onErrorOccurred(s, e) {
alert("One error occurred in the control '" + e.ControlName + "'.\r\nThe error detail in the method '" + e.MethodName +
"' is as follows:\r\n\r\n" + e.ErrorMessage + "\r\n\r\nSorry for this inconvenient. ");
}
Run the application by pressing the F5 key or by clicking the play button on Visual Studio.
Click the 'Open' button and it should display an example tif image file.
###################################### - Using Image Components Web ImgThumbnails Component - ######################################
Open the previous ASP.NET MVC 4 project.
Add a reference to the ImageComponents.Web.Mvc.ImgThumbnails.dll assembly that can be found on the SDK installation folder\Examples\Assemblies\Web\Mvc\
Include the ImgThumbnails-vsdoc.js file in the 'Scripts' project folder. This file can be found on the SDK installation folder\Examples\Web\Version4\CSharp\Mvc\IC.Web.Mvc.ImageEditor\Scripts\
Open the Index.cshtml view in order to display the HTML source code.
Add the following script elements to the head of the page:
Insert in the beginning of the body element the configuration of the ImgThumbnails control: @Html.ImgThumbnailsManager().ScriptResource().Include() @Html.ImgThumbnailsManager().SetWidth("150px") @Html.ImgThumbnailsManager().SetHeight("500px")
The full HTML code may look like this: @using ImageComponents.Web.Imaging.Mvc; Index @Html.ImgEditManager().ScriptResource().Include() @Html.ImgThumbnailsManager().ScriptResource().Include() @Html.ImgEditManager().SetWidth("400px") @Html.ImgEditManager().SetHeight("500px") @Html.ImgThumbnailsManager().SetWidth("150px") @Html.ImgThumbnailsManager().SetHeight("500px")
@Html.ImgEditManager().Render("imgEdit1") | @Html.ImgThumbnailsManager().Render("imgThumbnails1") |
Open and add the following JavaScript code to the index.cshtml.js file: /// /// var _webServiceURL = "http://localhost/IC.Web.Imaging/ImageManagerService.svc"; var _imgEdit = null; var _imgThumbnails = null; //Comment the following lines on release. This is just for intellisense purposes. _imgEdit = new ImgEdit(); _imgThumbnails = new ImgThumbnails();
var _isImgScanDownloading = false;
function pageLoad() {
//Get the ImgEdit control.
_imgEdit.set_WebServiceURL(_webServiceURL);
_imgEdit.addEventListener("ErrorOccurred", onErrorOccurred);
}
function openImage() {
_imgEdit.DisplayUrl('http://www.imagecomponents.net/Documentation/Doc.tif');
_imgEdit.FitTo(ImgEdit.ICImageFit.BESTFIT, true);
}
function onErrorOccurred(s, e) {
alert("One error occurred in the control '" + e.ControlName + "'.\r\nThe error detail in the method '" + e.MethodName +
"' is as follows:\r\n\r\n" + e.ErrorMessage + "\r\n\r\nSorry for this inconvenient. ");
}
Run the application by pressing the F5 key or by clicking the play button on Visual Studio.
Click the 'Open' button and it should display an example tif image file and it's pages thumbnails.
###################################### - Using Image Components Web ImgScan Component - ######################################
Open the previous ASP.NET MVC 4 project.
Add a reference to the ImageComponents.Web.Mvc.ImgScan.dll assembly that can be found on the SDK installation folder\Examples\Assemblies\Web\Mvc\
Include the ImgScan-vsdoc.js file in the 'Scripts' project folder. This file can be found on the SDK installation folder\Examples\Web\Version4\CSharp\Forms\IC.Web.ImageEditor\js\
Open the Index.cshtml view in order to display the HTML source code.
Add an Input (Button) element as:
Add the following script elements to the head of the page:
Insert in the beginning of the body element the configuration of the ImgScan control: @Html.ImgScanManager().ScriptResource().Include()
The full HTML code may look like this: @using ImageComponents.Web.Imaging.Mvc; Index @Html.ImgEditManager().ScriptResource().Include() @Html.ImgThumbnailsManager().ScriptResource().Include() @Html.ImgScanManager().ScriptResource().Include() @Html.ImgEditManager().SetWidth("400px") @Html.ImgEditManager().SetHeight("500px") @Html.ImgThumbnailsManager().SetWidth("150px") @Html.ImgThumbnailsManager().SetHeight("500px")
@Html.ImgEditManager().Render("imgEdit1") | @Html.ImgThumbnailsManager().Render("imgThumbnails1") |
Open and add the following JavaScript code to the index.cshtml.js file: /// /// /// var _webServiceURL = "http://localhost/IC.Web.Imaging/ImageManagerService.svc"; var _imgEdit = null; var _imgThumbnails = null; var _imgScan = null; //Comment the following lines on release. This is just for intellisense purposes. _imgEdit = new ImgEdit(); _imgThumbnails = new ImgThumbnails(); _imgScan = new ImgScan();
var _isImgScanDownloading = false;
function pageLoad() {
//Get the ImgEdit control.
_imgEdit.set_WebServiceURL(_webServiceURL);
_imgEdit.addEventListener("ErrorOccurred", onErrorOccurred);
_imgScan.addEventListener("ErrorOccurred", onErrorOccurred);
_imgScan.addEventListener("SocketStatusChanged", onSocketStatusChanged);
_imgScan.addEventListener("ScanFinished", onScanFinished);
}
function openImage() {
_imgEdit.DisplayUrl('http://www.imagecomponents.net/Documentation/Doc.tif');
_imgEdit.FitTo(ImgEdit.ICImageFit.BESTFIT, true);
}
function scanImage() {
//Close existing image if open.
_imgEdit.Close();
if (_imgScan.ConnectionStatus !== ImgScan.ICWSocketStatus.CONNECTED) {
_imgScan.OpenConnection(function () {
_imgScan.ActiveSourceName = "TWAIN2 FreeImage Software Scanner";
_imgScan.DeviceDriverType = ImgScan.ICDeviceDriverType.TWAIN;
_imgScan.DeviceSettings = new ImgScan.ICDeviceSettings();
//This is important if you are scanning a multi-page document. You can also set to PDF.
_imgScan.DeviceSettings.OutputFormat = ImgScan.ICImageOutputFormat.TIFF;
_imgScan.SetTwainSettings = new ImgScan.TwainSettings();
_imgScan.SetTwainSettings.Values.TwainICapabilities.ImageXferMech = ImgScan.ICAP_XFERMECH.NATIVE;
_imgScan.Acquire();
});
}
else {
_imgScan.ActiveSourceName = "TWAIN2 FreeImage Software Scanner";
_imgScan.DeviceDriverType = ImgScan.ICDeviceDriverType.TWAIN;
_imgScan.DeviceSettings = new ImgScan.ICDeviceSettings();
//This is important if you are scanning a multi-page document. You can also set to PDF.
_imgScan.DeviceSettings.OutputFormat = ImgScan.ICImageOutputFormat.TIFF;
_imgScan.SetTwainSettings = new ImgScan.TwainSettings();
_imgScan.SetTwainSettings.Values.TwainICapabilities.ImageXferMech = ImgScan.ICAP_XFERMECH.NATIVE;
_imgScan.Acquire();
}
}
//This events are hired up on page load method.
//On web socket connection.
function onSocketStatusChanged(s, e) {
switch (e) {
case ImgScan.ICWSocketStatus.CONNECTING:
break;
case ImgScan.ICWSocketStatus.CONNECTED:
break;
case ImgScan.ICWSocketStatus.CONNECTIONERROR:
if (_isImgScanDownloading == false) {
if (confirm('Could not connect to the ImgScan twain bridge plugin.\r\nDo you want to download the installation package and try again?')) {
_isImgScanDownloading = true;
_imgScan.DownloadScanService("http://localhost/IC.Web.Imaging/ImgScan/ICScanService.zip");
} else {
_imgScan.CloseConnection();
}
}
break;
case ImgScan.ICWSocketStatus.RECONNECTING:
break;
}
}
//On scan finished event.
function onScanFinished(s, e) {
//Upload the image to your server.
var _base64Image = e.Stream;
}
function onErrorOccurred(s, e) {
alert("One error occurred in the control '" + e.ControlName + "'.\r\nThe error detail in the method '" + e.MethodName +
"' is as follows:\r\n\r\n" + e.ErrorMessage + "\r\n\r\nSorry for this inconvenient. ");
}
Run the application by pressing the F5 key or by clicking the play button on Visual Studio.
Click the 'Scan' button and it should initiate and display the scanner driver dialog.
###################################### - Using Image Components Web ImgAnnotations Component - ######################################
Open the previous ASP.NET MVC 4 project.
Add a reference to the ImageComponents.Web.Mvc.ImgAnnotations.dll assembly that can be found on the SDK installation folder\Examples\Assemblies\Web\Mvc\
Include the ImgAnnotations-vsdoc.js file in the 'Scripts' project folder. This file can be found on the SDK installation folder\Examples\Web\Version4\CSharp\Forms\IC.Web.ImageEditor\js\
Open the Index.cshtml view in order to display the HTML source code.
Add an Input (Button) element as:
Add the following script elements to the head of the page:
Insert in the beginning of the body element the configuration of the ImgAnnotations control: @Html.ImgAnnotationsManager().ScriptResource().Include()
The full HTML code may look like this: @using ImageComponents.Web.Imaging.Mvc; Index @Html.ImgEditManager().ScriptResource().Include() @Html.ImgThumbnailsManager().ScriptResource().Include() @Html.ImgScanManager().ScriptResource().Include() @Html.ImgAnnotationsManager().ScriptResource().Include() @Html.ImgEditManager().SetWidth("400px") @Html.ImgEditManager().SetHeight("500px") @Html.ImgThumbnailsManager().SetWidth("150px") @Html.ImgThumbnailsManager().SetHeight("500px")
@Html.ImgEditManager().Render("imgEdit1") | @Html.ImgThumbnailsManager().Render("imgThumbnails1") |
Open and add the following JavaScript code to the index.cshtml.js file: /// /// /// /// var _webServiceURL = "http://localhost/IC.Web.Imaging/ImageManagerService.svc"; var _imgEdit = null; var _imgThumbnails = null; var _imgScan = null; var _imgAnnotations = null; //Comment the following lines on release. This is just for intellisense purposes. _imgEdit = new ImgEdit(); _imgThumbnails = new ImgThumbnails(); _imgScan = new ImgScan(); _imgAnnotations = new ImgAnnotations();
var _isImgScanDownloading = false;
function pageLoad() {
//Get the ImgEdit control.
_imgEdit.set_WebServiceURL(_webServiceURL);
_imgEdit.addEventListener("ErrorOccurred", onErrorOccurred);
_imgScan.addEventListener("ErrorOccurred", onErrorOccurred);
_imgScan.addEventListener("SocketStatusChanged", onSocketStatusChanged);
_imgScan.addEventListener("ScanFinished", onScanFinished);
}
function openImage() {
_imgEdit.DisplayUrl('http://www.imagecomponents.net/Documentation/Doc.tif');
_imgEdit.FitTo(ImgEdit.ICImageFit.BESTFIT, true);
}
function scanImage() {
//Close existing image if open.
_imgEdit.Close();
if (_imgScan.ConnectionStatus !== ImgScan.ICWSocketStatus.CONNECTED) {
_imgScan.OpenConnection(function () {
_imgScan.ActiveSourceName = "TWAIN2 FreeImage Software Scanner";
_imgScan.DeviceDriverType = ImgScan.ICDeviceDriverType.TWAIN;
_imgScan.DeviceSettings = new ImgScan.ICDeviceSettings();
//This is important if you are scanning a multi-page document. You can also set to PDF.
_imgScan.DeviceSettings.OutputFormat = ImgScan.ICImageOutputFormat.TIFF;
_imgScan.SetTwainSettings = new ImgScan.TwainSettings();
_imgScan.SetTwainSettings.Values.TwainICapabilities.ImageXferMech = ImgScan.ICAP_XFERMECH.NATIVE;
_imgScan.Acquire();
});
}
else {
_imgScan.ActiveSourceName = "TWAIN2 FreeImage Software Scanner";
_imgScan.DeviceDriverType = ImgScan.ICDeviceDriverType.TWAIN;
_imgScan.DeviceSettings = new ImgScan.ICDeviceSettings();
//This is important if you are scanning a multi-page document. You can also set to PDF.
_imgScan.DeviceSettings.OutputFormat = ImgScan.ICImageOutputFormat.TIFF;
_imgScan.SetTwainSettings = new ImgScan.TwainSettings();
_imgScan.SetTwainSettings.Values.TwainICapabilities.ImageXferMech = ImgScan.ICAP_XFERMECH.NATIVE;
_imgScan.Acquire();
}
}
function addAnnotation() {
_imgAnnotations.EnableAnnotationType = ImgAnnotations.ICAnnotationType.HighlightAnnotation;
_imgEdit.EnableSelectionType = ImgEdit.ICSelectionType.ANNOTATIONSELECTION;
}
//This events are hired up on page load method.
//On web socket connection.
function onSocketStatusChanged(s, e) {
switch (e) {
case ImgScan.ICWSocketStatus.CONNECTING:
break;
case ImgScan.ICWSocketStatus.CONNECTED:
break;
case ImgScan.ICWSocketStatus.CONNECTIONERROR:
if (_isImgScanDownloading == false) {
if (confirm('Could not connect to the ImgScan twain bridge plugin.\r\nDo you want to download the installation package and try again?')) {
_isImgScanDownloading = true;
_imgScan.DownloadScanService("http://localhost/IC.Web.Imaging/ImgScan/ICScanService.zip");
} else {
_imgScan.CloseConnection();
}
}
break;
case ImgScan.ICWSocketStatus.RECONNECTING:
break;
}
}
//On scan finished event.
function onScanFinished(s, e) {
//Upload the image to your server.
var _base64Image = e.Stream;
}
function onErrorOccurred(s, e) {
alert("One error occurred in the control '" + e.ControlName + "'.\r\nThe error detail in the method '" + e.MethodName +
"' is as follows:\r\n\r\n" + e.ErrorMessage + "\r\n\r\nSorry for this inconvenient. ");
}
Run the application by pressing the F5 key or by clicking the play button on Visual Studio.
Click the 'Open' button and it should display an example tif image file.
Click the 'Add Highlight' button and draw the highlight annotation into the image.
###################################### - Using Image Components Web ImgBarDecoder Component - ######################################
Open the previous ASP.NET MVC 4 project.
Add a reference to the ImageComponents.Web.Mvc.ImgBarDecoder.dll assembly that can be found on the SDK installation folder\Examples\Assemblies\Web\Mvc\
Include the ImgBarDecoder-vsdoc.js file in the 'Scripts' project folder. This file can be found on the SDK installation folder\Examples\Web\Version4\CSharp\Forms\IC.Web.ImageEditor\js\
Open the Index.cshtml view in order to display the HTML source code.
Add an Input (Button) element as:
Add the following script elements to the head of the page:
Insert in the beginning of the body element the configuration of the ImgBarDecoder control: @Html.ImgBarDecoderManager().ScriptResource().Include()
The full HTML code may look like this: @using ImageComponents.Web.Imaging.Mvc; Index @Html.ImgEditManager().ScriptResource().Include() @Html.ImgThumbnailsManager().ScriptResource().Include() @Html.ImgScanManager().ScriptResource().Include() @Html.ImgAnnotationsManager().ScriptResource().Include() @Html.ImgBarDecoderManager().ScriptResource().Include() @Html.ImgEditManager().SetWidth("400px") @Html.ImgEditManager().SetHeight("500px") @Html.ImgThumbnailsManager().SetWidth("150px") @Html.ImgThumbnailsManager().SetHeight("500px")
@Html.ImgEditManager().Render("imgEdit1") | @Html.ImgThumbnailsManager().Render("imgThumbnails1") |
Open and add the following JavaScript code to the index.cshtml.js file: /// /// /// /// /// var _webServiceURL = "http://localhost/IC.Web.Imaging/ImageManagerService.svc"; var _imgEdit = null; var _imgThumbnails = null; var _imgScan = null; var _imgAnnotations = null; var _imgBarDecoder = null; //Comment the following lines on release. This is just for intellisense purposes. _imgEdit = new ImgEdit(); _imgThumbnails = new ImgThumbnails(); _imgScan = new ImgScan(); _imgAnnotations = new ImgAnnotations(); _imgBarDecoder = new ImgBarDecoder();
var _isImgScanDownloading = false;
function pageLoad() {
//Get the ImgEdit control.
_imgEdit.set_WebServiceURL(_webServiceURL);
_imgEdit.addEventListener("ErrorOccurred", onErrorOccurred);
_imgScan.addEventListener("ErrorOccurred", onErrorOccurred);
_imgScan.addEventListener("SocketStatusChanged", onSocketStatusChanged);
_imgScan.addEventListener("ScanFinished", onScanFinished);
_imgBarDecoder.addEventListener("ScanFinished", onBarcodeScanFinished);
}
function openImage() {
_imgEdit.DisplayUrl('http://www.imagecomponents.net/Documentation/Doc.tif');
_imgEdit.FitTo(ImgEdit.ICImageFit.BESTFIT, true);
}
function scanImage() {
//Close existing image if open.
_imgEdit.Close();
if (_imgScan.ConnectionStatus !== ImgScan.ICWSocketStatus.CONNECTED) {
_imgScan.OpenConnection(function () {
_imgScan.ActiveSourceName = "TWAIN2 FreeImage Software Scanner";
_imgScan.DeviceDriverType = ImgScan.ICDeviceDriverType.TWAIN;
_imgScan.DeviceSettings = new ImgScan.ICDeviceSettings();
//This is important if you are scanning a multi-page document. You can also set to PDF.
_imgScan.DeviceSettings.OutputFormat = ImgScan.ICImageOutputFormat.TIFF;
_imgScan.SetTwainSettings = new ImgScan.TwainSettings();
_imgScan.SetTwainSettings.Values.TwainICapabilities.ImageXferMech = ImgScan.ICAP_XFERMECH.NATIVE;
_imgScan.Acquire();
});
}
else {
_imgScan.ActiveSourceName = "TWAIN2 FreeImage Software Scanner";
_imgScan.DeviceDriverType = ImgScan.ICDeviceDriverType.TWAIN;
_imgScan.DeviceSettings = new ImgScan.ICDeviceSettings();
//This is important if you are scanning a multi-page document. You can also set to PDF.
_imgScan.DeviceSettings.OutputFormat = ImgScan.ICImageOutputFormat.TIFF;
_imgScan.SetTwainSettings = new ImgScan.TwainSettings();
_imgScan.SetTwainSettings.Values.TwainICapabilities.ImageXferMech = ImgScan.ICAP_XFERMECH.NATIVE;
_imgScan.Acquire();
}
}
function addAnnotation() {
_imgAnnotations.EnableAnnotationType = ImgAnnotations.ICAnnotationType.HighlightAnnotation;
_imgEdit.EnableSelectionType = ImgEdit.ICSelectionType.ANNOTATIONSELECTION;
}
function readBarcodes() {
_imgBarDecoder.ImageBarcodeTypes = [];
_imgBarDecoder.ImageBarcodeTypes.push(ImgBarDecoder.ICImageBarcodeType.CODE39);
_imgBarDecoder.ImageBarcodeOrientations = [];
_imgBarDecoder.ImageBarcodeOrientations.push(ImgBarDecoder.ICImageBarcodeOrientation.LEFTTORIGHT);
_imgBarDecoder.StopOnFirstResult = false;
_imgBarDecoder.ExtensiveSearch = true;
_imgBarDecoder.EnableCheckDigit = false;
_imgBarDecoder.ImageBarcodePageType = ImgBarDecoder.ICImageBarcodePageType.SELECTEDPAGE;
_imgBarDecoder.ReadBarcodes();
}
function getEnumValue(enumObj, key) {
for (var obj in enumObj) {
if (enumObj[obj] === key) {
return obj;
}
}
return null;
}
//This events are hired up on page load method.
//On web socket connection.
function onSocketStatusChanged(s, e) {
switch (e) {
case ImgScan.ICWSocketStatus.CONNECTING:
break;
case ImgScan.ICWSocketStatus.CONNECTED:
break;
case ImgScan.ICWSocketStatus.CONNECTIONERROR:
if (_isImgScanDownloading == false) {
if (confirm('Could not connect to the ImgScan twain bridge plugin.\r\nDo you want to download the installation package and try again?')) {
_isImgScanDownloading = true;
_imgScan.DownloadScanService("http://localhost/IC.Web.Imaging/ImgScan/ICScanService.zip");
} else {
_imgScan.CloseConnection();
}
}
break;
case ImgScan.ICWSocketStatus.RECONNECTING:
break;
}
}
//On scan finished event.
function onScanFinished(s, e) {
//Upload the image to your server.
var _base64Image = e.Stream;
}
//On barcode scan finished event.
function onBarcodeScanFinished(s, e) {
if (_imgBarDecoder.ReadedBarcodesResults != null && _imgBarDecoder.ReadedBarcodesResults.length > 0) {
var _resultValue = "";
for (var i = 0; i < _imgBarDecoder.ReadedBarcodesResults.length; i++) {
var _result = _imgBarDecoder.ReadedBarcodesResults[i];
_resultValue += "Barcode type: " + getEnumValue(ImgBarDecoder.ICImageBarcodeType, _result.BarcodeType) + "\r\n" +
"Barcode result: " + _result.Text + "\r\n\r\n";
}
alert(_resultValue);
}
}
function onErrorOccurred(s, e) {
alert("One error occurred in the control '" + e.ControlName + "'.\r\nThe error detail in the method '" + e.MethodName +
"' is as follows:\r\n\r\n" + e.ErrorMessage + "\r\n\r\nSorry for this inconvenient. ");
}
Run the application by pressing the F5 key or by clicking the play button on Visual Studio.
Click the 'Open' button and it should display an example tif image file.
Click the 'Read Barcodes' button to read the image CODE39 barcode.
FAQs
Supported Platforms: • NETFramework Image Components for ASP.Net MVC is an imaging SDK that allows the view, edit, capture, creation and data manipulation. Some of the Image Components functions are: opening file or directory and saving most common images file types (*.jpg;*.jpeg;*.tif;*.tiff;*.bmp;*.gif;*.png;*.cut;*.dds;*.g3;*.hdr;*.ico;*.iff;*.lbm;*.jng;*.koa;*.mng;*.pbm;*.pcd;*.pcx;*.pgm;*.ppm;*.psd;*.ras;*.sgi;*.tga;*.targa;*.wbmp;*.xbm;*.xpm;*.wmf;*.pdf;*.xps) and convert between them. Thumbnail view of the image multi or single page. Navigation between the pages, by thumbnail click or by toolbar. Image fit to the screen (original, best and width). Rotate left, right, flip and mirror. Zoom + and Zoom -. Inserting, appending, deleting or moving pages. Cropping by selection or auto cropping, resizing, undo, redo, copy and paste. Many filters like invert, grayscale, etc. Image enhance (color, brightness, smooth, sharpen, etc.). Many edge detectors. Glass tool to zoom a particular part of the image. Thumbnail viewing, navigation and position management. Twain and WIA support using ADF or flat bed, multi page or single page. Save and Scanner options by image type or compression (None, JPG, CCITT3, CCITT4, LZW, PDF...) . Access to the most common Capabilities and ICapabilities. Document, page, zone OCR and text search, supporting some common languages. PDF reading and export, multi, single or selected page. PDF text search and extraction. Full customized image annotations including, Note, Stamps, Highlight, Hide, Ellipse, Line, Arrow and Image. Barcode encoder and decoder. Supports Code11, Code 39, Interleaved 2 of 5, Codabar, Code 93, EAN8, EAN13, UPCA, Code128, PDF417, QRCODE. Automatic barcode detection and scan direction.
We found that imagecomponents.mvc.imaging demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovered npm malware campaign mimicking popular Node.js libraries and packages from other ecosystems; packages steal data and execute remote code.
Research
Socket's research uncovers three dangerous Go modules that contain obfuscated disk-wiping malware, threatening complete data loss.
Research
Socket uncovers malicious packages on PyPI using Gmail's SMTP protocol for command and control (C2) to exfiltrate data and execute commands.