Categories | Question details Back To List | ||
dhtmlXGrid scrollbars problem & about excell and ext -includes for extending functionality Hello, I have the following code to setup my dhtmlXGrid: ------- <link rel="stylesheet" type="text/css" href="dhtmlxGrid/codebase/dhtmlxgrid.css"> <link rel="stylesheet" type="text/css" href="dhtmlxGrid/codebase/dhtmlxgrid_skins.css"> <script type="text/javascript" src="dhtmlxGrid/codebase/dhtmlxgrid.js"></script> <script type="text/javascript" src="dhtmlxGrid/codebase/dhtmlxgridcell.js"></script> <script type="text/javascript" src="dhtmlxGrid/codebase/excells/dhtmlxgrid_excell_liveedit.js"></script> <script type="text/javascript" src="dhtmlxGrid/codebase/excells/dhtmlxgrid_excell_grid.js"></script> <div id="rawDataGrid" style="height:300px;width:100%;"></div> mygrid = new dhtmlXGridObject("rawDataGrid"); mygrid.setImagePath("<%=VisitBean.getDhtmlxRoot() %>dhtmlXGrid/codebase/imgs/"); mygrid.setSkin("modern"); mygrid.setEditable(true); mygrid.init(); mygrid.loadXML("xml/rawDataGridXML.jsp"); ------- Everything works nicely so far (including XML loading, editing only certain columns and so on), except that the vertical scrollbar does not appear if the grid reaches beyond the height of element rawDataGrid. How do I get scrollbars. Also I would like to know where there is a guide to explain all the includes needed for certain functionality? I am looking at this document and can not find all of the explanations: http://www.dhtmlx.com/docs/products/dhtmlxGrid/doc/guide.html#grid_confxml What I would like to achieve (and therefore have correct includes for) is the following: 1. use either XML or JSON (I understand it is faster to process) to configure the grid as far as possible without involving separate javascript conf commands to the grid. So far this is working nicely. 2. be able to separate certain columns for editing, and lock some of them. So far this works as well. 3. have one column as an integer field which editable, with integer-only input validation. 4. have another column as a timestamp (yyyy-mm-dd hh:mm:ss) field, which would then have a way to reset the hh:mm:ss part to 00:00:00. This could be a button, link, or context menu whichever way works best. Which is the easiest way? 5. possibly the timestamp column could have a calendar selector instead, although I am not sure how that applies to the hh:mm:ss part of the timestamp? Thank you in advance for the answers, you can also contact me at tapani(dot)jalonen(at)visit(dot)fi. We have purchased the professional Suite package. Answer posted by Support on Nov 21, 2008 06:27 >>How do I get scrollbars. scrollbars must appear automatically, there is no any additional code need to be executed to enable them. >>Also I would like to know where there is a guide to explain all the includes needed for certain functionality? For normal functionality you need to have dhtmlxcommon.js dhtmlxgrid.js dhtmlxgridcell.js The API reference contains names of used js files for each method http://dhtmlx.com/docs/products/dhtmlxGrid/doc/alpha.html#grid_api_a You can use full dhtmlx.js included in suit package, or libCompiler from the package to make custom build. >>1. use either XML or JSON (I understand it is faster to process) Loading data from JSON may be about 5-10% faster, than from XML, but full configuration ( loading grid structrure and settings ) only possible for XML format. >>3. have one column as an integer field which editable, with integer-only input validation. There is no built-in validators, but you can use onEditCell event to check value and regect or correct it in necessary way. >>4. have another column as a timestamp (yyyy-mm-dd hh:mm:ss) field Can be done through custom excell http://dhtmlx.com/docs/products/dhtmlxGrid/doc/articles/Custom_excell_creation.html#grid_cexc or you can use inline HTML ( which may contain custom button or any other elements ) >>5. possibly the timestamp column could have a calendar selector instead, In current version calendar able to select date only, there is no possibility for time creation. for all above (1)-(5) , you need not any additional js files, except 3 core ones. |