Code: Select all
Function Replace(Source As String, Search As String, NewPart As String)
Dim Result As String
Result = join(split(Source, Search), NewPart)
Replace = Result
End Function
Sub Show(obj_ As Object, type_ As Integer)
Dim str As String
if type_=0 then str = obj_.DBG_Methods
if type_=1 then str = obj_.DBG_Properties
if type_=2 then str = obj_.DBG_SupportedInterfaces
str = Replace(str,Chr(10),"")
str = Replace(str,";",";"&Chr(10))
str = Replace(str,":",":"&Chr(10)&Chr(10)&" ")
str = Replace(str,"Sbx","")
Dim s()
s=Split(str,";")
iter=0
For i=LBound(s) to UBound(s)
if type_=1 then
s(i)=Replace(s(i),";","")
if InStr(s(i),"BOOL")>0 then s(i)=Replace(s(i)," BOOL ","")&" As Boolean"
if InStr(s(i),"INTEGER")>0 then s(i)=Replace(s(i)," INTEGER ","")&" As Integer"
if InStr(s(i),"DOUBLE")>0 then s(i)=Replace(s(i)," DOUBLE ","")&" As Double"
if InStr(s(i),"STRING")>0 then s(i)=Replace(s(i)," STRING ","")&" As String"
if InStr(s(i),"OBJECT")>0 then s(i)=Replace(s(i)," OBJECT ","")&" As Object"
if InStr(s(i),"LONG")>0 then s(i)=Replace(s(i)," LONG ","")&" As Long"
if InStr(s(i),"ARRAY")>0 then s(i)=Replace(s(i)," ARRAY ","")&" As Array"
endif
's(i)=s(i)&"+"
iter=iter+1
if iter>30 then
iter=0
s(i)=s(i)&">>>"
end if
Next i
str=Join(s)
s=Split(str,">>>")
For i=LBound(s) to UBound(s)
msgbox "Page "+i+" of "+UBound(s)+Chr(10)+Chr(10)+s(i)
Next i
End Sub
Show(obj_ As Object, type_ As Integer)
obj_= any object as Frame, Imgae, etc.
type_ = is what we want to see:
0 - show all object methods
1 - show all object propertys
2 - show all object interfaces
Code: Select all
Doc = ThisComponent
Show(Doc,0)