Difference between revisions of "FAQ.Microsoft.NETframework"

From Overbyte
Jump to navigation Jump to search
 
Line 1: Line 1:
[[Main_Page | Main page]] -> [[FAQ]] -> [[FAQ.Microsoft.NETframework | Microsoft .NET framework]]
 
  
== Creating a .Net package in Delphi for .Net ==
 
 
# Create a .net package (recommendation from dr Bob at http://www.drbob42.com/examines/examin55.htm)
 
# Add the units in the DotNet-folder of ICS e g Overbyte.Ics.Component.pas et c.
 
# Add the Borland VCL (the units implicity uses them so they are needed as a reference)
 
# Compile and the finished DLL-can be used by .Net environments like Visual Studio 2005.
 
 
 
== Examples ==
 
 
=== Creating a socket in C# ===
 
 
Add a reference to the DLL that you created. Then add using and the code at proper places.
 
 
  using OverByte.Ics;
 
  using OverByte.Ics.Units;
 
 
  lSocket = new TWSocket(null);
 
  lSocket.Addr = "127.0.0.1";
 
  lSocket.Port = "10001";
 
  lSocket.LineMode = true;
 
  lSocket.OnSessionConnected += new TSessionConnected(lSocket_OnSessionConnected);
 
  lSocket.OnDataAvailable += new TDataAvailable(lSocket_OnDataAvailable);
 
  lSocket.Connect();
 

Latest revision as of 14:43, 6 August 2007