Can anyone assist me in next steps to resolve the issue below?
I am debugging the stock ASP.NET Login Form in VS Studio 2019
On the Razor Email Field (in the Login.cshtml file) @Html.TextBoxFor(m => m.Email, new { @class = "form-control" })
I keep getting a red-squiggly in VS Studio - on the View (Login.cshtml).
It shows an aria-valid-attr-value issue.
I have inspected the Email field in Chrome - All ARIA attribute values in this field appear to be valid:
<input class="form-control valid" data-val="true"
data-val-email="The Email field is not a valid e-mail address."
data-val-required="The Email field is required."
id="Email" name="Email" type="text" value=""
aria-describedby="Email-error" aria-invalid="false">
.NET forums are moving to a new home on Microsoft Q&A, we encourage you to go to Microsoft Q&A for .NET for posting new questions and get involved today.
I appreciate the link and it provides a lot of helpful info on aria-describedby, however:
I could not see where "Email-error" was an incorrect format. Or why. Or why it was even created by the ASP.NET engine to start with.
I typed in an invalid email to check and see if there was an error message with the id="Email-error" and there was, so I'm not sure what you mean by incorrect format?
Do you have any feedback on this? I'm still researching and hope to find it myself, but anything "more-specific" regarding my comments above would be very helpful. Thanks in advance!
Accroding to your description,I don't understand your reqiurment clearly.What's the details of the " aria-valid-attr-value issue. "?
Could you tell more details to us?It will help us to solve your problems.
Best regards,
Yijing Sun
.NET forums are moving to a new home on Microsoft Q&A, we encourage you to go to Microsoft Q&A for .NET for posting new questions and get involved today.
The requirement is that I want the error message I'm getting in VS 2019 to go away. It's coming from a standard login form that is generated in the .NET framework MVC (ASP). I did not code the aria attributes on the field, they were auto generated by VS
Studio 2019 and the .NET MVC Framework. As for more specifics, not sure what to provide. I've already provided the error and where it occurs. And for additional info, I've provided what the field looks like in markup after generating the aria attributes.
As even more info, I've provided my research finding on the two aria attributes that could have caused the error. I found nothing out of sorts. One person suggested that the formatting of the aria-describedby might be invalid. I researched it and did not
find anything wrong with the value of "Email-error". This is an id of the field that generates if someone puts in an invalid email address. And when I did that, the id was valid.
Are you saying the form works as expected and the only thing you are trying to address is VS's squiggly line error?
If so, ignore VS's error.
(I can't reproduce your error without knowing more about what kind of project you are using. The Login form created by VS on my MVC projects doesn't include the aria markup you see.)
Yes, I am saying exactly that. I have been ignoring the error, but it would be easier if I knew that it was some kind of known bug.
I'm using .NET framework 4.804084 Visual Studio Community 2019. I have not touched the Login.cshtml file, but have made coding changes regarding authentication and such. But not sure how that would affect the login form. I can't see how any of my changes
would prompt .NET to place aria attributes on fields. I have a feeling that all of that is auto-generated out of the box. Which unnerves me because no one else anywhere else seems to get this error. Perhaps it was a bug in .NET and fixed in Core. I don't
know. But if it was a bug, my google searches are coming up empty.
None
0 Points
4 Posts
ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 06, 2020 07:42 PM|papadan1066|LINK
Can anyone assist me in next steps to resolve the issue below?
I am debugging the stock ASP.NET Login Form in VS Studio 2019
On the Razor Email Field (in the Login.cshtml file)
@Html.TextBoxFor(m => m.Email, new { @class = "form-control" })
I keep getting a red-squiggly in VS Studio - on the View (Login.cshtml).
It shows an aria-valid-attr-value issue.
I have inspected the Email field in Chrome - All ARIA attribute values in this field appear to be valid:
Contributor
3430 Points
1302 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 07, 2020 08:34 AM|yij sun|LINK
Hi papadan1066,
Accroding to your description,as far as I think,Invalid ARIA attribute value: aria-describedby="Email-error".The format is wrong.
More details,you could refer to below article:
https://developer.paciellogroup.com/blog/2018/09/describing-aria-describedby/
Best regards,
Yijing Sun
None
0 Points
4 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 07, 2020 09:41 PM|papadan1066|LINK
I appreciate the link and it provides a lot of helpful info on aria-describedby, however:
I could not see where "Email-error" was an incorrect format. Or why. Or why it was even created by the ASP.NET engine to start with.
I typed in an invalid email to check and see if there was an error message with the id="Email-error" and there was, so I'm not sure what you mean by incorrect format?
Do you have any feedback on this? I'm still researching and hope to find it myself, but anything "more-specific" regarding my comments above would be very helpful. Thanks in advance!
Contributor
3430 Points
1302 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 10, 2020 09:25 AM|yij sun|LINK
Hi papadan1066,
Accroding to your description,I don't understand your reqiurment clearly.What's the details of the " aria-valid-attr-value issue. "?
Could you tell more details to us?It will help us to solve your problems.
Best regards,
Yijing Sun
None
0 Points
4 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 11, 2020 08:36 PM|papadan1066|LINK
Thanks for the reply, yig sun:
The requirement is that I want the error message I'm getting in VS 2019 to go away. It's coming from a standard login form that is generated in the .NET framework MVC (ASP). I did not code the aria attributes on the field, they were auto generated by VS Studio 2019 and the .NET MVC Framework. As for more specifics, not sure what to provide. I've already provided the error and where it occurs. And for additional info, I've provided what the field looks like in markup after generating the aria attributes. As even more info, I've provided my research finding on the two aria attributes that could have caused the error. I found nothing out of sorts. One person suggested that the formatting of the aria-describedby might be invalid. I researched it and did not find anything wrong with the value of "Email-error". This is an id of the field that generates if someone puts in an invalid email address. And when I did that, the id was valid.
What else do you require? Thanks in advance.
Contributor
5921 Points
2450 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 12, 2020 01:23 AM|KathyW|LINK
Are you saying the form works as expected and the only thing you are trying to address is VS's squiggly line error?
If so, ignore VS's error.
(I can't reproduce your error without knowing more about what kind of project you are using. The Login form created by VS on my MVC projects doesn't include the aria markup you see.)
None
0 Points
4 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 12, 2020 09:13 PM|papadan1066|LINK
Yes, I am saying exactly that. I have been ignoring the error, but it would be easier if I knew that it was some kind of known bug.
I'm using .NET framework 4.804084 Visual Studio Community 2019. I have not touched the Login.cshtml file, but have made coding changes regarding authentication and such. But not sure how that would affect the login form. I can't see how any of my changes would prompt .NET to place aria attributes on fields. I have a feeling that all of that is auto-generated out of the box. Which unnerves me because no one else anywhere else seems to get this error. Perhaps it was a bug in .NET and fixed in Core. I don't know. But if it was a bug, my google searches are coming up empty.
Contributor
5921 Points
2450 Posts
Re: ASP.NET Standard Login Form - (aria-valid-attr-value) Issue
Dec 12, 2020 09:57 PM|KathyW|LINK
Ask on the Visual Studio forum:
https://developercommunity.visualstudio.com/spaces/8/index.html