Help understanding this C# library
Hi kind of a newbie question.
So apparently this library is popular for this sort of thing:
http://extracting.codeplex.com/
When I download that all I get开发者_StackOverflow is a .dll
I can't find documentation on their api, I don't know what I'm supposed to do with this .dll (I know how to load in functions from DLLs and such, but how when I don't even know whats in it?), can someone help me out.
start a new c# project. Open the add reference dialog and use the broswe tab, select the dll.
now open the object browser - you will see all the functions etc
edit: of course you can also download the source code from codeplex; always the ultimate form of documentation
There's a link on the same page pointing to the API documentation containing sample usage.
There is a link to an example on the codeplex site
http://extracting.codeplex.com/wikipage?title=Web%20Data%20Extracting%20and%20Analyzing%20Framework%20API&referringTitle=Home
They have limited documentation on the codeplex site, available here.
I would recommend checking that documentation to see if it meets your needs, and asking any addition questions in their Discussions Page.
To use the functionality of the DLL from your project, right click on your project file in the Solution Explorer and choose "Add Reference..". You will be presented with a dialog to choose the reference you want to add. To choose the DLL from this library, browse to it from the Browse tab.
Once you've added the reference, you won't notice a whole lot of difference - all adding a reference does is give you access to the classes that are defined withing that DLL (called an "Assembly" in .NET terms). Think of it like getting a new set of "built-in" classes in your project that you can now use. You'll want to find some documentation or ask for help on the site to learn how to use these classes.
if you are using visual studio, you can just include the dll into the reference folder of your project and then use the "using" keyword to include the library into your namespace ...
If this is a .NET assembly, then reflector will tell you what classes and methods are available. You can also reference the DLL from a C# project and then press "ctrl-alt-j" to bring up the object browser to see that data inside of Visual Studio.
You can download the source code from that page.
Look at the classes and namespaces. You can add a reference to the DLL to your project and add "using" with the namespace of the DLL to the top of any code files you need to use it in in order to have access to the classes.
Additionally you can look at some of the examples posted.
Load the dll into .net Reflector. This will list the contents of the dll and any code comments associated with the API.
精彩评论