Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PropertyGrid and SQLConnectionStringBuilder #1142

Closed
FJGR65 opened this issue Jun 27, 2021 · 24 comments · Fixed by #1152
Closed

PropertyGrid and SQLConnectionStringBuilder #1142

FJGR65 opened this issue Jun 27, 2021 · 24 comments · Fixed by #1152
Assignees
Labels
Area\Netcore Issues that are apply only to .NET runtime or the 'netcore' project folder.

Comments

@FJGR65
Copy link

FJGR65 commented Jun 27, 2021

When I try to edit the properties of the SqlConnectionStringBuilder in a PropertyGrid there is a problem with the synonyms. Properties appear with their original names and synonyms.
Categories don't work either, as do descriptions.

The application is on .NET 5.0

Portapapeles01

@Wraith2
Copy link
Contributor

Wraith2 commented Jun 27, 2021

Runtime or design time? The ref assembly looks like it's correctly annotated with ComponentModel attributes so it should behave properly at design time. The implementation in the src assembly doesn't have the attributes though, so if this is runtime then we can fix it, if it's design time then I'm not sure what's happening.

@FJGR65
Copy link
Author

FJGR65 commented Jun 27, 2021

It's at runtime.

Thank you for the correction.

@Wraith2
Copy link
Contributor

Wraith2 commented Jun 27, 2021

It should be pretty simple to fix then. We just need to annotate the src with the same attributes as ref.

@JRahnama
Copy link
Contributor

@FJGR65 Thanks for bringing up this issue to our attention. We will look into it shortly.
@Wraith2 Thank you for the solution.

@JRahnama
Copy link
Contributor

JRahnama commented Jul 5, 2021

@FJGR65 I added the annotations to src, but when it comes to testing I had some difficulties creating the grid. Can you walk me through the steps you have taken to make the property grid in netcore please?

@FJGR65
Copy link
Author

FJGR65 commented Jul 5, 2021 via email

@FJGR65
Copy link
Author

FJGR65 commented Jul 6, 2021

Good Morning:

I do not know how to upload a project to the comments, so I send you the code by e-mail. It is a reduced version of what I am doing, but I hope it is useful to test your annotations.

@JRahnama
Copy link
Contributor

JRahnama commented Jul 6, 2021

Good Morning:

I do not know how to upload a project to the comments, so I send you the code by e-mail. It is a reduced version of what I am doing, but I hope it is useful to test your annotations.

Thank you. I got the code. I will start testing the fixes and will update you shortly.

@FJGR65
Copy link
Author

FJGR65 commented Jul 6, 2021 via email

@JRahnama
Copy link
Contributor

JRahnama commented Jul 6, 2021

@FJGR65 I tested and everything is working as expected. Please check the fixe in your convenient time and confirm that the issue is solved.

Thanks for bringing up the issue.
Regards

@JRahnama JRahnama self-assigned this Jul 6, 2021
@JRahnama JRahnama added the Area\Netcore Issues that are apply only to .NET runtime or the 'netcore' project folder. label Jul 6, 2021
@JRahnama JRahnama added this to the 4.0.0-preview1 milestone Jul 6, 2021
@FJGR65
Copy link
Author

FJGR65 commented Jul 7, 2021

Thank you very much for the solution. There are no problems with the synonyms, although the categories and descriptions continue without appearing. However, for me it is enough.

@ErikEJ
Copy link
Contributor

ErikEJ commented Jul 7, 2021

@FJGR65 Can you share a screenshot that demonstrates the missing parts?

@FJGR65
Copy link
Author

FJGR65 commented Jul 7, 2021

This is with new fixes:
Portapapeles02

This is with .Net Framework 4.5.2 with System.Data.SqlClient (in spanish, sorry)

Portapapeles03

@Wraith2
Copy link
Contributor

Wraith2 commented Jul 7, 2021

Missing CategoryAttribute annotations.

@FJGR65
Copy link
Author

FJGR65 commented Jul 7, 2021 via email

@Wraith2
Copy link
Contributor

Wraith2 commented Jul 7, 2021

We have localized versions of CategoryAttribute and DescriptionAttribute called ResCategoryAttribute and ResDescriptionAttribute which allow localization, those will need to be applied.

@cheenamalhotra
Copy link
Member

cheenamalhotra commented Jul 7, 2021

CategoryAttributes could be applied to match the behavior with .NET Framework, but we don't have localized resources supported in .NET Core yet.

That would be part of a separate task, just FYI. cc @David-Engel
If it can work in English, it should be acceptable fix for this particular issue.

@Wraith2
Copy link
Contributor

Wraith2 commented Jul 7, 2021

I think english would be better than nothing, at least there's an indication of category in that case even if the category itself isn't in the right language.

@JRahnama
Copy link
Contributor

JRahnama commented Jul 7, 2021

That would be part of a separate task, just FYI. cc @David-Engel David Engel (Simba Technologies Inc) Vendor
If it can work in English, it should be acceptable fix for this particular issue.

David approved that English-only is better than nothing.

There are several changes made to the PR. More file has changed.

@FJGR65 can you check with the new build from the PR?

@FJGR65
Copy link
Author

FJGR65 commented Jul 8, 2021

First, thank all of you for the effort made to solve the problem. The result has been much more than satisfactory, since my intention was simply to solve the problem with the PropertyGrid.
You have managed to work properly, to show the categories and descriptions. It is much more than expected. Thank you.

As for the issue of translations, I just hoped they were in English. The screen shown in Spanish was because I am on holidays and it is very difficult for me to access my development computer on remote, so I could not show the screen in English. It has also been rather complicated to respond more quickly to your requirements, since I do not have access to the Internet on the beach and I have had to move to perform the tests and screenshots.

Anyway, it has been very rewarding to check the quick response from you, kindness and willingness to solve the problem. Thanks.

Finally, I show you the last screenshot in which it is checked that the PropertyGrid works correctly. Thus, for me, the problem is completely solved.

Portapapeles04

All the best
Francisco

@ErikEJ
Copy link
Contributor

ErikEJ commented Jul 8, 2021

So Categories work on an English system?

@FJGR65
Copy link
Author

FJGR65 commented Jul 8, 2021 via email

@JRahnama
Copy link
Contributor

JRahnama commented Jul 8, 2021

So Categories work on an English system?

Descriptions are English-only for now.

@Wraith2
Copy link
Contributor

Wraith2 commented Jul 8, 2021

but we don't have localized resources supported in .NET Core yet.

If there isn't an issue to track localization in netcore can we open one? The localized resources are in netfx so in theory it's all just waiting on the source merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area\Netcore Issues that are apply only to .NET runtime or the 'netcore' project folder.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants