Bug 168331 - Macro does not work for table because of lack of methods
Summary: Macro does not work for table because of lack of methods
Status: REOPENED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
26.2.0.0 alpha0+ master
Hardware: All Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-09-09 14:20 UTC by NarayanAras
Modified: 2025-09-10 15:20 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Debug macro provided by ChatGPT, and its report (1.82 KB, application/x-zip-compressed)
2025-09-09 14:24 UTC, NarayanAras
Details

Note You need to log in before you can comment on or make changes to this bug.
Description NarayanAras 2025-09-09 14:20:00 UTC
Description:
I asked ChatGPT top create a macro that inserts a pattern with autoserialized numbers in selected cells of a table.

(e.g. Sl 01, Sl 02, Sl 03,....)

But ChatGPT kept failing. Finally it has written a debug macro to extract the methods in table object that its macro can use.

After running this macro in my system, it reports that there is no method in the table object, and so it is not possible to write this macro.

Attaching the macro and the debug output.

I am not a coder, so this report is as received from ChatGPT.


Steps to Reproduce:
1.Run the attached macro.
2. It gives a list of attributes and methods in Table object.
3.

Actual Results:
No methods are listed in the debug report.

Expected Results:
Various methods were expected. According to ChatGPT, it has scanned the latest documentation. But it is possible that it may have missed the correct address. 


Reproducible: Always


User Profile Reset: No

Additional Info:
[Information automatically included from LibreOffice]
Locale: en-US
Module: TextDocument
[Information guessed from browser]
OS: Windows (All)
OS is 64bit: yes
Comment 1 NarayanAras 2025-09-09 14:24:17 UTC
Created attachment 202764 [details]
Debug macro provided by ChatGPT, and its report
Comment 2 NarayanAras 2025-09-09 14:25:59 UTC
This is what I asked ChatGPT:

Write a macro for LibreOffice Writer. 

It should let the user select a range of cells (1xn or nx1), and fill it with a pattern as follows: 

----------------- 
Step-1: 
The macro shows a dialog with this default pattern: 

Sl |1|0 

Where- 
- Parameter#1 is text. 
   default: "Sl " (short for "serial", followed by a space) 
- Parameter#2: The starting number. 
    default: 1 
- Parameter#3: The number of digits to which the number is to be padded with leading zeros. 
    Default: 0 (meaning no padding). 
- The pipe (|) is the parameter-separator.
  
The dialog should show this explainer text: 
<Text> | <startingNumber> | <paddingLength> 

-------------------------- 
Step-2: 
The user edits the pattern and presses OK. 
The macro fills the selected range.

---------------------------------
Error-handling:

If the user has not selected contiguous cells along a row/column, ask him to select a 1xn or nx1 range and exit.
Comment 3 Robert Großkopf 2025-09-09 15:07:10 UTC
This isn't a bug. Seems you (and ChatGPT) will need help for getting it work. You could create a new entry in https://ask.libreoffice.org/ instead. Most answers will appear in https://ask.libreoffice.org/c/english/5
Comment 4 NarayanAras 2025-09-10 13:59:23 UTC
I tried the community, but they are unable to help.
I saw 13-year old bug still unresolved.

These are not good resolutions!
Comment 5 Robert Großkopf 2025-09-10 14:46:07 UTC
(In reply to NarayanAras from comment #4)
> I tried the community, but they are unable to help.
> I saw 13-year old bug still unresolved.
> 
> These are not good resolutions!

Seems you expect a hotline, not help from the community. You wrote about a different problem in
https://ask.libreoffice.org/t/unable-to-generate-valid-macros-using-chatgpt-and-grok-both-report-interpreter-issues/126540/10

So the main problem for you seems to be: Why isn't ChatGPT able to create the macro in a right way. But ChatGPT isn't a component of LibreOffice.
Comment 6 NarayanAras 2025-09-10 15:17:00 UTC
I am a member of multiple communities to understand the way they work. That's why I could make out that there are no solutions. I did get a few replies, but they do not explain why a method is not working.

I do not anticipate that anyone can answer such fundamental problems. 

I am NOT looking at ChatGPT as you outlined. Let me explain: ChatGOT creates a macro using a few attributes and functions, and I try them in macro Editor (ALT+F11). It reports bugs. I report them back. ChatGPT tries to use another approach and different attribute/function. I repeat. 

The macro takes about 2 days of morning-to-evening effort. Then I try Grok. It obviously tries a different algorithm, but again after one day of trials it also gives up.

It has taken a really sincere effort from me and the AI engines. Please respect the process.

Now that I am raising a bug that a specific attribute/function does not work, why is that a solvable issue by the community??

Some time ago I had submitted a systematic list of such non-working functions. I got a similar flippant answer. Really!
Comment 7 NarayanAras 2025-09-10 15:20:52 UTC
I have used ChatGPT to create a couple of macros in Writer, and also Python scripts to create bookmarks in complex pdf files. So this is not as if I am raising some issues out of ignorance.

It's a simple problem: Specific methods/attributes are not working as expected.