Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

how to navigate between fields of Editform with Enter key in Blazor?

$
0
0

I want to navigate between fields of Editform with Enter Key thats means i want Enter Key act as Tab key using c# code in blazor,I use this code but it does not work

<EditForm Model="@productDtoVM" OnValidSubmit="Save"><InputText @bind-Value="productDtoVM.itmNo" class="form-control"@onkpress="Tab"/></EditForm>

this is Tab method

 void Tab(KeyboardEventArgs e)        {            if (e.Key == "Enter")            {                e.Key = "Tab";            }        }

i tried to use @onkeyup and @onkeydown instead of @onkeypress but they not working


Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>