Products | Support | Email a link to this topic. | Send comments on this topic. | Back to Introduction - All Topics | Help Version 19.0.8.30
|
Leadtools.Codecs Namespace : CodecsLoadSvgAsyncCompletedEventArgs Class |
public class CodecsLoadSvgAsyncCompletedEventArgs : CodecsAsyncCompletedEventArgs
'Declaration
Public Class CodecsLoadSvgAsyncCompletedEventArgs Inherits CodecsAsyncCompletedEventArgs
'Usage
Dim instance As CodecsLoadSvgAsyncCompletedEventArgs
public sealed class CodecsLoadSvgAsyncCompletedEventArgs : CodecsAsyncCompletedEventArgs
public class CodecsLoadSvgAsyncCompletedEvent extends CodecsAsyncCompletedEvent
function Leadtools.Codecs.CodecsLoadSvgAsyncCompletedEventArgs()
public ref class CodecsLoadSvgAsyncCompletedEventArgs : public CodecsAsyncCompletedEventArgs
The RasterCodecs class supports loading SVG from image files asynchronously using the LoadAsync methods. When calling any of these methods, the caller thread will not be blocked and the method will return instantly.
When the RasterCodecs object finishes loading the SVG, the LoadSvgAsyncCompleted event will occur when the operation is finished (or when an error occur).
The LoadSvgAsyncCompleted event uses a data argument object of type CodecsLoadSvgAsyncCompletedEventArgs. This class contains the following properties:
Property | Description |
---|---|
CodecsLoadSvgAsyncCompletedEventArgs.Uri, CodecsLoadSvgAsyncCompletedEventArgs.Stream and CodecsLoadSvgAsyncCompletedEventArgs.FileName |
Contains the URI, stream or file name passed to the method that initialized this asynchronous operation. Only one of these properties can be a valid value (not a null reference) at any time The property that contains a valid reference depends on what version of LoadSvgAsync method has been called. For example, if LoadSvgAsync(Uri uri, int pageNumber, CodecsLoadSvgOptions options, object userState) is being called, the Uri will contain the same URI passed to the method while Stream and FileName will both be null. If LoadSvgAsync(String fileName, int pageNumber, CodecsLoadSvgOptions options, object userState) is being called, the FileName will contain the same file name string value passed to the method while Uri and Stream will both be null and so on. |
CodecsLoadSvgAsyncCompletedEventArgs.Document |
Contains the ISvgDocument instance that contains the SVG data of the page being loaded. When the asynchronous operation completes, the LoadSvgAsyncCompleted event will fire and Document will contain the final and ready to use SVG object. If an error occurs, this property will be set to null and the object is disposed internally by the toolkit. |
CodecsLoadSvgAsyncCompletedEventArgs.Error |
Contains any errors that might have occurred during the asynchronous operation. You must check this value when the LoadSvgAsyncCompleted event fires and make sure it does not contain a valid Exception object. |
CodecsLoadSvgAsyncCompletedEventArgs.Cancelled |
Contains a value indicating whether an asynchronous operation has been canceled. For example, by calling CancelAsync when using RasterCodecs.LoadAsync with a URL. |