https://bugs.documentfoundation.org/show_bug.cgi?id=146157

--- Comment #8 from Michael Kogan <[email protected]> ---
Sorry, I pasted the wrong piece of code, here is the specific one for this
case:


_________________________________________
REM  *****  BASIC  *****

Sub Writer_Find_and_Replace_Formula()
REM     This finds all occurrences of "=" within all Formula objects embedded
within the current Writer document,
REM and adds curly braces "{}" to prevent the display of question marks.
REM NB. This action can not be Undone via the menu "Edit : Undo".
        Dim oDoc As Object
        oDoc = ThisComponent

        Dim oEmbeddedObjects As Object, oObj As Object
        oEmbeddedObjects = oDoc.getEmbeddedObjects()

        Dim i As Integer
        For i = 0 To oEmbeddedObjects.getCount() - 1
                oObj = oEmbeddedObjects.getByIndex( i ).getEmbeddedObject()

                If oObj.ImplementationName =
"com.sun.star.comp.Math.FormulaDocument" Then      REM Found a Formula.
                        oObj.Formula = Join( Split( oObj.Formula, "=" ), "={}"
)                REM Perform Find & Replace.
                End If

        Next i
End Sub
_________________________________________

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

Reply via email to