Categories | Question details Back To List | ||
multi select use to Click&Drag Hi! generally, multi-select use to Ctrl or shift key. but I want make multi-select use to Mouse Click or Click&Drag. check this out. http://leeyc09.x-y.net/1.jpg I wanna this http://leeyc09.x-y.net/2.jpg Are you understand? how to do this? use enableBlockSelection method? I need you are advice. Thx you. P.s : I have dhtmlxSuite 2008 Rel.2 Professional edition build 80512 -attach source- ------------------------------------------------------------------------------------------------- this is Configuration from XML page ------------------------------------------------------------------------------------------------- <!--conf <sample in_favorites="false"> <product version="1.4" edition="std"/> <modifications> <modified date="070101"/> </modifications> </sample> --> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>Configuration from XML</title> </head> <body> <link rel='STYLESHEET' type='text/css' href='../common/style.css'> <table cellspacing="0" cellpadding="0" class="sample_header" border="0"> <tr valign="middle"> <!-- COMPONENT ICON --> <td width="40" align="center"><img src="../common/dhtmlxgrid_icon.gif" border="0"></td> <!-- COMPONENT NAME --> <td width="120" align="left">Sample: dhtmlxGrid</td> <!-- SAMPLE TITLE --> <td width="0" align="left"><b>Configuration from XML</b></td> <!-- LINK TO COMPONENT PAGE --> <td width="0" align="right"><a href="http://www.dhtmlx.com/docs/products/dhtmlxGrid/index.shtml">dhtmlxGrid main page</a></td> <!-- CLOSE BUTTON --> <td width="50"><div class="sample_close"><a href="javascript:void(0);" onclick="self.close();"><img src="../common/sample_close.gif" width="14" height="14" border="0" alt="X"></a></div></td> </tr> </table> <link rel="STYLESHEET" type="text/css" href="../../codebase/dhtmlxgrid.css"> <script src="../../codebase/dhtmlxcommon.js"></script> <script src="../../codebase/dhtmlxgrid.js"></script> <script src="../../codebase/dhtmlxgridcell.js"></script> <script src="../../codebase/ext/dhtmlxgrid_selection.js"></script> <script src="../../codebase/ext/dhtmlxgrid_nxml.js"></script> <table width="600"> <tr> <td> <div id="gridbox" width="100%" height="250px" style="background-color:white;"></div> </td> </tr> <tr> <td> </td> </tr> </table> <script> mygrid = new dhtmlXGridObject('gridbox'); mygrid.setImagePath("../../codebase/imgs/"); mygrid.loadXML("gridH.xml"); mygrid.enableBlockSelection(); </script> <!-- FOOTER --> <table callspacing="0" cellpadding="0" border="0" class="sample_footer"><tr><td style="padding-left: 8px;">© <a href="http://www.dhtmlx.com">DHTMLX LTD</a>. All rights reserved</td></tr></table> <!-- FOOTER --> </body> </html> Answer posted by Support on Aug 04, 2008 06:25 There is no way to achieve such functionality through API. While first part - multiselection by click can be achieved with pretty small code modificaiton. Second scenario will require a complex coding. Multi-selection , by single click dhtmlxgrid.js, line 1091 if (this.selMultiRows != false){ if (ev.shiftKey&&this.row != null){ can be replaced with if (this.selMultiRows != false){ selMethod=2; if (ev.shiftKey&&this.row != null){ |