Is it possible to pass a global var value using Ajax OnClick Event ?

Hello,
I’m trying to pass a global variable throught OnClik Event.
I’ve tried to insert the following code

[glo_save_current_where]=’’;

$save_current_where = {sc_where_current};
[glo_save_current_where]= $save_current_where;

but unfortunatly it doesn’t work.

I don’t know Ajax but I hope in some way it’s possible the same.
How can I modify code ?

Thanks

Do you fixed the problem?

Hello,
unfortunately not…
The issue is almost tricky and I try to explain my goal.

I got a grid with some features on board.
I want to mantain the Refined search that user does during the use of application.
So if you select a category of products on the left of the grid when you come back from buttons clicking or other actions the user is expecting to find the same situation.

I added to the end of SQL of grid a global var [glo_save_current_where]
like…
FROM products LEFT OUTER JOIN price_list ON products.ProductID = price_list.ProductID
AND (price_list.CustomerID = ‘[glo_CustomerID]’ )
LEFT JOIN categories ON products.CategoryID = categories.CategoryID
[glo_save_current_where]
ORDER BY ProductID ASC

Then I put this within OnRecord

$save_current_where = {sc_where_current};
[glo_save_current_where]= $save_current_where;

This goes in conflict with the functioning of Refined Search and in some case ithe refined serch goes stucked.

A short video… I need to improve it but you can understand better the meaning of above rows… :wink:

Hello,
unfortunately not…
The issue is almost tricky and I try to explain my goal.

I got a grid with some features on board.
I want to mantain the Refined search that user does during the use of application.
So if you select a category of products on the left of the grid when you come back from buttons clicking or other actions the user is expecting to find the same situation.

I added to the end of SQL of grid a global var [glo_save_current_where]
like…
FROM products LEFT OUTER JOIN price_list ON products.ProductID = price_list.ProductID
AND (price_list.CustomerID = ‘[glo_CustomerID]’ )
LEFT JOIN categories ON products.CategoryID = categories.CategoryID
[glo_save_current_where]
ORDER BY ProductID ASC

Then I put this within OnRecord

$save_current_where = {sc_where_current};
[glo_save_current_where]= $save_current_where;

This goes in conflict with the functioning of Refined Search and in some case ithe refined serch goes stucked.

A short video… I need to improve it but you can understand better the meaning of above rows… :wink:
https://www.youtube.com/watch?v=pW2JGLKWv3U

I think Refined search is not working well. When you cancel the filter, SC must show original records.
you must try do the filter with the code of category. and show the name with a automaic select.

Yes , I also asked bug service but …they say… it’s not a SC problem… :wink:
Tomorrow I will try with using category instead and let you know