2015년 1월 6일 화요일

Please enter a vaild order

I have the table id, keyfile and service account email

I have tried to combine the party pizza app with the how to use the serviceaccount. 

on the emulator which has been updated the submit button doesnt work if i add a name and a comment.  If i leave these two out and press submit i get "Please enter a valid order'

i have attached screen shoots








in the initialize event you still assign the keyfile to the webviewer.HomeUrl, that obviously will not work...compare again with the example here

 the submit button doesnt work if i add a name and a comment.  

check your if statement in the ButtonSubmit.click event




I have checked over the if statement in the ButtonSubmit.click event.

It is exactly as the example in the party pizza tutorial



use Do it to debug your blocks, in your case the values in your if statement...



hi  I can not figure it out, how to make this statement with the button submit

Do It

You can perform the action for a block with Do It . In debugging a program like MoleMash, you could select Do It for MoveMole and see if the mole moves on the phone.
Do It not only does the block's action, but also puts up a balloon that shows the value returned. The figure below shows the use of Do It on an addition block to show the result of addding two numbers called this and that .

Result balloons are attached to blocks at a point indicated by a small equals sign. You can click on the equals sign to hide and show the result. Moving the mouse away from the block makes the result balloon go away.  



see tip 4 here

Top 5 Tips: How to learn  App Inventor




I did manage to find the function on a mac. it didnt change. please see attach im still getting the error sign.... Secondly, is it possible to Re-name the Screen1





Please see attachment with DO IT string

Will app work... it seems to work with just one screen when i add another it does not function




as already said earlier, in the initialize event you still assign the keyfile to the webviewer.HomeUrl, that obviously will not work...



do you remember: you already mentioned the same problem in your other thread https://groups.google.com/d/msg/mitappinventortest/t7tOrtMOPYE/M9Id0OqpWcMJ
do it step by step and fix that issue first before continuing

this is wrong


this is correct



please see attach 

it just not working




I already asked this in your other thread but probably I misunderstood your answer?
did the example (see link) work for you?

How to use the Service account option to connect to a Fusion TablesFusiontable




the problem in the end was 
1. you forgot the space after INSERT INTO
2. you wrote "Tyre Width" without underscore instead of Tyre_Width for that column name

unfortunately the error message does not help at all in this case for the service account method... remember the error message is just "Error" (see screenshot)...

for the API key method, the error message would be something like this "400 Bad Request Invalid query: Parse error near 'INTO..." @MIT: could you change that and provide a better error message for the service account method, too?




If possible, could you generate a and send a simple example that exhibits  this problem?    All App Inventor is doing here is passing along an error message that came back from a lower level module, so it would be good to have a clear repeatable error before I ask someone to dig into this.



you can use the attached simple example, just modify the select statement to get an invalid query and remove for example the space after FROM to get the "Error" result
Taifun




댓글 없음:

댓글 쓰기