I dropped by the forum in need to change standard footer menu (sum, count, ave ...) for my own and saw messages about openAI writing harbour code so I tried it.
I asked: "write harbour code that modifies xbrowse footer popup menu"
Here is what I got:
- Code: Select all Expand view RUN
FUNCTION modifyXBrowseFooterPopupMenu()
LOCAL oPopupMenu AS Object
oPopupMenu := XBROWSE.GetFooterPopupMenu()
oPopupMenu.AddItem("Custom Item 1", "customFunction1()")
oPopupMenu.AddSeparator()
oPopupMenu.AddItem("Custom Item 2", "customFunction2()")
oPopupMenu.AddSeparator()
oPopupMenu.AddItem("Custom Item 3", "customFunction3()")
RETURN NIL
FUNCTION customFunction1()
// Add custom code for Custom Item 1 here
RETURN NIL
FUNCTION customFunction2()
// Add custom code for Custom Item 2 here
RETURN NIL
FUNCTION customFunction3()
// Add custom code for Custom Item 3 here
RETURN NIL
I have to admit it looks pretty legit but this is obviously not going to work.
Can someone suggest the "real" solution?
Thank you.