VintaSoft Imaging .NET SDK v8.6
Vintasoft.Imaging Namespace / VintasoftFileAPI type / uploadImageFile Method
File from the HTML INPUT object of FILE type.
Function that will be executed if request is executed successfully.
Here is function prototype "function __success(data)".
The data parameter has the following properties:
Function that will be executed if request is failed.
Here is function prototype "function __error(data)".
The data parameter can be:
  1. An object with following properties:
    • errorMessage (string): Error message.
    • blocked (boolean): Indicates that the requested action is blocked by another request.
    if exception is catched inside web service.
  2. Otherwise, jqXHR object.
An instance, of WebServiceJS class, which will serve the request of this function.
In This Topic
    uploadImageFile Method
    In This Topic
    Sends an asynchronous request to a server for uploading an image file to a server.
    Syntax
    var value; // Type: any
    
    // Parameters
    var file; // Type:  object
    var successFunc; // Type:  object
    var errorFunc; // Type:  object
    var service; // Type:  object
    
    value = Vintasoft.Imaging.VintasoftFileAPI.uploadImageFile(file, successFunc, errorFunc, service);
    function uploadImageFile( 
       file : object,
       successFunc : object,
       errorFunc : object,
       service : object
    ) : any;

    Parameters

    file
    File from the HTML INPUT object of FILE type.
    successFunc
    Function that will be executed if request is executed successfully.
    Here is function prototype "function __success(data)".
    The data parameter has the following properties:
    • fileId (string): Image file identifier.
    errorFunc
    Function that will be executed if request is failed.
    Here is function prototype "function __error(data)".
    The data parameter can be:
    1. An object with following properties:
      • errorMessage (string): Error message.
      • blocked (boolean): Indicates that the requested action is blocked by another request.
      if exception is catched inside web service.
    2. Otherwise, jqXHR object.
    service
    An instance, of WebServiceJS class, which will serve the request of this function.
    Browser Compatibility
    9
    5
    11
    5
    See Also