Search Results for 'script'
-
Search Results
-
Topic: Script on a Field
Hello All. Im new to Tap Forms but am an experienced software developer. I can not get a script attached to a fied to execute. I put the same script at the form level and it executes perfectly when I click ‘run script’ Im using iOS on iPhone 13 latest OS and V5 of Tap Forms
Simple Form
Field1 Text
Fiedl2 number
Total1 -Script field
Total2 Number (to hold the calculated total)I have the script attached to Total1.
Basically gets the Field ID of Field2 (using the getID from the field list dialogue), does a var total = form.getTotalAllFields(field2_id) ,
does, setFieldValud(total2_id,total), I have both form.saveAllChanges and document.saveAllChanges. I also return total from the function.
As I mention this script runs perfect from the form object.I know there is a simple answer but I can not figure it out. I have tried all the suggestions I have found but none are working for me.
Thanks for any help.Topic: Script to Add File Alias?
First of all, thank you for this excellent program.
I have a form with a lot of records: 10 years, day by day, one photo per day. At the moment I prefer that the images are outside of Tap Forms, and now they are, as an alias, in a “web-website” field.
I’m new to Javascript and I’m trying – probably wrongly – to copy the link in the “web-website” field to a “File-Attachment” field, with this script, trying in 2 ways:
function CC1 () {
// Get image-link-from-web-field
let image_id = 'fld-8f9c8612cbc04ebfb422576213cebf74';
let image_link = record.getFieldValue (image_id);// way A - Copy to file-attach-field-as an alias
record.addFileFromUrlToField (image_link, 'fld-05f12a9a7da74079b354a02e7c5bb305');// way B - Copy to file-attach-field-as an alias
//record.setFieldValue('fld-05f12a9a7da74079b354a02e7c5bb305 ', image_link);form.saveAllChanges ();
}
CC1 ();
What am I trying to do is possible? Or should it be done manually by clicking “Add File Alias”icon?
Thanks a lot! Ricard Casals
I have an iMac and a Macbook. Something went wrong in my database a couple of months ago and I only noticed it this morning. A form with scripts had been erased. Anyway, I had a backup and was able to restore it on my iMac.
But before proceeding, I inactivated syncing, deleted the iCloud syncing data from my iMac. Turned off syncing on my Macbook too (from Tapforms) and deleted the local copy.
At this point, my database is on my iMac. I re-enabled syncing. I saw that the last upload date and time was corresponding to when I re-enabled syncing, after a couple minutes. So, on iCloud, it would seem that all is good.
On my Macbook, my database won’t sync fully. When I launched Tapforms, my database appeared with a cloud sync icon. When I try to open it, it shows an empty database. I’ve been patient, waited a long time, closed the database and waited, but the file never goes over 2.6 mb in the Finder. The real file size is 154 mb (or close to).
What else can I do to get my database from my iMac to my Macbook.
Note : I know the database is on iCloud sync because on Tapforms for iPhone, the database is all there, up to date.
Thanks,
Ray