Hi all,
I have an agent for importing images selected by the users into the image resources of a db. The code works fine with 8.x release and previous.
With release 9.0 the imported image (only for png file type) is broken and if you try to use it, the client crashes.
The importer works with JPG or GIF images.
It seems that the NotesDXLImporter class in the new release has a fault…
Any idea?
Stefano
Ps: If you want to reproduce it follow these steps:
-
Import a png file in your image resources.
-
Using tools\DXL Utilities\Exporter create the xml for that image
-
Write an agent with this code:
Dim session as new notessession Dim importer As NotesDXLImporter Dim stream As NotesStream Dim filename As String Set stream = session.CreateStream filename = “C:\Image.xml” '<<<< path of the xml file If Not stream.Open(filename) Then MessageBox "Unable to open file " & filename, “Error” Exit Function End If ’ Import the DXL in “create” mode - replaces existing images Set importer = session.CreateDXLImporter ’ --------------- Replica DB ---------------------- importer.ReplicaRequiredForReplaceOrUpdate = False ’ ------------------------------------------------- On Error GoTo errh Call importer.SetInput(stream) Call importer.SetOutput(db) importer.DesignImportOption = DXLIMPORTOPTION_REPLACE_ELSE_CREATE Call importer.Process Call stream.Close
4. Run the agent
- The resource is created in image resources but it is not viewable or utilizable in any form