Search Results for 'script'
-
Search Results
-
Is it possible for a JavaScript script to read the iOS clipboard?
I like to quickly note new entries in plain text in other apps (e.g. Drafts). I know there isn’t a full Tap Forms URL scheme at the moment, but the ability to run a form script that creates a record from the clipboard contents would be fantastic.
I hope it is possible,
Martin
Ps Setting the clipboard too would be great to send data to other apps, but that is of lesser importanceYou helped me with an earlier question about my TapForms database and now I have another question. I have this main/major/parent form that is a list of members, artists and interested people of our nonprofit arts organization which contains contact information and other stuff imported from an old filemakerpro database when we first started using TapForms in May of 2018.
I created a new form that is a record of memberships and donations some people in this list have paid. There is a linked field in the parent form showing the data/amounts they have paid, dates they paid, type of payment, check number, etc. There is also an “inverse relationship” field in the memberships and donations table/form that brings in the phone number and email and company name, etc. from the parent form so we can see more information about who paid. This is nice. Works fine.
I had asked you in an earlier question about changing the type of relationship link in the parent form and I understand your answer but have not changed the type of link yet. I am putting it off to ask this NEW question.
Sometimes I want to search in the parent form for a person who has paid between certain dates, or paid a certain amount and it is impossible because the data in the linked field, which is a table when viewing the form, is not visible in the list of fields that I can search on.
Also, I recently created a yet another child form/table of items in a specific event (a gallery show of artists’ work) that were submitted by some of the people/artists in the parent list, about 55 items (sometimes one person has submitted more than one item). There is a linked field in the parent form where we can enter the item numbers and specifics about the items submitted by the artists, and there is an “inverse relationship” field in the item list showing the artist name and company and address from the parent form (or whatever I choose to show). All works fine, I was able to create a price list of the items and we have been able to adjust things just fine. Beautiful.
However, just like the above mentioned impossibility, if I want to search in the item list for information about the artists who have submitted items, that is impossible because none of the artist information is visible in the search. I realize I can search and find items in the form showing the artist information and can go to that individual record with the little arrow, one by one, but that is rather tedious.
I read about how you were going to add some javascript capability (I do not write javascript myself at all) and I was wondering if this new functionality would make it possible to do what I want to do, and if so how and who could do it?
Is it going to be impossible forever or is there something simpler that I can do?
Thank you for the new update/upgrade(s), I love TapForms and love that you are keeping up with the Mac OS updates. I would love it more if I could do what I want to do.
Your fan,
Carol Jones
It’d be great to make this more of an IDE. You have some syntax color tagging, which is nice; but for example it’d be great to be able to re-indent a script to prettify it, and to be able to select a range and use TAB and SHIFT-TAB to indent and de-indent a block.
The mechanism for referencing fields by “ID” is also awkward, especially since the only way to get the ID is to use a button that inserts a complete assignment statement. At the very least, a lookup function that takes a field name and returns the ID would make this a bit easier to work with; and also make the script a lot easier to read.
(And, by the way, in case it’s not obvious, I think this addition is an amazing idea.)
Topic: Javascript field question
What I initially expected doesn’t seem to be the way it works, or maybe I just can’t figure it out.
You’ve got both “field” and “form” scripts. The documentation even hints at “field” scripts as an extension of the spreadsheet-like calculation fields; but I wasn’t able to figure out how to set a value for the script field. In a spreadsheet, each cell has both a “formula” and a “value”, and that’s how your calculation fields work as well, but the Javascript fields don’t appear to work that way. The sidebar won’t even let me find a field ID for the script field, so if it’s possible there has to be some trick to it; and simply returning the desired value doesn’t appear to do anything. Is this possible, or do I really need to define both a script field and a value field where the script stores the result?
I also found out that the field script runs only when the record is saved, so adding a “compute total” calculation script field didn’t update the “total” column until I manually modified each record. A simple adaptation in the form of a form script that iterated through the records took care of that … but is it possible to make a form script that iterates over the records and directly calls a script in each record instead of duplicating the code?
Topic: V5.3 Manual
How do I access the new manual.
“New Tap Forms 5.3 manual, including a section on the JavaScript API you can use to write scripts to read and manipulate your records.”
Ron