Looking for info on ninerays.win.widgets.dll - c#

I've inherited a C# program that makes extensive use of widgets from ninerays.win.widgets.dll. The solution builds fine and even runs under mono in a Armbian Linux environment.
However I have to make modifications to this program and I have no documentation regarding this DLL. I wonder if anything is out there. Also when I attempt to open some of the panels in Designer I'm seeing this error:
I wonder if part of the problem is the NineRays dll file.
I would appreciate any documentation on this dll file and any suggestion on opening panels in designer.

this is not sponsored!
get dotpeek and let it create some documentation for you :)
https://www.jetbrains.com/decompiler/

Related

C# Compiling my code only works for my PC and no one elses

My code is built in NET Framework 4.7.2, it uses two .dlls siticone.dll + windowsinput.dll.
How do I let my code be used by others and include these .dlls. I am highly certain this is caused by those .dlls, as when I make a new WinForms app my friends can open that code but not my main one that has these .dlls!
P.S: on opening the code it sits in Task manager but does not physically open
What worked for me: Costura Fody, a NuGet that includes .dlls to your execute for you.
You can also use "Embed Interop Files" but after some digging and testing myself I found it didn't work on certain versions and lots of people saying to turn it off.
Another error I had with Costura.Fody which I figured out was you may need to remove the .dlls from your references and add them back in afterwards.
PS. You can also use an installer (like inno setup) if you like but I find it much simpler having it all inside of the execute. Hope this helps like everyone has helped me :)

How to decompile ASP.NET web application [duplicate]

we have an application in production and the code is in Pre-Compiled form. The developer who developed that application left the company and we don't have any backup of source code. the only access we have is Pre Compiled code in the server. We need to fix the issues in the application now.
Is there any way to Decompile (extract to actual source code) the PreCompiled code ?
Open the DLLs in the .NET Reflector.
To update #xOn's answer:
Due to a recent source control disaster I had to recover my project from the DLLs. So sadly I'm knowledgable on the procedure:
Get .Net Reflector from here: http://www.red-gate.com/products/dotnet-development/reflector/
You do not seem to need FileDisassembler.
Either load your bins in Reflector or double click them.
Mind that the .Net framework might have not maintained your original project file structure. So if some of your ASPX pages shared the same basic class name in different .cs files (I.E. Inherits tag is the same, but CodeFile tag differs), you would not be able to simply "export source code".
Don't go blindly exporting source files. It won't work.
There will still be some work to be done before being able to just fire up the old build button. For example - DLLs can refer to property's getter/setters directly. You will have to fix that.
Good luck.
Start with:
http://www.red-gate.com/products/dotnet-development/reflector/
...plus:
http://www.denisbauer.com/NETTools/FileDisassembler.aspx
You'll have to recompile the latter to link it against v6.5 of reflector (the latest, as of this post.) It is a good add-on if you want to avoid having to copy and paste ever single class into files by hand. It will dump an entirely assembly as .cs files. I think it may even generate a csproj.
Both tools are free.
I had the similar issue and used Reflector to Decompile it. I got the source code, then changed the bit I wanted, and rebuild it. Then I copied that dll again to Production site. It started to reflect my changes. It was very easy and not at all difficult, maybe because Precompiled site had dlls for every page, and was updatable , so had only code-behind file in dll.
For reference: http://www.reflector.net/
When u install .net reflecter.its import in visual studio.
then you saw the .net reflector tools on menu bar.
Click on .net reflector >>Choose Asseblies (Dll file) to debug.
I found that dll can be just Read using the .NET Reflector tool but can't extract the Source Code. And also once the webforms are precompiled, we can't even get back the code behind files. All we can do is to debug and analyze the Code.

Modify Compiled .Net Exe

I have an application written in C# (without the source of course), that needs to be changed a little bit. For example, I need to stop a few lines of code that create an unnecessary menu. So I think I should comment them out.
The source code is not obfuscated. I know I can completely decompile, change, and compile again, using tools like Reflector/Reflexil. But everyone knows that by doing this, many parts of code won't compile again! Is there a way in Reflector (or any other product) that a part of could be disabled/changed without this process?
Thanks.
You might want to try dnSpy. It is a .NET assembly editor, decompiler, and debugger forked from ILSpy.
https://github.com/0xd4d/dnSpy
If you really needed to do this, you could decompile it with Reflector (or a similar product) and then use that to try to recreate a solution in .Net that will produce the same executable.
You may run into issues around:
Obfuscated code
Sections where the decompile shows you accurate code for specific sections, but for some reason it just doesn't work in your new solution (and then what do you do?)
This is not to mention the potential legal issues related to doing this. If the executable was released under a license that would permit you to do this, then you would most likely have access to the source code. So the fact that you do not have access to the source code implies that doing what you are suggesting might not be legal.
Eventually I managed to "disable" a few lines of code in the compiled exe.
I used Reflector with Reflexil plugin installed. Reflexil allowed me to edit an MSIL instruction, and then save the result back to an exe file. So, it involved learning a few MSIL instructions, especially the "no operation" command (making a line of code do nothing). To see the list of instructions and a tutorial, see here and here.
Hope it helps someone else.
for the sake of completeness:
Another possible solution is to use the ildasm http://msdn.microsoft.com/en-US/library/f7dy01k1%28v=vs.80%29.aspx
MSIL Disassembler, edit the MSIL and feed it back to ilasm.
How practical this solution is, depends on you of course
This thread may help: dotnet dll decompile and change the code
Last time When I tried with decompile the source using reflection, I got too many compilation issues with regarding to resources and other subs though the dll isn't obfuscated. So there could be things beyond just extracting the source and modifying in order to make your new dll work as the old one.
SO I would suggest to go with direct dll manipulation using any of the options mentioned in the other thread.
If you have source code on the same machine on which you are testing your exe file, and if you are making changes in your sourcecode in visual studio, then while compiling it will automatically get reflected in your exe file.
You need not do any special thing for it. And if it is not, then just make the changes in code and paste your debugg folder's new exe (with debugg folder) on another machine having all recent changes.

Scintilla .NET - Can't find libraries

I'm trying to get Scintilla .NET working in a C# form I'm making.
I've followed the directions provided in the readme such as adding the Scintilla component to the toolbox, but when I try to drag the component to a C# form I get this following error:
http://tinypic.com/r/152m7wx/4
I've placed the two included dlls (SciLexer.dll, ScintillaNET.dll) in my system32 folder. I can't seem to figure out what's wrong.
I'm using VS 2008, and Windows 7.
Any ideas why I'd be getting a File not found error?
Is your computer x86 or x64? If it's x64 you need to put the dll's in C:\Windows\SysWOW64
Otherwise do the following: put scilexer.dll in the same directory as scintillanet.dll (note that when you reference scintillanet.dll from VS 2008 it copies it to the debug directory.. so scilexer.dll should also be put in debug.
Try using procmon to "spy" on where it is actually looking for the DLL files.
I found that the problem was caused by whatever I used to install the Scintilla stuff. The install was incomplete.
I don't have specifics, but there is another install floating around on the same page you find the first that is complete. I think that should head you in the right direction. Sorry I can be more specific.
If your still stuck, lemme know and I'll try and figure out exactly where I got the files, or maybe I have them lying around somewhere.

C# debugging across dlls

I have a project which has a calling structure similar to this:
main project/application
my library code
someone else's library code
my library code
Everything's written in C#, and I have access to 'someone else's library code'. Their code is not included in my project, because it's open source and not my code. I can make debug versions of all the libraries, and I've done so.
That 'someone else's library code (SELC, I guess?) is throwing an exception in a heisen-bug kind of way, and I'm trying to track it down and maybe submit a bugfix to the project maintainer. Problem is, my debugging stack is stopping at my library code, and lists the SELC as 'external' and I can't debug into it. I've copied the pdb files as well as the debug version of the library into the debug directory of my application, and still no luck; I can't seem to debug into their code, and I can't step into it at all.
Once upon a time, back in vs6 days, I could do this-- have two different projects open at the same time in two different environments, and have the debugger trace across dll boundaries from one project into another. I'd assume that functionality remains, because it's just so dang useful.
Any suggestions?
I've looked for this answer but not found it, so if this is a dupe, just let me know where to look.
Do you have "Just My Code" turned on in Visual Studio's debugging options?
If you have the sources (as i read from you), you can make an project with their source code, and then add the project to your solution.
In visual studio the project in .csproj file , and solutions in .sln file.

Categories