0

When I want to add new entry to @Html.EditorFor I can see suggestions of my last entries. Look at the picture below.

enter image description here

Is there any way to remove or hide the suggestins?

My code:

        <td>
            @Html.EditorFor(modelItem => item.NR_PRZESYLKI_EX)
            @Html.ValidationMessageFor(model => item.NR_PRZESYLKI_EX)
        </td>
  • 1
    Does this answer your question? [How do you disable browser Autocomplete on web form field / input tag?](https://stackoverflow.com/questions/2530/how-do-you-disable-browser-autocomplete-on-web-form-field-input-tag) – GSerg Feb 07 '20 at 08:00
  • I think this is the browser's autocomplete functionality. You can try to turn it off via this answer: https://stackoverflow.com/a/3015847/6996150 . But in Chrome it's notoriously difficult to stop the functionality. – johey Feb 07 '20 at 08:00

2 Answers2

0

This should work.

    <td>
        @Html.EditorFor(modelItem => item.NR_PRZESYLKI_EX, new { autocomplete="off" })
        @Html.ValidationMessageFor(model => item.NR_PRZESYLKI_EX)
    </td>
sheavens
  • 685
  • 7
  • 14
0

Thanks for all answers. @sheavens your code doesn't work for me :( @johey your suggestion solve the problem...