Variable Undefined Error

Hello All!

I am facing this issue from past two three days. I wanted to know if anyone else is facing the same issue or not. If yes! How did you solve it.

So, the problem is that I passing a variable to other activity in my flow. I have initialized my variable in the very beginning. I don’t know why it is giving me error of variable undefined.

Here is the picture. You can see very clearly that everything is perfect and fine.

Warm Regards,
Muhammad Hayyan Khan

Firstly, what kind of monster codes in light mode? (just kidding :upside_down_face:)

Secondly, I’ve tested a similar code and it works fine for me. Can you give more details? Is it possible for you to show your workflow and the content of the Excel sheet?

1 Like

@Muhammad_Shahzeb Could you share the .neek file here, so we can check quickly.
(I will check in light mode too :smiley:)

1 Like

@Muhammad_Hayyan looks like your issue is already resolved via a ticket by support team. Let us know via ticket if something is not going well in this regard.

1 Like

Hi @Avinash_Rai

I was very busy last days in that project. I solved it myself by simply logging out and log in again :slight_smile: . With the time I have learned solving such issues with ElectroNeek. If there is any issue with ElectroNeeks development side, close the project and reopen it again. If issue still exists, restart your PC. If it doesn’t work, log out and log in to Studio Pro :sweat_smile: .

Anyways I really appreciate the efforts of support. Thumbs up :+1:

Hahaha! Pro developers use light mode :sunglasses:

Yes! The logic was fine. But I don’t know it was giving error for no reason. But such things happens in ElectroNeek. I am sure you would have experienced as well if you use this platform on regular bases.

Thank you! Have great day!

Hahahaha! “We” you and your team? If you guys are comfortable in dark mode. Give it a try in dark mode. I wish you best of luck! Take care :sweat_smile: :+1:

Issue was solved. I really appreciated your support.

Thank you! Have a nice day!

@Muhammad_Hayyan i had a look at the ticket you raised and seems the solution was to change the variable name and not the restart and logout/login. Since you were using JS-reserved words length as a variable name and hence the issue was encountered.
Can you reconfirm that you did not make any changes and simply restart worked? Our support team would like to dig deeper and find out more to avoid such inconvenieneces. We appreciate your comments in ticket no. 12180. We will await for your respose!

I would love to share more details. Yes! The solution provided was to change the variable name from length to size because length is function in js. But it really does not effect the code. You can use a variable name length anywhere in your code.

The other solution was to use variable after the read text file activity but I was using variable in that activity and I had to initialize it before read text file activity.

I tried using logout/login method. It worked!

Have a great day! Thank you for your support!