开发者

Recover WinForms from dll

开发者 https://www.devze.com 2022-12-24 17:09 出处:网络
We think most of the source has been recovere开发者_Python百科d through .NET Reflector. A utility which export the dll as C# source.

We think most of the source has been recovere开发者_Python百科d through .NET Reflector. A utility which export the dll as C# source.

The only missing part is WinForms which is not included when .NET Reflector export the dll source.

Is there any way to get the WinForms recover from dll?

Thanks.


If it's not in the dll, you can't get it out :-)

But possible some class files are the forms you're searching for. Maybe you have to add a reference to System.Windows.Forms.dll to your project.


From Visual Studio 2005 on, Windows Forms classes are partial classes split into a Designer generated part (MyForm.designer.cs) and your actual implementation (MyForm.cs). You can see that in Explorer when you create a new Form from scratch.

In order to resolve your problem you would have to split up the class exported by Reflector the same way that Visual Studio does: Place the InitializeComponent() method and all control declarations into the MyForm.designer.cs file and the remaining code into the MyForm.cs file.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号