//TH-Header //***************************************************************************************** // Copyright (c) 2014 KURANT Project // All rights reserved. // // $FileName : selclass.dg // $ProjectName : The Hammer 2.0 // $Authors : Wil van Antwerpen, Michael Kurz, Sergey V. Natarov, Bernhard Ponemayr // $Created : 01.25.2014 01:08 // $Type : LGPL // // Contents: Select Class to generate // //***************************************************************************************** //TH-RevisionStart //TH-RevisionEnd // Project Object Structure // oSelectClass is a zf_dbModalPanel // oClass_grid is a Grid // oOk_btn is a Button // oCancel_btn is a Button // Register all objects Register_Object oClass_grid Register_Object oCancel_btn Register_Object oOk_btn Register_Object oSelectClass Use DFAllEnt.pkg Object oSelectClass is a dbModalPanel Set Label to "Select Class to Generate" Set Size to 102 240 Set Location to 9 11 Object oClass_grid Is A List Set Size to 70 165 Set Location to 6 9 procedure fill_list integer hArr iCount iItem iMax string sStr get oClass_Array to hArr send delete_data move ((item_count(hArr)/2)-1) to iMax for iCount from 0 to iMax move (iCount*2) to iItem get string_value of hArr item iItem to sStr send add_item 0 sStr loop end_procedure On_Key kCancel Send Close_Panel End_object Object oOk_btn is a Button Set Label to "OK" Set Default_State to TRUE Set Location to 6 179 Procedure OnClick integer ho get oclass_grid to ho send pShowSetClass to (oSetupClass(self)) (value(ho,current_item(ho))) End_Procedure // OnClick End_Object // oOk_btn Object oCancel_btn is a Button Set Label to "Cancel" Set Location to 24 179 Procedure OnClick send close_panel End_Procedure // OnClick End_Object // oCancel_btn Procedure pShowSelectClass send fill_list to (oClass_grid(self)) set select_state of (oClass_grid(self)) item 0 to true send popup_modal End_Procedure End_Object // oSelectClass