I want to add v-on:click or @click in like following html helper method:
@Html.TextBoxFor(x => x.ItnScanCaseCode, new { @id="txtid",@click = "onchangeevent();" })
How to do that?
You could use a Dictionary
for htmlAttributes
like this:
@Html.TextBoxFor(x => x.ItnScanCaseCode, htmlAttributes: new Dictionary<string, object> {
{ "v-on:click", "onchangeevent()" },
{ "id", "txtid" }
})
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With