[Libreoffice-bugs] [Bug 135242] Calc: Macro - sorting is working just for first 3 criteria

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Tue Jul 28 17:34:32 UTC 2020


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

--- Comment #3 from BogdanB <buzea.bogdan at libreoffice.org> ---
Code in MACRO that is executed:

REM  *****  BASIC  *****

Sub Main

End Sub


sub Macro1
rem ----------------------------------------------------------------------
rem define variables
dim document  as object
dim dispatcher as object
rem ----------------------------------------------------------------------
rem get access to the document
document   = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")

rem ----------------------------------------------------------------------
dim args1(0) as new com.sun.star.beans.PropertyValue
args1(0).Name = "DbName"
args1(0).Value = "bd"

dispatcher.executeDispatch(document, ".uno:SelectDB", "", 0, args1())

rem ----------------------------------------------------------------------
dim args2(17) as new com.sun.star.beans.PropertyValue
args2(0).Name = "ByRows"
args2(0).Value = true
args2(1).Name = "HasHeader"
args2(1).Value = true
args2(2).Name = "CaseSensitive"
args2(2).Value = false
args2(3).Name = "NaturalSort"
args2(3).Value = false
args2(4).Name = "IncludeAttribs"
args2(4).Value = true
args2(5).Name = "UserDefIndex"
args2(5).Value = 0

args2(6).Name = "Col1"
args2(6).Value = 16
args2(7).Name = "Ascending1"
args2(7).Value = true

args2(8).Name = "Col2"
args2(8).Value = 17
args2(9).Name = "Ascending2"
args2(9).Value = false

args2(10).Name = "Col3"
args2(10).Value = 23
args2(11).Name = "Ascending3"
args2(11).Value = false

args2(12).Name = "Col4"
args2(12).Value = 20
args2(13).Name = "Ascending4"
args2(13).Value = true

args2(14).Name = "Col5"
args2(14).Value = 21
args2(15).Name = "Ascending5"
args2(15).Value = true

args2(16).Name = "IncludeComments"
args2(16).Value = false
args2(17).Name = "IncludeImages"
args2(17).Value = true

dispatcher.executeDispatch(document, ".uno:DataSort", "", 0, args2())

end sub

Sub Macro2

End Sub

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20200728/857cea94/attachment.htm>


More information about the Libreoffice-bugs mailing list