Coding the blocks – requesting data

The first code that we need to program is to request data from the Fusion Table. Click on GuestList_Screen in the Blocks drawer and drag the when GuestList_Screen.Initialize event. This event is automatically triggered whenever a screen is launched. We want to request data from the Fusion Table when the GuestList screen is launched. Thus, we will add to this event is the call FusiontablesControl1.GetRows block. This block will let us request data from the Fusion Table. You can find this block in the FusiontablesControl1 blocks drawer. The GetRows block needs two pieces of information to fetch rows from Fusion Tables: the ID of the table and name of the column. We identified the table ID when we were creating the Fusion Table. Paste that ID into the tableId socket of the GetRows block using a Text block. Use another Text block to specify the column name, 'Guest Names'. Note the single quotes; just like in the InsertRows block, the column names have to be single-quoted here as well. The following screenshot shows the completed set of blocks:

Coding the blocks – requesting data
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset