CodeConverter icon indicating copy to clipboard operation
CodeConverter copied to clipboard

VB => C#: Cannot find custom tool 'MyApplicationCodeGenerator' on this system @ My Project\Application.MyApp

Open ATECoder opened this issue 3 years ago • 3 comments

Is your feature request related to a problem? Please describe. This is more of a question: It looks like Application.myapp serves to point to the startup object. The project file includes reference to the code generator decorating the application.designer.cs file, which points to the startup object. <None Include="Properties\Application.myapp"> <Generator>MyApplicationCodeGenerator</Generator> <LastGenOutput>Application.Designer.cs</LastGenOutput> </None>

I wonder if the designer can be references without referencing the code generator.

Describe the solution you'd like Decorate the designer differently.

Describe alternatives you've considered N/A

Additional context N/A

ATECoder avatar Oct 23 '20 13:10 ATECoder

I'm guessing ".myapp" a VB-only thing so perhaps the converter should entirely remove the myapp file and the reference to it, and just leave the generated designer code there? I've never really looked at this functionality, so do let me know what you end up doing in C# with those settings and I'll have a think about how the converter can make that easiest without breaking any existing stuff

GrahamTheCoder avatar Oct 24 '20 09:10 GrahamTheCoder

My observations are:

  • Application.myapp and the associate designer can be removed from library and test projects.
  • Removing Application.myapp from the project file and leaving the designer seems to work. It seems that, other than the authentication mode, the designer retains the information listed in 'myapp'.

I used www.funduc.com Search and Replace to change the project file and attached the script (this does not remove the designer, though, as the script is oblivious to the project type): ApplicationMyApp-Remove.zip

Also, here is a link to a reply on Stack Overflow with links to MSDN articles: https://stackoverflow.com/questions/1329169/authentication-mode-application-defined

ATECoder avatar Oct 24 '20 16:10 ATECoder

found a couple of additional cases for the application.designer in the project file of my converted C# projects.. see attached S&R script: ApplicationMyApp-Remove.zip

ATECoder avatar Oct 25 '20 04:10 ATECoder