Help

Re: Scripting Problem with Input Variables

3464 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Rose_Haft1
8 - Airtable Astronomer
8 - Airtable Astronomer

Hi there - When I copy and paste the sample code for my input configuration, I am receiving this error and the code won’t run.

‘iv_UpdateStatus’ does not exist on type ‘{}’.(2339)

Any suggestions on what could be wrong? Or how to fix it?

23 Replies 23

I agree.

I don’t think that I am speculating that much. Rose has stated that she simply copied the code from the sample and did not add or alter the code. She shows the sample in the screen capture, along with the copy button. I have also used that copy button with no ill effects or weird characters.

I believe that she has shared the entirety of the code in the screen capture. You can see it twice: once in the code editor and again in the documentation.

I hate editing text with invisible characters. You may be right that it is an issue of hidden characters. But I still doubt that it is an issue of quote characters copy/pasting incorrectly.

I agree that the solution will probably be something simple and likely remedied in minutes. However, I’m not so sure that the cause will ever be determined.

Hi @kuovonne and @bill.french -

Below is the code. The ‘it won’t run’ is coming from the blue Test button being greyed out.

There is an error in the variables box (red suiggly line) with some of the variables but not all of them. Are there rules about what the variables can and cannot contain?

let inputConfig = input.config();

console.log(The value of iv_date_created is ${inputConfig.iv_date_created});

console.log(The value of iv_NameModified is ${inputConfig.iv_NameModified});

console.log(The value of iv_UpdateAssignedTo is ${inputConfig.iv_UpdateAssignedTo});

console.log(The value of iv_UpdateDueDate is ${inputConfig.iv_UpdateDueDate});

console.log(The value of iv_UpdateDoDate is ${inputConfig.iv_UpdateDoDate});

console.log(The value of iv_UpdateStatus is ${inputConfig.iv_UpdateStatus});

Have you retested every step of the automation in order, starting from the trigger?

@Bill.French and @kuovonne - Is it possible that there is an error because it’s a time variable?

I am not sure what the limits of the input variables are.

I deleted all but one variable, and re-copied and pasted to simplify. When else have you seen this be problematic?

image

Can you show a screen capture of the automation configuration page that shows the trigger and all of the steps in the automation?

Can you also please answer the question regarding retesting all of the steps in the automation? (And if you have not retested all of the steps in the automation, can you please do so?)

Thanks. One of the challenges with script automations that lean on historical process steps is that those steps are blind to the troubleshooter. Perhaps you should create a base that includes a sample record such that the complete process can be reviewed. Then share it to @kuovonne.

With that, a snapshot of the contents of the inputConfig object would also be really helpful because it appears you are referencing input elements that simply don’t exist.

@Bill.French I see two issues here, and it isn’t clear if they are related or not.

  1. The script will not run. This probably has nothing to do with the code itself.
  2. The editor is complaining that inputConfig is missing some properties.

In my experience the two issues are not related.

Here is the sample base: Sign up - Airtable

The flow is:

Name field is updated
Last modified time field is updated
Automation runs

The automation is not running for the time update nor the name update on their own and also not together.

Thanks in advance for your help.

Runs fine for me -

image

Enabled the automation in the base, changed the name field - ran as expected -

image