https://bz.apache.org/ooo/show_bug.cgi?id=127238

          Issue ID: 127238
        Issue Type: DEFECT
           Summary: OpenOffice Error vnd.sun.star.GraphicObject
           Product: Calc
           Version: 3.3.0 or older (OOo)
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P5 (lowest)
         Component: code
          Assignee: [email protected]
          Reporter: [email protected]
  Target Milestone: ---

am trying to display an image from a SpreadSheet(OpenOffice) into my PictureBox
control and here is my code.

    Dim objServiceManager As Object
    Dim objDesktop        As Object
    Dim objDocument       As Object
    Dim objText           As Object
    Dim objCursor         As Object
    Dim oDoc              As Object
    Dim ARG()
    Dim oGraph    As Object
    Dim oView     As Object
    Dim oDrawPage As Object
    Dim oSheet    As Object
    Dim oimage    As Object
    Dim osize     As Object
    Dim Cell      As Object
    Dim GraphURL As String

    Set objServiceManager = CreateObject("com.sun.star.ServiceManager")
    Set objDesktop =
objServiceManager.createInstance("com.sun.star.frame.Desktop")
    Set osize = objServiceManager.Bridge_GetStruct("com.sun.star.awt.Size")
    Set opos = objServiceManager.Bridge_GetStruct("com.sun.star.awt.Point")
    Set oDoc =
objDesktop.loadComponentFromURL("file:///C:\Users\paul\Desktop\ACE Express -
Fairview_Sample PC of Gondola.ods", "_blank", 0, ARG())
    Set oSheet = oDoc.getSheets().getByIndex(0)
    Set oimage = oDoc.createInstance("com.sun.star.drawing.GraphicObjectShape")
    Set oView = oDoc.CurrentController
    Set oDrawPage = oView.getActiveSheet.DrawPage
    Set oControl = oDoc
    Set oDrawPage = oDoc.getDrawPages().getByIndex(0)
    Set oimage = oDrawPage.getByIndex(0)

    Image1.Picture = LoadPicture(oimage.GraphicURL)

But sad to say I have this error

My goal is how can i load image from Calc Spreadsheet into VB6 Imagebox


Please take note of the following:

 - The spreadsheet used is OpenOffice Calc
 - Displaying the image inside Picturebox (VB6)

-- 
You are receiving this mail because:
You are the assignee for the issue.

Reply via email to