Add more variables to JavaScript column

Please add more variables to the JavaScript column… 3 is really way too little… I have to join and split all the time.

Why was JavaScript sad?

Because it didn’t know how to null its feelings.

2 Likes

I think there is no need for this as this can be done by the template column then you can lookup the code in the java script column as. Work around

??? Variables from columns… it is for comfort… now I have to join variables, then split them inside JavaScript… I have no idea what your point is.

You can build your whole code in the template column and just add it in the JavaScript in 1 variable, this will give you unlimited variables

Same as joining variables… I’m talking JavaScrip with more p1…p2…p3…p4…p5…p6… so when I’m working on script… I don’t have to adjust any other column… BTW are you suggesting for me to make a workaround? I’m a master of workaround… LOL… I requested a solution not to make workarounds… :wink:

One more thing… Glide has an excellent Java editor… if you have all your var feed… it will show you real live results without debugging and saving… You just type and watch… and maybe in the future, they will have some more advanced error notifications… but… still a very pleasant experience to write codes in Glide!
That’s why I requested more variables… so I can see live changes while I’m writing the code.
And all of my customers will agree with me… when I have a Zoom session with them… it is the most amazing tool… that you can put the return in any place in the code… and see what is working without clicking done… and adjusting other columns.

3 Likes

I hear you, but lately glide are having a big focus on automation thats why…

I have seen David adding ten extra variables to other columns… just like that… (one time, it was on my request). I hope he will do it again @david

Can I have more votes on this request? Please… 10 or more variables :pray:

1 Like

Hi there!

I’m not an expert, but I came across this problem today and noticed an issue (and its solution) that may be useful for other fellow amateur Gliders:

When passing code to a JS column using a Template column (because I need more than three variables) for a validation function (to detect empty cells), everything worked fine until “p10”, where it stopped validating. It seems dumb and obvious, but tricky at the same time… The problem is that Glide will read “p1” and input the variable found in “p1”, even if the field is supposed to be “p10”. The solution is to use different letters for each dozen. I used: “p8”, “p9”, “q10”, “q11”, and it worked perfectly.

It’s not a groundbreaking discovery, but hopefully useful for someone struggling with this problem at the moment.

Cheers!

Hmm, interesting!
Where you declare p4 and so on? And why? Why do you need px, instead directly inject warables in template column?

Hi! For sure it is just my lack of programming knowledge…

As you say I declare the variables in the Template column but my code stopped working at “p10”, let’s say [p1 = Name] and [p10 = Phone], if you declare “p1, p2 ,…, p10” when glide comes to p10 will substitute it for Name0, p11 would be Name1 and so on. Changing the letter (or using a similar approach) solves the problem and I just wanted to share it with other non expert gliders :slight_smile:

Have a nice day!

1 Like

Ok! I take it. Thanks for sharing!