Hi guys,
I have a textbox in .net and need to be able to add commas while typing dynamically and I've tried to search online but haven't got luck, here's what I found and not working
anyone could help will be appreciated, Thanks!
I have a textbox in .net and need to be able to add commas while typing dynamically and I've tried to search online but haven't got luck, here's what I found and not working
Code:
<script type="text/javascript">
$(document).ready(function () {
$('[id$="jquicomma"]').keyup(function () {
if (this.value.length % 4 == 3) this.value = this.value + ",";
});
});
</script>
<asp:TextBox ID="jquicomma" runat="server" Width="90%"></asp:TextBox>
anyone could help will be appreciated, Thanks!