Difference between revisions of "User:Pgmurphy/PerlDotNet"

From WolfTech
Jump to navigation Jump to search
Line 1: Line 1:
# Create strong name key.
+
# Create strong name key.<pre>sn -k <name>.snk</pre>
sn -k <name>.snk
 
 
 
 
# Add strong name key to project.
 
# Add strong name key to project.
 
## Right click on the project in VS, choose Properties
 
## Right click on the project in VS, choose Properties
Line 7: Line 5:
 
## Close project and text edit the .csproj file.
 
## Close project and text edit the .csproj file.
 
##* Change the path to the SN key to the central copy (<AssemblyOriginatorKeyFile>).
 
##* Change the path to the SN key to the central copy (<AssemblyOriginatorKeyFile>).
 
 
# Build project
 
# Build project
 
 
# Register .dll<pre>gacutil /i <file>.dll</pre><pre>regasm <file>.dll</pre>
 
# Register .dll<pre>gacutil /i <file>.dll</pre><pre>regasm <file>.dll</pre>
 
# Call library in Perl
 
# Call library in Perl

Revision as of 16:24, 28 March 2007

  1. Create strong name key.
    sn -k <name>.snk
  2. Add strong name key to project.
    1. Right click on the project in VS, choose Properties
    2. In Signing tab, enable signing and browse to .snk
    3. Close project and text edit the .csproj file.
      • Change the path to the SN key to the central copy (<AssemblyOriginatorKeyFile>).
  3. Build project
  4. Register .dll
    gacutil /i <file>.dll
    regasm <file>.dll
  5. Call library in Perl
use Win32::OLE;
$hello = new Win32::OLE('HelloDot.HelloWorld') or die $!; $hello->sayHello();