This is the hidden field and the javascript.
<asp:HiddenField ID="hdn" runat="server" />
<script type="text/javascript">
document.getElementById("hdn").value = "helo";
</script>
And i tried to access the hidden field value in the .cs file as string st = hdn.value.
But it shows null when i check the value using linebreaker
st = hdn.value? On page load? If is, it is after post back or not? How do you check valueusing linebreaker? What's more, the ID of element is invalid. TheIDproperty tells us about server control id, but client id is different (id in input field, auto-generated).