21
Views
4
Comments
Solved
How to use Javascript Output of Object type in OS client action?
Question
Application Type
Reactive

Hi there,

I am wondering, I have a JS output of type Object Car. I want to show message with the value Car.type in the client action (button on click).  How to?

regards

2025-02-10 17-24-13
Arun Rajput
Solution

Ok got you.

You can use this object variable in further javascript on same page.

Let me tell you one scenario where I used this 

I have integrated stripe payment gateway in my project and on ready event I assigned stripe object in object variable then on click of button I used this object variable to make the credit card payment, I told this scenario in short but this is how you can use object variable further in code.

I am not sure but there can be other uses as well but I knew only this.

Hope it clear your query.

2025-02-10 17-24-13
Arun Rajput

Hi Indra,

Create one more output parameter insise javascript let's say it's "CarType" then assign value from object to this parameter.

Like:

 CarType =car.type;

Best 

Arun

2025-01-09 14-56-57
IQ78

Hi, thanks

But, i mean in general, how to use variable local of type Object in OS client action?

regards

2025-02-10 17-24-13
Arun Rajput
Solution

Ok got you.

You can use this object variable in further javascript on same page.

Let me tell you one scenario where I used this 

I have integrated stripe payment gateway in my project and on ready event I assigned stripe object in object variable then on click of button I used this object variable to make the credit card payment, I told this scenario in short but this is how you can use object variable further in code.

I am not sure but there can be other uses as well but I knew only this.

Hope it clear your query.

2025-01-09 14-56-57
IQ78

Thanks,

So it is useless except for third party object? I mean in client action, the object (in my case object Car) cannot directly manipulated?

regards

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.