-
November 14th, 2020, 19:51 #1
Bug with CoreRPG 3.3.12 Column List onInit()
Hi,
Been having a problem in the Mongoose Traveller ruleset, that some of the 'Padlocks' are appearing on Reference Sheets as Red (correct) yet '_iedit' buttons attached to lists on the sheet are appearing when they shouldn't.
In the CoreRPG code 'common/scripts/column_list.lua' at the top on the onInit(), I've modified it to include debug comments.
Code:function onInit() Debug.console('CoreRPG here') if isReadOnly() then self.update(true); else local node = getDatabaseNode(); if not node or node.isReadOnly() then Debug.console('CoreRPG here3') self.update(true); Debug.console('CoreRPG here3.1') end end Debug.console('CoreRPG here4') end function isEmpty() return (getWindowCount() == 0); end function update(bReadOnly, bForceHide) Debug.console('CoreRPG update', bReadOnly) Debug.console('CoreRPG update', bForceHide)
However on inspecting the value of `bReadOnly` parameter in the 'update' function, it's been received as 'nil'.
Runtime Notice: Host session started
Runtime Notice: s'CoreRPG here'
Runtime Notice: s'CoreRPG here3'
Runtime Notice: s'CoreRPG update' | nil
Runtime Notice: s'CoreRPG update' | nil
Runtime Notice: s'CoreRPG here3.1'
Runtime Notice: s'CoreRPG here4'
Cheers,
MBMRuleset and much more content built for FGU.
Come join me on Twitter at: https://twitter.com/MadBeardMan to see what I'm up to!
-
November 15th, 2020, 19:18 #2
Supreme Deity
- Join Date
- Mar 2007
- Posts
- 20,611
I just modified by CoreRPG column_list.lua file to the following code; and got the attached messages when opening a record that used list_column template.
Code:function onInit() Debug.chat("ON INIT START"); if isReadOnly() then self.update(true); else local node = getDatabaseNode(); if not node or node.isReadOnly() then Debug.chat("IS READ ONLY INIT 1"); self.update(true); Debug.chat("IS READ ONLY INIT 2"); end end Debug.chat("ON INIT END"); end function isEmpty() return (getWindowCount() == 0); end function update(bReadOnly, bForceHide) Debug.chat("UPDATE", bReadOnly, bForceHide);
Regards,
JPG
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks