' 'Class Description: ' !short:ABrowse Class structure: Class ABrowse: ~~~~~~~~~~~~~~~ It adopts the class Browse for editation of clipper arrray as a table. Common use: ~~~~~~~~~~~~~~~~~ LOCAL OBJECT Ar OF ABrowse //-object is created AAdd(Ar:Arr,{"field1.1","field1.2","field1.3"}} //we create AAdd(Ar:Arr,{"field1.2","field2.2","field2.3"}} //a sample aray AAdd(Ar:Arr,{"field1.3","field3.2","field3.3"}} //for editation Ar:Init() //object is initialised As all classes derived from class Task, this class doesn't need methods Process() and Done() to be run. The initialisation adds new object of this class on the top of stack of classes and following is job for task-swapper (method Process() of class Task) Source text of class Abrowse is in the file C_ABrows.prg !seealso: c_browse.ngo:Browse c_task.ngo:Task c_box.ngo:Box c_upabro.ngo:UpABrowse c_dbrows.ngo:DBrowse c_color.ngo:Color ob_class.ngo:"Class hierarchy" !short:~~~~~~~~~~~~~~~~~~~~~~~~~ !short:create class ABrowse from Browse !short: export: !short: var N //1 ^BABrowse:N^N: public: numeric This instvar variable serves for array ABrowse:Arr in the same way as clipper function RecNo() for any database i.e. as pointer of current line in display table of this class. (Look at class Browse). !short: var Arr //{} ^BABrowse:Arr^N: public: array This is an array which represents table for view or editation. !short: method New=ABrowseNew //o:New() --> self ^BABrowse:New()^N: public: return self It fills the object with default initialising values. Following predcessor variables are modified: ^UABrowse:CanSwap^N: override: private: logical Default true value from inherited class Browse is overriden to new default value false. It restricts switching from Browse to Form. ^UABrowse:InsBlock^N: override: private: code_block Own method of new line input to table for array editation is defined. This is because adding items to an array differs from adding records to database. ^UABrowse:DelBlock^N: override: private: code_block For array editation defines own method of deleting of table line. !short: method Init=ABrowseInit //o:Init(Name,R,C,Rs,Cs,Clr,Shd) --> true/false ^BABrowse:Init(Name,R,C,Rs,Cs,Clr,Shadow)^N: public: return true Object is initialised, all parameters are not obligatory, when used are transmitted to predcessor method Box:GoodInit(...). For exact parameter description look at class ^Ubox^ method ^UGoodInit(...)^N. !short: endclass