PRIM_WEB.BlobReader (PRIM_WEB.BlobReader)

Returns a BLOB as a Base64 data string

Ancestors - Object (PRIM_OBJT)

Details

Blob Reader asynchronously converts a LANSA Blob variable to a Base64 encoded string.
 
When the Blob has been read, the Completed event will be fired.

Example

In this example, a selected file is converted to Base64.
Begin_Com Role(*EXTENDS #PRIM_WEB) Height(432) Width(777) Theme(#SYS_THEME<2015Blue>)
 
   Define_Com Class(#prim_web.BlobReader) Name(#Blobreader)
   Define_Com Class(#PRIM_TEXT) Name(#Text) DisplayPosition(1) Left(18) Parent(#COM_OWNER) TabPosition(1) Top(64) Width(711) Height(345)
   Define_Com Class(#PRIM_WEB.FilePicker) Name(#FilePicker) Caption('Pick a File') DisplayPosition(2) Ellipses(Word) Height(25) Left(23) Parent(#COM_OWNER) TabPosition(2) TabStop(False) Top(15) VerticalAlignment(Center) Width(120) ThemeDrawStyle('MediumTitle') Alignment(Center)
 
   Evtroutine Handling(#FilePicker.FileSelected) File(#File)
 
      #Blobreader.Read( #File.Blob )
 
      #Text := "Reading Blob"
 
   Endroutine
 
   Evtroutine Handling(#Blobreader.Completed) Data(#Data)
 
      #Text := #Data
 
   Endroutine
 
End_Com

Properties

NameDescription
ComponentClassNameComponentClassName is the name of the component's class. Inherited from Object (PRIM_OBJT)
ComponentMembersComponentMembers provides access to all the member components of this component Inherited from Object (PRIM_OBJT)
ComponentPatternNameComponentPatternName is used to qualify the class of the component. Inherited from Object (PRIM_OBJT)
ComponentTagGeneric space allowing a value to be stored for the instance Inherited from Object (PRIM_OBJT)
ComponentTypeComponentType gives you access to the type information about the component Inherited from Object (PRIM_OBJT)
ComponentTypeNameComponentTypeName is the fully qualified name of the component's class. Inherited from Object (PRIM_OBJT)
NameName identifies the component Inherited from Object (PRIM_OBJT)
OwnerOwner owns this component Inherited from Object (PRIM_OBJT)
ParentThe component instance to which this instance is attached. The visual container for a control or the collector of a set of child instances Inherited from Object (PRIM_OBJT)

Events

NameDescription
CompletedFired when the BLOB has been read
Data
CreateInstanceCreateInstance is signalled when an instance of a component is created Inherited from Object (PRIM_OBJT)
DestroyInstanceDestroyInstance is signalled when an instance of a component is about to be destroyed Inherited from Object (PRIM_OBJT)

Methods

NameDescription
ReadRead the contents of the BLOB
Blob

See also

All Component Classes

Technical Reference

Febuary 18 V14SP2