Tap Forms – Organizer Database App for Mac, iPhone, and iPad › Forums › Using Tap Forms › testing scripts
- This topic has 14 replies, 2 voices, and was last updated 1 year, 1 month ago by Glen Forister.
-
AuthorPosts
-
September 12, 2023 at 4:11 PM #49827
Glen ForisterParticipantI want to test a script, but not in my original form.
How do I make a copy of my form with just a few or all of the records so I can test something?
I’ve tried saving an archive of the form and changing the name on it and importing it, but it just disappears – were the empty records imported into the current form from which it came???
I’ve tried making a copy of the form, but that form is empty. How do I get some data into the copy form without making up stupid data with a lot of work?
What is the best procedure here?
September 12, 2023 at 4:44 PM #49828
BrendanKeymasterHi Glen,
The Tap Forms Archive method is the way to go. But don’t rename the file as that will have no affect. The form name is embedded within the .tfarc file.
Instead, create a new document, then import the archive into that document. When you import an archive into the same place from whence it came, you will simply be updating the records that are already in that form.
It’s really useful if you want to make changes to a form and send it to someone else multiple times. Perhaps to update a form you shared with them at some prior time that you added to. They could then import the updated changes.
Thanks!
Brendan
September 12, 2023 at 6:23 PM #49830
Glen ForisterParticipantTried and failed several times until I suddenly realized I was in a document with many forms which is where all my forms are. I guess I had to get out of that document of many forms and go to the top that holds only 2 dociments, samples and Home.
Made a new Form there without creating a new Document folder I guess. Then I was able to import the archive. I guess when I get my work done I can move it over my Home document to put it with my other forms I use?
September 12, 2023 at 6:31 PM #49831
BrendanKeymasterYes, you needed to exit the document from whence the form was exported and then make a new document (or open a different one is ok too), then import the archive.
But that form will forever be the same form as the original, even if you make changes to it. If you then export and import into your original document, you won’t get a new form. It’ll simply update the original form. So be careful and make sure that’s what you really want to do.
September 12, 2023 at 6:43 PM #49832
Glen ForisterParticipantHow do I create a form that is unique from importing an archive of another form into a new one so I can get it back into my working document?
September 13, 2023 at 3:01 PM #49835
BrendanKeymasterGet it back into your working document as a separate, new form? You’ll need to use the Export Records function to create a CSV file, but that’s not as comprehensive as a Tap Forms archive. And if you do go that route, make sure the Export Record IDs option is turned OFF. If you don’t, Tap Forms will just update the existing records when you re-import the CSV file.
Or you can just use the other document instead of having one document with all your forms in it. One organization technique is to separate forms based on topic into separate documents. For example, Personal, Work, Hobbies, Projects, and so on.
September 13, 2023 at 3:57 PM #49837
Glen ForisterParticipantComprehensive with an archive file sounds like the right way to go. Seems to work.
Question about organization. As I was doing this I was puzzled again by the fact there are 3 layers.
Document layer
Another layer with 3 items (My Forms, Matt, Sample Forms). What are these items called that are inside the document? Why this branching?I keep all 73 of my forms in “My Forms”. Don’t know what this folder is, but that is where I do all my work. I don’t want to have to go up 2 layers and then down 2 layers to look at a file or Form when it is so easy to see what I want in 1 sec.
I understand why the “Sample Forms” are separated, I don’t work with them, but are they really separated. Should they be another layer up and then 2 down to keep them separate as a backup? I remember this talked about in one of the documeents, but I didn’t get it then either.
Thanks.
September 14, 2023 at 10:37 AM #49840
BrendanKeymasterIf you’re at all familiar with Excel, you might know that Excel has something called Worksheets in it. You can have one Excel document with many worksheets inside it.
That’s the same way Tap Forms organizes things. The document is the file on disk that contains the database. The database contains forms. The forms contain your records. You can have as many document files as you like. Whatever makes sense to you. If you select a document and click on the Show in Finder button, you’ll see that it’s just a file on disk with a
.tapforms
file extension. It’s not actually a separate layer in the database. Each Tap Forms document file is its own separate database.If you were to use Excel in the same way you’re using Tap Forms, you would only have one Excel document with 73 worksheets inside it. That could get a bit unwieldy to manage I would suspect.
So Tap Forms allows you to split out forms into different documents, organized however you would like to organize them.
There is one other layer of organization in Tap Forms too, which I call Categories. They were basically a holdout from when Tap Forms only had a single database. You needed a way to organize personal forms separate from work forms, etc. So you could put a form inside of a Category to organize it. In Tap Forms 5 I created the ability for you to have separate documents. So categories are a little less important than they were. But can still come in handy.
In a new version of Tap Forms I’m working on, the Sample Forms document will no longer be included. I’ve written a new Template Library screen which will contain all of the forms you can install into any document you like. Right now you have to export a form from the Sample Forms document and then import that into your working documents. The new Template Library will be available to any document at all times without having to do the export/import dance.
October 20, 2023 at 4:27 PM #50013
Glen ForisterParticipantReading the above directions left me udecided what to do.
You say using the archive file method is the best and it would keep all the work I’ve done, but you say it will end up being the same document and can’t be moved to the same document the original came from because it would over write the original form.
Can you the detail steps required to use an archive file to make a copy of a Form, be able to modify that form in another document until the modifications are what I want, then bring it back into the original document (because it is the same subject as the original) with a different name.
Then after I have the original Form copied and worked on, I would need to move the data from the original Form into the newly named modified document so I can continue working in a new environment that I have created (which will take time to do) and the data will be out of date.
This is such a simple thing to want to do, yet it seems very difficult and prone to destruction of data if a mistake is made and there are various ways to make those mistakes without a step-by-step direction that anybody can use. The sentence format directions are very confusing, especially how you discuss 2 different methods.
Hope this isn’t an unreasonable request.
Tbanks.
October 20, 2023 at 6:06 PM #50014
BrendanKeymaster- Select a form in Document A.
- Export your form as a Tap Forms Archive (.tfarc) file by selecting Export Tap Forms Archive from the File menu.
- Create a new, empty Document B by selecting New Document from the File menu.
- Import your .tfarc file into Document B.
That’s really all there is to it.
The updating issue occurs when you want to then export your form from Document B and then re-import it into Document B.
Internally, even though the forms are in different documents, they both originated from the same place (Document A). So if you re-import that form into Document A, then it will simply apply whatever changes you made (except for deletes) to that same form in Document A.
You can duplicate a form within a single document and that becomes a brand new form not related to the original. But it won’t contain the data. Just the fields the form is made up of.
Hope that’s more clear.
Thanks,
Brendan
October 20, 2023 at 6:30 PM #50022
Glen ForisterParticipantSo, assume I copy a Form into the same document, that has no data.
Then I work on the form to get what I want ( much easier since the original is right there to compare quickly). Then I want the changes to the form I made to the copy. I would want to move that work to the original document.
How do I move the work I’ve done on the copy Form to the original Form without doing all the work all over again?
Now, in this process, if all goes wrong, does the archive of the original before changes revert it to the original condition?
October 21, 2023 at 10:48 PM #50030
BrendanKeymasterYou’d have to re-create the changes you made to the form copy on the original you copied it from.
A Tap Forms Archive contains in it the current state of the form template and all its data.
When you import a .tfarc file into a document that contains that form already, Tap Forms does a merge of the form with the archive. For example, if you renamed a field, then imported an archive that was made before you renamed the field, it would be renamed back. Or if you deleted a field, it would be re-created from the archive. But if you added a new field, it wouldn’t delete the added field when you imported the archive.
October 22, 2023 at 9:19 AM #50032
Glen ForisterParticipantOk, so really, the only safe way to create a copy to work on changing the Original Form, is:
1. Duplicate the Form.
2. Work on the changes wanted, including renaming fields, moving fields, adding fields and all the changes in properties required in the Duplicate Form.
3. Export data as a CSV file from the Original Form which you are still adding data to while work on the Duplicate Form was proceeding. Make sure the Export Record IDs option is turned OFF. If you don’t, Tap Forms will just update the existing records when you re-import the CSV file.
4. Import that data from the Original Form into the new Duplicate Form.
5. During the Import process, make sure the data in the old Form is directed to the correct field in the Duplicate Form. I haven’t done this much in TF, so I don’t know how much ability there is to make sure the previous is possible, but I’m sure you made that possible.
Thanks for clarifying the traps involved with the Archive file. Basically, don’t use it for this purpose or it will prove dangerous to you eventually.
Let me know if I’m correct or need to change something.
- This reply was modified 1 year, 2 months ago by Glen Forister.
October 22, 2023 at 5:53 PM #50034
BrendanKeymasterYup. That’s about right.
The Tap Forms Archive format is a great format to store your data in or to share forms with other people. But it’s not designed as a mechanism for duplicating a form and all of its data within the same document. Different documents yes. Just not the same document as the original form.
November 12, 2023 at 12:30 PM #50117
Glen ForisterParticipantI finally had the time to do the
Copy Form to a new Form in the same document.
I then made my changes in the copied Form and added 2 fields to hold the Java Scripts.I then Exported my revised data in the original Form into a CSV file.
I also had to rename a couple fields when I imported into a spreadsheet.
I also had to the data in one field.I then imported the altered CSV file into the new copied Form with the desired changes.
Unfortunately, the changes didn’t happen and the added records didn’t get imported.Basically nothing happened and the new Form didn’t get updated.
What is the correct process if it isn’t the one detailed above in the previous posting.
-
AuthorPosts
You must be logged in to reply to this topic.