Help

Simple Copy Record to Create New Record Script (Novice)

Topic Labels: Scripting extentions
1701 5
cancel
Showing results for 
Search instead for 
Did you mean: 
Drew_Nemer
8 - Airtable Astronomer
8 - Airtable Astronomer

Today is my first foray into scripting with AirTable and i feel like the best method of learning how to script is to figure out a use of it that would be easy and useful.

So i want to create a button that would copy certain fields and input them into a new row.

For instance, my company manages affordable housing vouchers and we want to keep track of units that do not work out, but the voucher recipient (potential tenant) will still be searching for a new unit.

Instead of rewriting over existing data, i wanted to make a button that would copy these fields:

Participant Name
Specialist Name
Action
Program
URL
NOTES

and input them into a new row with an updated STATUS of “Back OTC”. So we know that this person previously attempted to move into a unit, but that unit didn’t work out, now they are OTC (on the clock) to go find a new unit.

Does that make sense? i feel like making a button do this with a script should be a perfect way of getting my feet wet into scripting in general.

I appreciate anyone who is willing to walk me through this. :slightly_smiling_face:

5 Replies 5

Hi @Drew_Nemer ,
Lets postpone the button concept for now, we can come back to that once things are working.

Start, by installing the scripting app (I assume you already did that). Take a look at the Record Picker example and see if you can output all of the fields you listed. Then read up on the Cell Values and Field Options documentation. This should get you on the path to what you are looking for.

Feel free to post what you are working on and I can try to help. There is no single solution to this, your needs will be different from others needs.

This could be a good starter project, depending on your current experience with programming. If you already know JavaScript and can read the scripting documentation, you can probably learn quickly. But if you have not done any scripting/coding/programming, don’t be afraid to back up to smaller, incremental goals. ,

Unfortunately, i don’t know Javascript so maybe this is where my wall really is.

Are you interested in learning? If so, Airtable is a great place for building up coding skills.
If you’ve completely new to coding, you might want to start with a generic JavaScript beginner course
to learn basic things like variables, data types, assignment, branching/loops, functions, etc.
On the other hand, if you are comfortable with these basic programming concepts, you can start applying them to JavaScript and simple Airtable scripts by looking at the little examples in the documentation. (I don’t mean the full fledged example scripts in the documentation, but the little examples that are only a few lines long embedded into the documentation for specific functions.)

You don’t need to master the whole JS curriculum, the basic is enough for Airtable, I do JS development full-time and the scripting required for Airtable is quite minimal

Array, for loops and conditions. All the best