why not my javascript passing parameter to code behind method [Resolved]

Posted by Cpatil1000 under ASP.NET on 9/27/2016 | Points: 10 | Views : 190 | Status : [Member] | Replies : 1
Hi,
i am using repeater to display farmer status. In the repeater in using anchor tag.
when i click it not passing hidden value of our code behind method
'SetFarmerChart()'

but i am getting value of anchor tag
'status_id'
.. When page load it is calling perfect
but when i try on anchor click it is not calling..
So how do it..

Please find the attachment




Responses

Posted by: Sheonarayan on: 9/29/2016 [Administrator] HonoraryPlatinum | Points: 50

Up
0
Down

Resolved
You can code like this under Repeater ItemTemplate.

<a href="javascript:SetFarmerChart('<%= Eval("status_id") %>')">Show Chart</a>


This will pass the status id to the javascript function.

Thanks

Regards,
Sheo Narayan
http://www.dotnetfunda.com

Cpatil1000, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response