Replicate View and View in DocStar Attachment events

Hello,

I’m trying replicate the same functionality View and View in DocStar buttons do, I did a trace but just the below method was caught:

Ice.Proxy.BO.AttachmentImpl
GetAccountForUser

Have someone replicated this before?

Thanks