Bug 73123 - Macro recorder does not record selecting a column
Summary: Macro recorder does not record selecting a column
Status: RESOLVED WONTFIX
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: BASIC (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: Other All
: low enhancement
Assignee: Not Assigned
URL:
Whiteboard: BSA
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-29 14:11 UTC by jean.sanchez
Modified: 2015-12-25 02:37 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
a spreadsheet with data that behaves like explained. The macro is to be recorded manually. (70.62 KB, application/vnd.oasis.opendocument.spreadsheet)
2013-12-29 14:11 UTC, jean.sanchez
Details

Note You need to log in before you can comment on or make changes to this bug.
Description jean.sanchez 2013-12-29 14:11:10 UTC
Created attachment 91291 [details]
a spreadsheet with data that behaves like explained. The macro is to be recorded manually.

Problem description: 
I recorded a macro which deleted G column.
While applying it again it deletes always the A column instead the column that should have been recorded.


Steps to reproduce:
1. create some columns filled with anything, starting from A, or use the attached file (about one stock values, easy to read).
2. Record a macro which deletes (not the values, the whole column) G column
3. open back the initial file
4. apply the recorded macro

Current behavior:
it deletes always the column A

Expected behavior:
it should delete the G column that was recorded in the macro.
Operating System: Mac OS X
Version: 4.1.4.2 release
Comment 1 Julien Nabet 2013-12-29 15:16:46 UTC
I gave a try with master sources updated today.
In tests I did, it deleted the column where the cursor was.
Comment 2 Terrence Enger 2013-12-29 16:45:10 UTC
Julien beat me to it, but here is the comment I had prepared.

Starting from scratch, I recorded a macro while I selected column C
(by mouse click on the column heading) and deleted the column from the
pop-up menu.  The recorded macro did not capture the selection
operation.  Thus, in playback, the macro deletes each column that has
a selected cell.

For comparison:
(*) a macro recorded in Writer does copture selection done by
    <shift>+<right-arrow>.
(*) a macro recorded in Calc does capture selection by mouse-click on
   a cell and following <shift>+<right-arrow> <shift>+<down-arrow>.

My observations are in a debug build of master commit 480c7c2, fetched
2013-12-27 02:33 UTC.  So I am setting platform = All.
Comment 3 Terrence Enger 2013-12-29 16:46:10 UTC
This time fer shur, Rocky.
Comment 4 tommy27 2014-11-02 08:45:16 UTC
still reproducible with LibO 4.3.2.2 under Win7x64

(In reply to Terrence Enger from comment #2)
> ... The recorded macro did not capture the selection
> operation.  Thus, in playback, the macro deletes each column that has
> a selected cell.
> 
> ....

yes, this is exactly what happens.
this is the recorded code which is the same as in OOo 3.3.0

sub test
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 ----------------------------------------------------------------------
dispatcher.executeDispatch(document, ".uno:DeleteColumns", "", 0, Array())
end sub

so we are dealing with one of the limitation of the macro recorder which is inherited from OOo.
Comment 5 QA Administrators 2015-12-20 16:17:21 UTC Comment hidden (obsolete)
Comment 6 Terrence Enger 2015-12-24 16:54:23 UTC
Running daily dbgutil bibisec repo version 2015-12-20 in an
environment chroot'd to debian sid, I see that "record macro" does not
capture the selection of a column made by clicking on the column
heading.

So the problem still happens.
Comment 7 Maxim Monastirsky 2015-12-24 18:40:14 UTC
The current macro recorder only records commands executed via the dispatcher. It's not designed to record user actions, and there is no way to "fix" it, other than rewriting from scratch. There is a very good reason why the checkbox in Tools->Options has the word "limited" in it.
Comment 8 Terrence Enger 2015-12-25 02:37:58 UTC
Thank you, Maxim.  I am setting bug status RESOLVED WONTFIX.