Search Results for 'script'
-
Search Results
-
Hello
My databases were imported from Bento. I have a rating field in most of my forms which are all 0-5 stars, because that is what Bento provided. I would like to make them 0-10 stars which I can do in Tap Forms but this means changing all the existing values: I have thousands of records.
Is there a way to automatically double the ratings value in all records please? I have looked at scripts and at this forum but can’t find anything obvious that would do it. The closest I could manage was to make a new calculation field that takes the existing rating and doubles it. However, this does not allow me to enter data directly so it would not enable me to have a rating of say 7 because I can’t enter 3.5 in the original.
Many thanks
Andy
Hi Brendan,
I try to assign the current date to a field using a script.
First try:
theRec.setFieldValue(date_sold_id, Date());
Doesn’t show anything. If I change date_sold to a text field it works. Then I tried to get the date number:
theRec.setFieldValue(date_sold_id, Date.parse(Date()));
Doesn’t work either. But something like this works:
theRec.setFieldValue(date_sold_id, theRec.getFieldValue(date_modified_id));
When using a script, how can I assign the current date to a field? Thanks!
— Daniel
Cheers, Daniel
---
See https://lab.danielleu.com/tapformspro/ for scripts and tips&tricksTopic: Pasting records in iOS
Hi,
I’m still trying to think of ideas to get from drafts app to Tap Forms.
I recently asked if the Tap Forms JavaScript had access to the clipboard (think of using that as the communications channel), but it hasn’t.
I am now wondering if it is possible to paste records into the iOS version? I could make a drafts action create the correct format for the paste.
Thanks
Martin
Topic: Cloudant Password
Hi y’all,
Am trying to use cloudant for syncing my database. Have followed the instruction re setting up an account, but I’m not sure where to find the password.
This is the alphabet soup I get from the “credentials” on the cloudant site:
{
“apikey”: “1ZQdMj162xdk3vf4N0ZMkQAhN4oikS2z5-xCd-SXAAIX”,
“iam_apikey_description”: “Auto generated apikey during resource-key operation for Instance – crn:v1:bluemix:public:cloudantnosqldb:eu-gb:a/6573add2f18f4d48b22620fd392dd094:32191e04-2a8b-4bbe-bc54-bff77190292f::”,
“iam_apikey_name”: “auto-generated-apikey-36ca775e-c28c-425c-bf55-4f5754841a8a”,
“iam_role_crn”: “crn:v1:bluemix:public:iam::::serviceRole:Manager”,
“iam_serviceid_crn”: “crn:v1:bluemix:public:iam-identity::a/6573add2f18f4d48b22620fd392dd094::serviceid:ServiceId-2432e2f3-f9ba-4cc1-be44-15a42d4bc426”,
“url”: “https://2dc42a4a-07a3-405f-91f6-66fbe35a4cdd-bluemix.cloudant.com”,
“username”: “2dc42a4a-07a3-405f-91f6-66fbe35a4cdd-bluemix”
}The username is pretty apparent, but I have no idea what the password is. Can anyone help?
Many thanks in advance.
I created a mileage tracker form but posted it in the regular forum. Figured I should post it here for everyone to download. It requires Tap Forms 5.3 at a minimum because it uses JavaScript to copy the previous mileage value to a new record. You need to select a record and then run the script. Tap Forms will create a new record and copy over the values from the selected record to the new record.
Use the Import Tap Forms Archive function to import this file.
Thanks!
Brendan
Hi
I have the parent database “Photo Database” with the child “Photo Prints”. The child database is used to keep track of all prints created and sold. In there, I would like to include some basic information from the parent database such as image title.
In the parent database I set the one-to-many link and enabled show inverse relationship. Then in the child database I created a field with the type ‘script’ containing
var image_title = photo_database.getFieldValue('fld-a64a1b71aeb8408499143d9c852b0056');
image_title;
But when I run it, following error:
ReferenceError: Can't find variable: photo_database, column:33, line:1
I guess I’m missing something to define photo_database which is the parent “Photo Database”. Attached is the sample template. Thank you for your help!
– Daniel
Cheers, Daniel
---
See https://lab.danielleu.com/tapformspro/ for scripts and tips&tricks