Stuck in "First App" - step 9, binding form to grid

Hi,

I’ve downloaded the dhtmlx library v.4.0.1 Standard edition to give it a try, and are making my way through the “your first app” tutorial.
I get stuck in step in step 9, with the call to “contactForm.bind(contactsGrid);”
I get the error “Object # has no method ‘bind’”.

My script includes are:

Since I include all of dhtmlx, I don’t need to load datastore.js directly, is that correct?

In the library I downloaded, the dhtmlxDataStore/codebase folder is empty. So if I do need to load it, where do I find it?

Hi
Sorry, we will fix it in the next update.

Thanks for notifying on this, I thought I was alone. Apparently this was not the case with ‘dhtmlxSuite 2013 Rel.1 (DHTMLX 3.6) Standard edition build 131108’ too.

As we wait for the update, this is the walk around I have used on DHTMLX 4.02. A bit long but it worked for me.

  1. Disable the binding by commenting //contactForm.bind(contactsGrid);

  2. Introduce a form connector file - ‘dataform.php’

<?php session_start(); require_once("../includes/db_config.php"); //your data connection configuration file require_once("../codebase/connector/form_connector.php"); $conn = new FormConnector($mysqli,"MySQLi"); $conn->render_table("contacts","contact_id","fname,lname,email"); ?>
  1. Set the transaction mode to POST just before grids initialization
    dpg.setTransactionMode(“POST”,true);

  2. Insert the onRowSelect event contactsGrid just after the grids initialization -dpg.init(contactsGrid);
    contactsGrid.attachEvent(“onRowSelect”, function(rID,cInd){
    contactForm.load(“controller/dataform.php?id=”+rID);
    });

Hope it helps, I am also waiting for the fix. Otherwise this is one of the greatest tools I have ever used. :sunglasses: