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

Aaron J. Peterson <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |UNCONFIRMED
     Ever confirmed|1                           |0

--- Comment #2 from Aaron J. Peterson <[email protected]> ---
It's not a bug with a document or my setup.  There simply isn't a Parent
property on comment objects, and there should be one.  Are you looking for
examples of why this should be?  There are a ton of uses -
http://dmcritchie.mvps.org/excel/ccomment.htm has a boatload.  Here's a simple
one:


Sub DelComments()
    Dim cm As Comment
    Dim ws As Worksheet

    For Each ws In Worksheets
        ws.Activate
        For Each cm In ActiveSheet.Comments
            cm.Delete
            cm.Parent.AddComment Text:="Comment is deleted."
        Next cm
    Next ws
End Sub


(from
https://www.mrexcel.com/forum/excel-questions/539902-visual-basic-applications-parent-comment.html)

This fails because cm.Parent, which should be the parent cell Range object, is
Nothing.  You'll get this error on that line:

BASIC runtime error.
'91'
Object variable not set.

I'll make up a file with that script and a spreadsheet with a comment if you
think need it.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to