0

I am having trouble getting access to certain .NET libraries. Phalanger promises the ability to tap into all the .NET libraries; however I can't seem to access many. For instance, I cannot do:

$table = new System\Data\DataTable;

which is a standard .NET library. I am not sure why this is happening because their documentation is a bit dry. Any idea what is going on here? Any help is greatly appreciated!

CodesInChaos
  • 106,488
  • 23
  • 218
  • 262
Serguei Fedorov
  • 7,763
  • 9
  • 63
  • 94

1 Answers1

2

The solution to this is fairly simple. Phalanger will import

 <add assembly="System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />

according to the documentation. However, if you need any extra libraries which exist in .NET (assuming they are installed), you can do the following:

 <add assembly="System.Data"/>

This will allow your Phalanger based application tap into the library! Make sure to add this into the

  <classLibrary></classLibrary>

block!

Serguei Fedorov
  • 7,763
  • 9
  • 63
  • 94
  • Yes, Phalanger will load only libraries specified in configuration section. But it won't load 'System' by itself. Any additional assembly increases application startup, so thats why there is just few default libraries.When you are using a project within Phalanger Tools for Visual Studio (console app or classlibrary), also assemblies listed in References are included. – Jakub Míšek Jul 27 '12 at 16:14