| **Navigation:**  [[abc library reference.htm|ABC Library Reference]] > ViewManager > ViewManager Methods >====== Init (initialize the ViewManager object) {{c6h0009.jpg|C6H0009.jpg}} ====== | [[getfreeelementposition return free key element position .htm|{{btn_prev_n.gif|Previous page}}]][[abc library reference.htm|{{btn_home_n.gif|Return to chapter overview}}]][[kill shut down the viewmanager object .htm|{{btn_next_n.gif|Next page}}]] | | || **Init(**// view, primaryrelation //[,// order //]// //**)** {{blk2blue.jpg|blk2blue.jpg}} | **Init** | Initializes the ViewManager object. | | //view// | The label of the managed VIEW. | | //primaryrelation// | The label of the RelationManager object for the //view//'s primary file. | | //order// | A structure containing the sort, range limit, and filter information for the managed VIEW. If omitted, the Init method supplies an empty SortOrder structure that may be set up with AddSortOrder, AppendOrder, SetOrder, AddRange, and SetFilter methods. | The **Init **method initializes the ViewManager object. **Implementation:** The Init method sets the values of the Order, PagesAhead, PagesBehind, PageSize, Primary, and View properties. The //order //parameter allows derived classes, such as the BrowseClass, to add additional sort information to their underlying views. By passing the Order property from another ViewManager object or the Sort property from a BrowseClass object as the //order //parameter, you can implement several objects with similar sorts, filters, and range limits. **Example:** ** MyView.Init(OrderView,Relate:Order)   !initialize the ViewManager** ** MyView.Open                           !open the view** ** !program code** ** MyView.Close                          !close the view** ** MyView.Kill                           !shut down the ViewManager ** **See Also:**     [[order sort range limit and filter information .htm|Order]], [[primary the primary file relationmanager .htm|Primary]], [[view the managed view .htm|View]], [[pagesahead buffered pages .htm|PagesAhead]], [[pagesbehind buffered pages .htm|PagesBehind]], [[pagesize buffer page size .htm|PageSize]]