Welcome! - PowerTCP Telnet for .NET

PowerTCP Telnet for .NET
Welcome!
Send comments on this topic.

PowerTCP Telnet for .NET 4.x fills the Telnet and remote access communication gap in the .NET Framework by providing stream-based Telnet communication that can be plugged into any Framework 2.0+ application.

Overview

This latest version of the venerable PowerTCP product line gets a new .NET 2.0 re-design that leverages the power of the latest .NET environments to provide the most advanced Internet Communications components available. Some of the features include:

  • Auto-login capabilities
  • Auto-option negotiation with easy configuration options
  • Secure SSL Telnet support
  • Blocking reads that wait for defined delimiters, specifically designed for scripting applications
  • Start method for easily implemented multi-threaded applications, including cross-threading marshaling support
  • PTY property binds a TextBox to the Telnet component as a ready-made interface for interactive online communications
  • Logging event for easy debugging and session logging
  • Proxy support
  • Includes Rexec, Rsh and Rlogin components in addition to Telnet

Background

The Visual Basic environment introduced the use of components (VBX and OCX), but typically only executed on the UI thread. Though multi-threaded support was added at the Operating System level, developers needed C++ to created multi-threaded applications.

When 32-bit application support was added to Visual Basic, PowerTCP was able to use background worker threads to execute communication tasks, and not interfere with the UI. Events, however, could only be raised on the UI thread.

.NET Version 1

The use of worker threads, delegates and events was greatly improved under .NET 1.0:

  • Background threads could be conveniently started
  • Events could be raised on worker threads

In fact, the multi-threaded environment became so powerful that users needed to become aware of concepts like thread safety and synchronization, which were never of concern before.

PowerTCP evolved as well, providing an interface that included blocking methods (which block the executing thread until completion), pseudo-blocking methods (which block the UI thread until completion, but process events while doing so), and asynchronous methods (which execute on background threads). The goal was to provide as complete an interface as possible, without making it complex or difficult to use.

.NET Version 2

The .NET environment has evolved, and so has its users. Customers are developing more applications for ASP.NET, more console applications, and more service applications. Lacking UIs, pseudo-blocking and asynchronous methods are not relevant for these environments. There are also trends towards greater levels of customer control. For these reasons, PowerTCP for .NET 4.x was designed with the following emphases:

  • Model-View-Controller Support
    Traditional PowerTCP asynchronous support provided a means for executing methods on worker threads, but this required a signaling mechanism indicating when operations completed. This resulted in difficult-to-maintain, event-driven code. With the new design, code is more self-documenting, uses fewer resources, and is more flexible to use. In addition, the user interface is separated from protocol logic. Please see Asynchronous Operation Obsoleted for a more detailed examination of the benefits of this new design.

  • Improved Re-Use of .NET 2.0 Features
    PowerTCP 4.x has taken advantage of generics, improved support for X509 certificates, and other features introduced in .NET 2.0. Now that most users have migrated from .NET 1.x, PowerTCP can be upgraded without sacrificing backward compatibility. Of course, the .NET 1.x product line will still be licensed for use in the .NET 1.x environment to support legacy applications.

  • Integrated Security
    Secure Socket Layer (SSL) security is integrated into the core product, so that SSL encryption is included in each new product.

  • Support for .NET CF (Compact Framework)
    Comprehensive support of the Compact Framework has been extended with the new design.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Component
Rlogin Component
Rsh Component
Telnet Component

Documentation Version 4.4
© 2011 Dart Communications. All Rights Reserved.


Getting Started - PowerTCP Telnet for .NET

Getting Started
Send comments on this topic.

In addition to perusing this documentation, it is highly recommended that the user examine the sample applications available on the website.

For the most basic quick-start, create a new Windows Application project in Visual Studio, drag the Telnet component and a button onto the form, and add code to your Click event handler. Examine this documentation for simple example snippets to emulate.

Sample Applications

All samples include C#, VB.NET and VC++/CLI versions. A PowerShell sample is also available.

Sample | Description
Automated Client | Demonstrates execution of an automated application using Telnet.
Rexec Client | Demonstrates execution of a command using Rexec.
Rlogin Client | Demonstrates a user-interactive Rlogin client.
Rsh Client | Demonstrates execution of a command using Rsh.
Telnet Client | Demonstrates a user-interactive Telnet client.
Telnet Automated Console | Demonstrates use of Telnet in a console application.
Telnet PTY Client | Demonstrates use of the Pty feature, which adds a TextBox interface to the Telnet component.
Telnet Automated Web | Demonstrates use of Telnet on a web page.

Download the Telnet for .NET Sample Applications

Support Options

Our mission at Dart is to deliver high quality Internet connectivity solutions to Internet application developers. Our goal is to supplement these solutions with timely support resources that can help at many different levels.

You must have an active connection to the Internet to view these links.

Paid Support Options
Discusses the paid support options available.
Free Support Options
Provides access to free materials to help your development, including FAQS, online help files, tutorials, code snippets, online asp samples, and a free support forum.
Support Forum
Provides access to our support forum, monitored by our own development staff as time permits.
Dart Solutions
Discusses the custom development support offered by Dart Solutions.

Authenticode Signing

Dart installation executables are authenticode signed with a "Dart Communications" digital certificate to ensure against tampering during distribution.

Dart dlls included in the installation bin directory are .NET strong name signed, but not authenticode signed. These dlls are used by the sample applications and typically referenced in users' products.

For those users who require dlls signed by the author company (for example, for Windows logo compliance), dlls that have been signed with the "Dart Communications" digital certificate are also included in the product. These dlls are contained in the "Signed Distributables" sub-folder under the installation bin folder.

In accordance with the End-User Licensing Agreement, pre-compiled Dart dlls may NOT be signed with a user's own certificate. However, for users who wish to independently sign these dlls, Dart offers Enterprise licenses which allow for this. Please contact sales@dart.com for more information.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Component
Rlogin Component
Rsh Component
Telnet Component


Licensing and Trial Operation - PowerTCP Telnet for .NET

Licensing and Trial Operation
Send comments on this topic.

Licensing the Product

The Developer License

Licensed components require the presence of a Developer License in order to create a valid runtime license resource. Developer Licenses are specific to the user's development machine, and to the version of the Dart assembly used.

Obtaining a Developer License

After purchase of the product, the developer is furnished with a Product Key (Serial Number) that licenses development for a single user on up to two machines.

To obtain the Developer License, run the included DartActivateLicense utility and enter the Product Key. This utility opens a web browser and navigates to the Dart Customer Center, where a zip file containing the Developer License file is available for download. If an Internet connection does not exist, the utility provides a URL for downloading the Developer License file at a later date.

Subscription customers can obtain a Product Key for a product that has been upgraded by visiting the "My Products" page of the Customer Center and clicking on the listed current license.

Location of the Developer License

The Developer License file should be extracted from the downloaded zip file and saved to the following location:

Program Files \ Dart \ PowerTCP Telnet for .NET \ <Version Number> \ bin

where <Version Number> is a placeholder for the product version number associated with the license.

This location is also accessible from a shortcut added to the Start menu:

Start \ All Programs \ Dart \ PowerTCP Telnet for .NET \ <Version Number> \ Binaries Folder

At runtime, the component will search this location for the Developer License. No trial messages are subsequently seen.

The Developer License should never be deployed with an application.

Versioning

Developer Licenses are version-specific. Each minor version of the product (for example, 4.0 and 4.1) requires a separate Developer License. Build updates to the product (for example, 4.0.0 and 4.0.1) do not require a new Developer License. Version upgrades are available to developers with an active subscription.

Developer License Filename

The Developer License filename has the following format:

Dart.Telnet.developer.dartlic

Important!!!

A machine must have a Developer License to license runtime use.

The .licenses Resource

An <appname>.licenses resource file is linked into the developed assembly during compilation. This file contains either the Product Key or a trial expiration date. This resource is read at runtime to confirm that the topmost managed assembly is licensed. A LicenseException is thrown if no license is found. To license intermediary assemblies, see the "Extended and ISV Licensing" section below.

The licenses.licx File

When a licensed control or component is added to a Visual Studio project using the designer, a licenses.licx text file is created (if one does not already exist) and added to the project. A single-line entry is added to the file, which includes the licensed Class (for example, "Dart.Telnet.Telnet"), the Assembly name (for example, "Dart.Telnet"), and some optional information such as Version Number. This file can be found in the Solution Explorer.

The presence of this licx file triggers the Microsoft license compiler utility (lc.exe) to create the .licenses resource during compilation.

Manual Creation of the licenses.licx

If the licenses.licx file is not automatically updated (such as when a licensed component is created in code or when the target platform is a device), the licenses.licx entry must be added manually. If it does not already exist in the project, a new text file named "licenses.licx" must be added to the Project. It is not enough for the file to exist in the working directory, or for it to be added to the Solution. The entry for the licensed component is a single line that includes the name of the component and the assembly name, separated by a comma. For example:

Dart.Telnet.Telnet, Dart.Telnet

Web Site Projects

Web Site projects include an App_Licenses.dll that must be rebuilt when changes are made to the licenses.licx file, or when a new Developer License has been installed. This is accomplished by right-clicking on the licenses.licx file in the Solution Explorer, and selecting the "Rebuild Runtime Licenses" option.

Compilation Environments That Do Not Support the licenses.licx File, Like MONO

For environments that do not recognize the licenses.licx file, Dart has its own License Compiler application. This utility can be used to generate the <appname>.licenses resource file, which can then be added to the project as an embedded resource, or linked during compilation using the appropriate resource switch. Please contact Dart Support for help with compilation in environments that do not recognize the licenses.licx file.

Scripting Environments

A Developer License can be used in place of the license resource for environments without compilation.

Troubleshooting

LicenseExceptions thrown by the executing application should provide detailed information regarding the problem causing the exception.

In addition, the product utilizes the system's Application Event log, under the "Dart Components" source (or the ".NET Runtime" source, if the "Dart Components" log could not be created).

Important!!!

  • The license resource must be for the Entry (topmost managed) Assembly (exe or dll).
  • Cases in which the Entry Assembly is not the topmost executing application are considered "Plug-In" scenarios and require a Plug-In Distribution License or an ISV Distribution License (see below for more details).

Extended and ISV Licensing

Please contact Dart Sales to further explore the Extended and ISV licensing options.

Extended Distribution License

The Extended Distribution License is available for the development of software to be used by an executing assembly that does not contain a Dart license resource. This is typically a dll that exposes a programming interface and can therefore be used as a development tool. This includes, but is not limited to, the following scenarios:

  • Creation of a dll that can be used by other software developers as a development tool
  • Creation of a plug-in dll that can be used by existing 3rd-party application(s)
  • Creation of a dll that provides a COM interface to a VB6 application
  • Creation of an exe that exposes a class that is used to access product functionality

ISV Distribution License

For Independent Software Developers (ISVs) or Enterprises who wish to bypass all licensing mechanisms, Dart offers the ISV Distribution License. The ISV license permits the tight integration of Dart source code directly into a library or application.

Trial Operation

At Runtime

Components used by applications running in trial mode will periodically show a trial message, and, after seven days of operation, expire.

7-Day Trial

An application compiled with a trial license can be deployed to other platforms for testing, but the license expires after 7 days.

  • No messages are shown during the Trial License's first 4 days.
  • After 4 days, the user is informed of the date the trial license will expire.
  • After 7 days, the user is informed of the trial's expiration. The application will cease functioning and throw a License Exception when used.
  • A trial license can be reset by recompiling the application.

Trial Messages

  • Trial messages and exceptions will always appear in the system's Application event log under the "Dart Components" source (or the ".NET Runtime" source, if the "Dart Components" log could not be created).
  • A trial message or exception will also appear in a MessageBox, if the environment is capable of showing MessageBoxes.
  • Components used in ASP.NET applications will show trial messages or exceptions in client-side alert boxes when possible.

Important!!!

For environments without an active desktop (for example, under some Windows service and web application scenarios), examine the Application event log for trial messages and exceptions.

With the exception of the trial messages and instance expiration exception, runtime trial operation is the same as licensed operation. The same dll is used for both trial and licensed operation.

During Development

A trial message is always displayed when a 7-Day Trial license is created.

See Also

Reference

Rexec Component
Rlogin Component
Rsh Component
Telnet Component


Telnet Protocol Overview

Telnet Protocol Overview
See Also Send comments on this topic.

Glossary Item Box

The following information provides a basic understanding of the TELNET protocol and related concepts. This topic does not attempt to demonstrate usage of PowerTCP Telnet for .NET. For information of this type, see Asynchronous Operation and Assembly Overview.

Protocol Overview

TELNET (Telecommunications Network Protocol) is a data communications protocol—a set of rules for communications between computers. Telnet communication is the same for all systems, permitting it to work between different types of computers and operating systems. Telnet is often used for remote login—accessing one computer from another. A typical Telnet application would use the protocol to move data between a terminal emulator and a UNIX server (host).

Many host computers support the Telnet protocol. Its main use is online terminal communications; Telnet can be used to log in to remote machines and issue commands just as if the user was situated at the actual machine. Telnet can also be used to access remote databases, control other computers, distribute work among multiple systems, and remotely execute many applications.

Telnet is built upon TCP, and provides additional features that make it an upper-layer protocol. Using Telnet, both ends of a connection send data to each other. Typically, a terminal sends commands to a host, and the host responds with messages or data. For example, a user at a terminal may type "help" and the host may respond with "Type a command to get help on."

Telnet provides option negotiation as a means for establishing conventions between two machines. During a session, either host may send the other a command—requesting or volunteering a specific option. For example, the process of option negotiation determines if either computer will support echoing.

Telnet Connections

Connections are made on a port, which is a method of distinguishing multiple communications on a single computer. Most Telnet connections are made to port 23, the standard Telnet port.

To make a connection, specify a port and host name or address to connect to. All computers on a network have a distinguishing IP address. Standard IPv4 addresses have the following same format:

nnn.nnn.nnn.nnn

where each nnn is a number from 0 to 255 (except for the first octet, which may be from 0 to 247). This means an IPv4 address is 32bits long, allowing nearly 2^32 unique values. A typical IP address might be 129.229.1.2.

PowerTCP provides full support for IPv6. IPv6 was established as the next generation Internet protocol, in order to greatly increase the number of available IP addresses. IPv6 addresses have the following hexadecimal format:

xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx

where each xxxx is a hex value from 0000 to FFFF (0 to 65535). This means an IPv6 address is 128bits long, allowing 2^128 unique values. A typical address might be fe80::211:d800:97:c915. Note that "::" indicates a consecutive group of 0 values.

Most networks also support computer names, where the network will translate a name (such as "server3") into an IP address.

Network Virtual Terminal

The Network Virtual Terminal (NVT) is a concept used by Telnet to represent both hosts in a connection. The NVT is an imaginary character-based device with a keyboard and a printer (input and output). Incoming data goes to the printer, and input from the keyboard goes to the other end of the Telnet connection. Both ends of a Telnet connection must support the NVT.

The NVT supports the 7-bit character set known as NVT ASCII. NVT ASCII is the same as normal ASCII text, except that only 7 bits represent the character. The eighth high bit of the byte must be set to 0. In NVT ASCII, an end of line is represented by a two-character sequence CR, LF (carriage return, line-feed).

Both ends of a Telnet connection map their own terminal device characteristics to and from the NVT. For example, a program must change all 8-bit ASCII characters to the NVT character set. The NVT is intended to strike a balance between being overly restrictive (not providing some computers a rich enough vocabulary for mapping into their local character sets) and being overly inclusive (penalizing users with modest terminals).

Please refer to RFC 854 for more information on the NVT.

Binary Data

PowerTCP provides full support for binary data transmission. When sending, the following basic Telnet encoding rules are applied:

  1. Every byte of value 255 (IAC) is doubled up into a two-byte (255, 255) value.
  2. Every byte of value 13 (CR) not followed by a byte of value 10 (LF) is transformed into a two-byte (13, 0) value.

For all data received, the reciprocal transformation takes place within the Telnet component. This mechanism, established by RFC 854, enables the transmission of 8-bit binary data over a single Telnet channel.

There is also a TransmitBinary option that can be easily set using the Binary property of the Telnet component. When set to RequestOn, the TransmitBinary option is negotiated for both directions. When in this mode, a naked CR is not padded with a following NULL when data is sent. When data is received, any CR NULL encountered is used unaltered. All other padding (such as the doubling of IAC bytes) remains the same.

Option Negotiation

Option negotiation is the process of two computers agreeing on what features they will or will not provide. Each computer may send and respond to commands. A typical option negotiation session may occur as follows (although over 40 different options might be negotiated):

Computer A | Computer B
1. I will echo back what you send to me. |
 | 2. OK, Do echo back what I send to you.
3. Do suppress go–aheads. |
 | 4. No, I won't suppress go–aheads.

Either machine may initiate option negotiation. One machine may request that the other machine support or not support an option, or inform the machine that it will or won't support an option. The other may then respond that it will or won't support an option, or request that the other computer support or not support an option. The following table describes the four option negotiation commands:

Command | Description
WILL | The sender wants to support the option
WONT | The sender will not support the option
DO | The sender wants the receiver to support the option
DONT | The sender wants the receiver to not support the option

The different pairs of commands and responding commands follow:

Command | Response | Option Used
WILL I will support this option | DO I do support this option | Yes
WILL I will support this option | DONT No, don't support it | No
WONT I won't support this option | DONT OK, don't support it | No
DO Do support this option | WILL OK, I will support it | Yes
DO Do support this option | WONT No, I won't support it | No
DONT Don't support this option | WONT OK, I won't support it | No

Note If a machine does not want an option supported (WONT/DONT), the other machine must comply, responding with a DONT or WONT.

Telnet also provides suboption negotiation—negotiating details about a specific option. An example is the "terminal type" option. For both computers to decide to support the same terminal type, instead of using a different option for each individual terminal type, a suboption is negotiated. A typical suboption negotiation is shown below:

Computer A | Computer B
1. I will support different terminal types. |
 | 2. OK, Do support different terminal types.
3. OK, send your terminal type suboption. |
 | 4. My terminal type suboption is "IBMPC".

Option negotiation and suboption negotiation makes Telnet very flexible and adaptable to many different terminal configurations. Refer to the applicable RFCs for more information on Telnet and Telnet option negotiation.

See Also

Reference
Rexec Component
Rlogin Component
Rsh Component
Telnet Component


MVC Design in Applications

MVC Design in Applications
See Also Send comments on this topic.

Glossary Item Box

Extending the Model-View-Controller Design Philosophy to Applications

One of the features of the new version 4 components is the ease with which applications that utilize these components can be developed using a Model-View-Controller (MVC) design. MVC is a design philosophy that isolates application business logic from the user interface. The following white paper offers a detailed discussion of this design and its application to the PowerTCP and PowerSNMP components:

http://www.dart.com/articles_mvc.aspx

MVC design has been incorporated into some of the more sophisticated PowerTCP and PowerSNMP sample applications, providing two key benefits:

Separation of protocol logic from the user interface

Encapsulating protocol logic in a class separates it from any user interface, providing clean code that can be reused in other projects, with other interfaces.

The Proxy Server sample provides a nice demonstration of this separation. The sample implements several different proxy types; each in its own ProxyModel class. The sample can easily be extended to support additional proxy types by adding additional classes. Encapsulating data and logic pertaining to each different proxy in its own class provides a cleaner project that is easier to digest and maintain.

Simplified storage of runtime state information

Saving runtime state information and persisting this information when the application is terminated is a key feature of many applications. Model classes can be used to facilitate this.

The Tcp Client sample is a typical example.

First, the sample's TcpModel class provides properties for storing runtime data, including session data, security settings, and whether the application should echo data received. This class provides a "ground truth" for the state of the application, instead of the interface itself holding this information. The interface provides a means for updating the model, but is itself "dumb." Also, the encapsulated data can be easily passed to objects such as Settings and Connection forms, which are implemented as interfaces for updating the information contained within the model.

Second, as a serializable class, the model provides a means for easily persisting settings when the application is terminated. In the past, PowerTCP and PowerSNMP samples dedicated large chunks of code for saving and loading application settings, usually in the registry. PowerTCP 4 components have taken a different approach, focusing instead on providing help for serialization. This includes helper functions for Serializing and Deserializing objects to and from streams, as well as providing state information in serializable objects that can be easily stored. The TcpModel class stores two such objects - TcpSession (LocalEndPoint, RemoteEndPoint and Proxy information), and ClientSecurity (TargetHost, Certificates, Protocol, etc).

The sample applications are available as an option during the product installation, and can also be downloaded by clicking on the "Download Samples" link in the Start Menu.

See Also

Reference
Rexec Component
Rlogin Component
Rsh Component
Telnet Component


Asynchronous Operation Obsoleted - PowerTCP Telnet for .NET

[image]
PowerTCP Telnet for .NET
Asynchronous Operation Obsoleted
Send comments on this topic.

The following provides information on using PowerTCP components without blocking the user interface, by executing method calls on worker threads.

Introduction

Traditional PowerTCP asynchronous support provided a means for executing methods on worker threads, but this required a signaling mechanism indicating when operations completed. This resulted in difficult-to-maintain, event-driven code.

With the new version 4.0 design, code is more self-documenting, uses fewer resources, and is more flexible to use. A convenient Start method allows the user to string together multiple blocking methods with the following benefits:

  • Less event-driven code. Methods are called inline, producing self-documenting code that is easier to write and maintain.
  • Marshal methods are included that permit the user to conveniently marshal data back to the UI thread for display in any UI control.
  • A simplified and more efficient interface.
  • Removal of all asynchronous methods. The simple Start method allows users to conveniently execute directly on a worker thread.
  • No need for pseudo-blocking functionality. Problems associated with possible re-entrancy (caused when UI messages are processes while a communication method is in progress) are eliminated.
  • A single worker thread can be used to string together any combination of blocking methods, allowing the user to execute any combination of methods without using multiple worker threads in serial (a requirement of less advanced designs).

The Start Method

All PowerTCP components fully support both blocking and non-blocking use. However, the simple, streamlined interface contain only blocking methods. How can this be?

Each component contains a Start method call, which will execute one or more functions on a separate worker thread. In other words, any function containing blocking calls can be made asynchronous by simply passing it to the Start method. The syntax for this method is simple (C# and VB code snippets follow):

C# Copy Code
telnet1.Start(myBlockingFunction, myObject); //Can also be called without passing an object

private void myBlockingFunction(object myObject)
{
   ...
}

Visual Basic Copy Code
telnet1.Start(AddressOf myBlockingFunction, myObject)  'Can also be called without passing an object

Private Sub myBlockingFunction(ByVal myObject As Object)
   ...
End Sub

There are several advantages to this approach.

First, a function that performs some process is the same, whether it is executed on the UI thread or not. It is no longer necessary to write separate code for blocking and non-blocking applications.

Second, asynchronous code can be written in a sequential, step-by-step manner. It is no longer necessary to implement numerous event handlers, with code that jumps from one handler to another.

Third, it is no longer necessary to keep track of state in event handlers. For example, take the simple case where the following sequence must take place:

  1. Receive data A
  2. Send data B
  3. Receive data C
  4. Send data D

In other asynchronous implementations, an event will fire signifying data received. In this paradigm, a state machine must be implemented in the event handler (if A received then send B, else if C received then send D). With the new approach, a function is written with sequential statement (Receive A, Send B, Receive C, Send D). This produces code that is much easier to debug and to maintain.

Marshaling Data

The above example demonstrates how the Start method provides code that is easy to write, debug and maintain. But now the functions are operating on their own threads. How does the code report back to the main thread?

PowerTCP components have convenient Marshal method calls which are paired with events that fire on the main thread. For example (C# and VB code snippets follow):

C# Copy Code
telnet1.Marshal(telnet1.Read(buffer, 0, 1024), "",  null) //Execute on worker thread

private void telnet1_Data(object sender, DataEventArgs e)
{
   //Whenever data is received, display it in UI element (raised on the UI thread)
   textDisplay.AppendText(e.Data.ToString());
}

Visual Basic Copy Code
telnet1.Marshal(telnet1.Read(buffer, 0, 1024), "", Nothing) 'Execute on worker thread

Private Sub telnet1_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles telnet1.Data
   'Whenever data is received, display it in UI element (raised on the UI thread)
   textDisplay.AppendText(e.Data.ToString())
End Sub

This is an easy-to-use mechanism for marshaling data back to the main thread.

Typical Uses

Below are two typical asynchronous use examples.

In the first example, the developer wants to automate a session in the background, without interfering with the user-interface. A button, textbox and the PowerTCP component are added to the form. Pressing the button will initiate a session with communication displayed in the textbox. The automateSession function, which could also be used in a strictly blocking application, is passed to the Start call to be executed on a worker thread (C# and VB code snippets follow).

C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Event handlers were added in the designer
    //Start the process on a worker thread (no state info passed in)
    telnet1.Start(automateSession, null);
}

private void automateSession(object notUsed)
{
    //This function executes on a worker thread, providing multi-threaded, asynchronous operation
    try
    {
        //Connect
        telnet.Connect("myServer");

        //Login to the server, marshal data to the UI thread
        telnet.Marshal(telnet.Login(new Credentials("myUsername", "myPassword", "$")), "", null);

        //Send a list command
        telnet.Write("ls -la\r");

        //Wait for prompt, marshal data to the UI thread
        telnet.Marshal(telnet.Read("$"), "", null);

        //Send an exit command; server will close the connection
        telnet.Write("exit\r");

        //Read any remaining data before the shutdown
        telnet.Marshal(telnet.ReadToEnd(), "", null);
    }
    catch (Exception ex)
    {
        //Report errors to the UI thread
        telnet.Marshal(ex);
    }
}

void telnet1_Data(object sender, DataEventArgs e)
{
    //Add data received to the textbox
    textBox1.AppendText(e.Data.ToString());
}

void telnet1_Error(object sender, ErrorEventArgs e)
{
    //Add error messages to the textbox
    textBox1.AppendText(e.GetException().Message);
}

void telnet1_StateChanged(object sender, EventArgs e)
{
    //Change appearance of textbox when connected
    textBox1.BackColor = (telnet1.State == ConnectionState.Closed)
        ? SystemColors.ControlDark
        : SystemColors.ControlLight;
}
Visual Basic Copy Code
Private Sub button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles button1.Click
    'Event handlers were added in the designer
    'Start the process on a worker thread (no state info passed in)
    telnet1.Start(AddressOf automateSession, Nothing)
End Sub

Private Sub automateSession(ByVal notUsed As Object)
    'This function executes on a worker thread, providing multi-threaded, asynchronous operation
    Try
        'Connect
        telnet.Connect("myServer")

        'Login to the server, marshal data to the UI thread
        telnet.Marshal(telnet.Login(new Credentials("myUsername", "myPassword", "$")), "",  Nothing)

        'Send a list command
        telnet.Write("ls -la" & Constants.vbCr)

        'Wait for prompt, marshal data to the UI thread
        telnet.Marshal(telnet.Read("$"), "", Nothing)

        'Send an exit command; server will close the connection
        telnet.Write("exit" & Constants.vbCr)

        'Read any remaining data before the shutdown
        telnet.Marshal(telnet.ReadToEnd(), "", Nothing)
    Catch ex As Exception
        'Report errors to the UI thread
        telnet.Marshal(ex)
    End Try
End Sub

Private Sub telnet1_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles telnet1.Data
    'Add data received to the textbox
    textBox1.AppendText(e.Data.ToString())
End Sub

Private Sub telnet1_Error(ByVal sender As Object, ByVal e As ErrorEventArgs) Handles telnet1.Error
    'Add error messages to the textbox
    textBox1.AppendText(e.GetException().Message)
End Sub

Private Sub telnet1_StateChanged(ByVal sender As Object, ByVal e As EventArgs) Handles telnet1.StateChanged
    'Change appearance of textbox when connected
    If (telnet1.State = ConnectionState.Closed) Then
        textBox1.BackColor = SystemColors.ControlDark
    Else
        textBox1.BackColor = SystemColors.ControlLight
    End If
End Sub

In the second example, the developer wants to receive data whenever it is available, but again, without interfering with the ongoing processes of the application. Event handlers (not shown) are implemented as in the first example (C# and VB code snippets follow).

C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
   //Start the process on a worker thread (no state info passed in)
   telnet1.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
   //This function executes on a worker thread, providing multi-threaded, asynchronous operation
   try
   {
       //Connect to the server, marshal data to the UI thread
       telnet.Connect("myServer");

       //Receive data when it is sent by the remote host
       byte[] buffer = new byte[1024];
       while (telnet.State == ConnectionState.Connected)
           telnet.Marshal(telnet.Read(buffer, 0, 1024), "", null);
   }
   catch (Exception ex)
   {
       //Report errors to the UI thread
       telnet.Marshal(ex);
   }
}
Visual Basic Copy Code
Private Sub button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles button1.Click
   'Start the process on a worker thread (no state info passed in)
   telnet1.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
   'This function executes on a worker thread, providing multi-threaded, asynchronous operation
   Try
      'Connect and login to the server, marshal data to the UI thread
      telnet.Connect("myServer")

      'Receive data when it is sent by the remote host
      Dim buffer() As Byte = New Byte(1023){}
      Do While telnet.State = ConnectionState.Connected
         telnet.Marshal(telnet.Read(buffer, 0, 1024), "", Nothing)
      Loop
   Catch ex As Exception
      'Report errors to the UI thread
      telnet.Marshal(ex)
   End Try
End Sub

See Also

Reference

Rexec Component
Rlogin Component
Rsh Component
Telnet Component


Assembly Overview

Dart.Telnet Assembly
See Also Send comments on this topic.

Namespaces

Namespace | Description
Dart.Telnet | Namespace under which the Rexec, Rlogin, Rsh and Telnet components reside.

See Also

Reference

Rexec Component
Rlogin Component
Rsh Component
Telnet Component


Dart.Telnet Namespace

Dart.Telnet Namespace
See Also Inheritance Hierarchy Send comments on this topic.
Namespace under which the Rexec, Rlogin, Rsh and Telnet components reside.

Classes

 | Class | Description
Class | ClientSecurity | Class to be passed to AuthenticateAsClient().
Class | CommandEventArgs | Contains Telnet command event data.
Class | ComponentBase | Base class for PowerTCP Components.
Class | Credentials | Provides a holder for parameters used to login to a remote host.
Class | DartLicenseException | The base class for all Dart component license exceptions.
Class | Data | Encapsulates data read or written.
Class | DataEventArgs | Provides data for the Data event.
Class | DataException | Thrown when the expected data could not be read.
Class | ErrorEventArgs | Provides data for the Error event.
Class | IPEndPoint | Allows user to specify a range of IPEndPoints for local binding. Also resolves hostnames and saves them for future use.
Class | Option | Encapsulates a Telnet option.
Class | OptionCollection | A collection of Option objects.
Class | OptionEventArgs | Contains option event data.
Class | ProtocolException | Used to throw protocol exceptions for upper-layer protocols like FTP, SMTP and POP3.
Class | Proxy | Describes the server proxy, if any, to connect to.
Class | PtyBase | This class provides support for interactive on-line terminal access using controls derived from TextBoxBase.
Class | Rexec | The Rexec component enables use of the remote execution protocol within any .NET application.
Class | Rlogin | The Rlogin component enables use of the remote login protocol within any .NET application.
Class | Rsh | The Rsh component enables use of the remote shell protocol within any .NET application.
Class | Security | Base Security class to be passed to authenticate methods.
Class | Segment | Class used to encapsulate a byte[] segment.
Class | ServerSecurity | Class to be passed to AuthenticateAsServer().
Class | Session | Provides a holder for parameters used to establish a session.
Class | SocketBase | Base class for PowerTCP Components.
Class | SocketOption | Contains socket options that may be set by TCP and UDP sockets. These options are automatically applied to the connection used.
Class | TcpBase | Base class for components utilizing protocols built upon the TCP protocol.
Class | TcpSession | Provides a holder for parameters used to establish a TCP session.
Class | TcpSocketOption | Contains socket options that may be set by TCP sockets.
Class | Telnet | The Telnet component enables use of the Telnet protocol within any .NET application.
Class | UserStateEventArgs | Base class for EventArgs that have a UserState property.

Delegates

 | Delegate | Description
Delegate | ReadAsyncCompleted | Represents the method that will execute on an IO completion thread after data is asynchronously received.

Enumerations

 | Enumeration | Description
Enumeration | Command | Enumerates the TELNET protocol commands that can be sent.
Enumeration | ConnectionState | Defines the possible states of the connection.
Enumeration | DataDirection | Enumerates the directions data travels.
Enumeration | OptionCode | Enumerates the supported Telnet options.
Enumeration | OptionState | Enumerates the current state of an Option object.
Enumeration | ProxyType | Enumerates the proxy support provided by this product.

See Also

Reference

Dart.Telnet Assembly


ClientSecurity Class

[image]
PowerTCP Telnet for .NET
ClientSecurity Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : ClientSecurity Class

Class to be passed to AuthenticateAsClient().

Object Model

ClientSecurity Class

Syntax

Visual Basic (Declaration)
<SerializableAttribute()>
Public Class ClientSecurity
   Inherits Security
Visual Basic (Usage) Copy Code
Dim instance As ClientSecurity
C#
[SerializableAttribute()]
public class ClientSecurity : Security
Managed Extensions for C++
[SerializableAttribute()]
public __gc class ClientSecurity : public Security
C++/CLI
[SerializableAttribute()]
public ref class ClientSecurity : public Security

Inheritance Hierarchy

System.Object
Dart.Telnet.Security
Dart.Telnet.ClientSecurity

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ClientSecurity Members
Dart.Telnet Namespace


ClientSecurity Class Members

[image]
PowerTCP Telnet for .NET
ClientSecurity Class Members
See Also Fields Properties Send comments on this topic.
Dart.Telnet Namespace : ClientSecurity Class

The following tables list the members exposed by ClientSecurity.

Public Constructors

 | Name | Description
public Constructor | ClientSecurity Constructor |
Top

Public Fields

 | Name | Description
public Field | SelectionCallback | The delegate that executes when the server requests a certificate.
public Field | ValidationCallback | The delegate that executes after the server provides its certificate to the client. (Inherited from Dart.Telnet.Security)
Top

Public Properties

 | Name | Description
public Property | Certificates | Gets or sets a collection of client certificates to use during authentication.
public Property | CheckCertificateRevocation | Indicates whether the certificate revocation list is checked during authentication. (Inherited from Dart.Telnet.Security)
public Property | Protocols | Gets or sets the SSLProtocols available for authentication. (Inherited from Dart.Telnet.Security)
public Property | TargetHost | Gets or sets the remote host to be authenticated.
Top

See Also

Reference

ClientSecurity Class
Dart.Telnet Namespace


ClientSecurity Constructor

[image]
PowerTCP Telnet for .NET
ClientSecurity Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > ClientSecurity Class : ClientSecurity Constructor

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New ClientSecurity()
C#
public ClientSecurity()
Managed Extensions for C++
public: ClientSecurity();
C++/CLI
public:
ClientSecurity();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ClientSecurity Class
ClientSecurity Members


ClientSecurity Class Properties

[image]
PowerTCP Telnet for .NET
ClientSecurity Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : ClientSecurity Class

"

For a list of all members of this type, see ClientSecurity members.

"

Public Properties

 | Name | Description
public Property | Certificates | Gets or sets a collection of client certificates to use during authentication.
public Property | CheckCertificateRevocation | Indicates whether the certificate revocation list is checked during authentication. (Inherited from Dart.Telnet.Security)
public Property | Protocols | Gets or sets the SSLProtocols available for authentication. (Inherited from Dart.Telnet.Security)
public Property | TargetHost | Gets or sets the remote host to be authenticated.
Top

See Also

Reference

ClientSecurity Class
Dart.Telnet Namespace


Certificates Property

[image]
PowerTCP Telnet for .NET
Certificates Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ClientSecurity Class : Certificates Property

Gets or sets a collection of client certificates to use during authentication.

Syntax

Visual Basic (Declaration)
Public Property Certificates As X509CertificateCollection
Visual Basic (Usage) Copy Code
Dim instance As ClientSecurity
Dim value As X509CertificateCollection

instance.Certificates = value

value = instance.Certificates
C#
public X509CertificateCollection Certificates {get; set;}
Managed Extensions for C++
public: __property X509CertificateCollection* get_Certificates();
public: __property void set_Certificates(
   X509CertificateCollection* value
);
C++/CLI
public:
property X509CertificateCollection^ Certificates {
   X509CertificateCollection^ get();
   void set (    X509CertificateCollection^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ClientSecurity Class
ClientSecurity Members


TargetHost Property

[image]
PowerTCP Telnet for .NET
TargetHost Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ClientSecurity Class : TargetHost Property

Gets or sets the remote host to be authenticated.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Gets or sets the remote host to be authenticated.")>
Public Property TargetHost As String
Visual Basic (Usage) Copy Code
Dim instance As ClientSecurity
Dim value As String

instance.TargetHost = value

value = instance.TargetHost
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the remote host to be authenticated.")]
public string TargetHost {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the remote host to be authenticated.")]
public: __property string* get_TargetHost();
public: __property void set_TargetHost(
   string* value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the remote host to be authenticated.")]
public:
property String^ TargetHost {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ClientSecurity Class
ClientSecurity Members


ClientSecurity Class Fields

[image]
PowerTCP Telnet for .NET
ClientSecurity Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : ClientSecurity Class

"

For a list of all members of this type, see ClientSecurity members.

"

Public Fields

 | Name | Description
public Field | SelectionCallback | The delegate that executes when the server requests a certificate.
public Field | ValidationCallback | The delegate that executes after the server provides its certificate to the client. (Inherited from Dart.Telnet.Security)
Top

See Also

Reference

ClientSecurity Class
Dart.Telnet Namespace


SelectionCallback Field

[image]
PowerTCP Telnet for .NET
SelectionCallback Field
See Also Send comments on this topic.
Dart.Telnet Namespace > ClientSecurity Class : SelectionCallback Field

The delegate that executes when the server requests a certificate.

Syntax

Visual Basic (Declaration)
Public SelectionCallback As LocalCertificateSelectionCallback
Visual Basic (Usage) Copy Code
Dim instance As ClientSecurity
Dim value As LocalCertificateSelectionCallback

value = instance.SelectionCallback

instance.SelectionCallback = value
C#
public LocalCertificateSelectionCallback SelectionCallback
Managed Extensions for C++
public: LocalCertificateSelectionCallback* SelectionCallback
C++/CLI
public:
LocalCertificateSelectionCallback^ SelectionCallback

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ClientSecurity Class
ClientSecurity Members


CommandEventArgs Class

[image]
PowerTCP Telnet for .NET
CommandEventArgs Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : CommandEventArgs Class

Contains Telnet command event data.

Object Model

CommandEventArgs Class

Syntax

Visual Basic (Declaration)
Public Class CommandEventArgs
   Inherits System.EventArgs
Visual Basic (Usage) Copy Code
Dim instance As CommandEventArgs
C#
public class CommandEventArgs : System.EventArgs
Managed Extensions for C++
public __gc class CommandEventArgs : public System.EventArgs
C++/CLI
public ref class CommandEventArgs : public System.EventArgs

Inheritance Hierarchy

System.Object
System.EventArgs
Dart.Telnet.CommandEventArgs

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

CommandEventArgs Members
Dart.Telnet Namespace


CommandEventArgs Class Members

[image]
PowerTCP Telnet for .NET
CommandEventArgs Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : CommandEventArgs Class

The following tables list the members exposed by CommandEventArgs.

Public Properties

 | Name | Description
public Property | Command | The command sent by the remote host.
public Property | OptionCode | The option pertaining to the received command.
public Property | SubOption | Suboption pertaining to the received command.
Top

Public Methods

 | Name | Description
public Method | ToString | A readable string representing the command.
Top

See Also

Reference

CommandEventArgs Class
Dart.Telnet Namespace


CommandEventArgs Class Methods

[image]
PowerTCP Telnet for .NET
CommandEventArgs Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : CommandEventArgs Class

"

For a list of all members of this type, see CommandEventArgs members.

"

Public Methods

 | Name | Description
public Method | ToString | A readable string representing the command.
Top

See Also

Reference

CommandEventArgs Class
Dart.Telnet Namespace


ToString Method

[image]
PowerTCP Telnet for .NET
ToString Method
See Also Send comments on this topic.
Dart.Telnet Namespace > CommandEventArgs Class : ToString Method

A readable string representing the command.

Syntax

Visual Basic (Declaration)
Public Overrides Function ToString() As String
Visual Basic (Usage) Copy Code
Dim instance As CommandEventArgs
Dim value As String

value = instance.ToString()
C#
public override string ToString()
Managed Extensions for C++
public: string* ToString(); override
C++/CLI
public:
String^ ToString(); override

Return Value

A string containing the command, option and suboption.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

CommandEventArgs Class
CommandEventArgs Members


CommandEventArgs Class Properties

[image]
PowerTCP Telnet for .NET
CommandEventArgs Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : CommandEventArgs Class

"

For a list of all members of this type, see CommandEventArgs members.

"

Public Properties

 | Name | Description
public Property | Command | The command sent by the remote host.
public Property | OptionCode | The option pertaining to the received command.
public Property | SubOption | Suboption pertaining to the received command.
Top

See Also

Reference

CommandEventArgs Class
Dart.Telnet Namespace


Command Property

[image]
PowerTCP Telnet for .NET
Command Property
See Also Send comments on this topic.
Dart.Telnet Namespace > CommandEventArgs Class : Command Property

The command sent by the remote host.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Command As Command
Visual Basic (Usage) Copy Code
Dim instance As CommandEventArgs
Dim value As Command

value = instance.Command
C#
public Command Command {get;}
Managed Extensions for C++
public: __property Command get_Command();
C++/CLI
public:
property Command Command {
   Command get();
}

Remarks

This property represents the command sent by the remote host. For example, if the command from the server was a DO ECHO command (asking the client to enable echoing), this property will be set to Command.Do.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

CommandEventArgs Class
CommandEventArgs Members


OptionCode Property

[image]
PowerTCP Telnet for .NET
OptionCode Property
See Also Send comments on this topic.
Dart.Telnet Namespace > CommandEventArgs Class : OptionCode Property

The option pertaining to the received command.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property OptionCode As OptionCode
Visual Basic (Usage) Copy Code
Dim instance As CommandEventArgs
Dim value As OptionCode

value = instance.OptionCode
C#
public OptionCode OptionCode {get;}
Managed Extensions for C++
public: __property OptionCode get_OptionCode();
C++/CLI
public:
property OptionCode OptionCode {
   OptionCode get();
}

Remarks

This property represents the option to which the command pertains. For example, if the command from the server was a DO ECHO command (asking the client to enable echoing) this property would be set to OptionCode.Echo.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

CommandEventArgs Class
CommandEventArgs Members


SubOption Property

[image]
PowerTCP Telnet for .NET
SubOption Property
See Also Send comments on this topic.
Dart.Telnet Namespace > CommandEventArgs Class : SubOption Property

Suboption pertaining to the received command.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property SubOption As Byte()
Visual Basic (Usage) Copy Code
Dim instance As CommandEventArgs
Dim value() As Byte

value = instance.SubOption
C#
public byte[] SubOption {get;}
Managed Extensions for C++
public: __property byte[]* get_SubOption();
C++/CLI
public:
property array<byte>^ SubOption {
   array<byte>^ get();
}

Property Value

A byte array containing formatted data associated with the option.

Remarks

This property contains optional suboption data. Suboption usage is specific to a limited number of options. For the exact format of the suboption data, refer to the RFC that documents the option in question.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

CommandEventArgs Class
CommandEventArgs Members


ComponentBase Class

[image]
PowerTCP Telnet for .NET
ComponentBase Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : ComponentBase Class

Base class for PowerTCP Components.

Object Model

ComponentBase Class

Syntax

Visual Basic (Declaration)
<ToolboxItemAttribute(ToolboxItemType=, ToolboxItemTypeName="")>
Public Class ComponentBase
   Inherits System.ComponentModel.Component
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
C#
[ToolboxItemAttribute(ToolboxItemType=, ToolboxItemTypeName="")]
public class ComponentBase : System.ComponentModel.Component
Managed Extensions for C++
[ToolboxItemAttribute(ToolboxItemType=, ToolboxItemTypeName="")]
public __gc class ComponentBase : public System.ComponentModel.Component
C++/CLI
[ToolboxItemAttribute(ToolboxItemType=, ToolboxItemTypeName="")]
public ref class ComponentBase : public System.ComponentModel.Component

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Members
Dart.Telnet Namespace


ComponentBase Class Members

[image]
PowerTCP Telnet for .NET
ComponentBase Class Members
See Also Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : ComponentBase Class

The following tables list the members exposed by ComponentBase.

Public Properties

 | Name | Description
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component.
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events).
public Property | Tag | Gets or sets an object that stores any user data.
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object.
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals a string and/or object to the UI thread.
public Method | Serialize | Serialize an object to the provided destination stream.
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnError | Raises the Error event.
protected Method | OnUserState | Raises the UserState event.
Top

Public Events

 | Name | Description
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start.
public Event | UserState | Raised when Marshal(String,Object) is used.
Top

See Also

Reference

ComponentBase Class
Dart.Telnet Namespace


ComponentBase Class Methods

[image]
PowerTCP Telnet for .NET
ComponentBase Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : ComponentBase Class

"

For a list of all members of this type, see ComponentBase members.

"

Public Methods

 | Name | Description
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object.
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals a string and/or object to the UI thread.
public Method | Serialize | Serialize an object to the provided destination stream.
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnError | Raises the Error event.
protected Method | OnUserState | Raises the UserState event.
Top

See Also

Reference

ComponentBase Class
Dart.Telnet Namespace


Deserialize Method

[image]
PowerTCP Telnet for .NET
Deserialize Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : Deserialize Method

serializedObject
The previously serialized object.
Deserialize a previously serialized object.

Syntax

Visual Basic (Declaration)
Public Function Deserialize( _
   ByVal serializedObject As Stream _
) As Object
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim serializedObject As Stream
Dim value As Object

value = instance.Deserialize(serializedObject)
C#
public object Deserialize(
   Stream serializedObject
)
Managed Extensions for C++
public: Object* Deserialize(
   Stream* serializedObject
)
C++/CLI
public:
Object^ Deserialize(
   Stream^ serializedObject
)

Parameters

serializedObject
The previously serialized object.

Remarks

Provides a simple mechanism for restoring a previously serialized state. For example, the state (all runtime parameters) of a Session object could be saved. The provided serializedObject is read from its current position.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


Marshal Method

[image]
PowerTCP Telnet for .NET
Marshal Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : Marshal Method

Marshals a string and/or object to the UI thread.

Overload List

Overload | Description
Marshal(String,Object) | Marshals a string and/or object to the UI thread.
Marshal(Exception) | Marshals an exception to the UI thread.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


Marshal(String,Object) Method

[image]
PowerTCP Telnet for .NET
Marshal(String,Object) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class > Marshal Method : Marshal(String,Object) Method

message
The message to be marshaled.
state
The user state information to be marshaled. Can be null.
Marshals a string and/or object to the UI thread.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Marshal( _
   ByVal message As String, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim message As String
Dim state As Object

instance.Marshal(message, state)
C#
public void Marshal(
   string message,
   object state
)
Managed Extensions for C++
public: void Marshal(
   string* message,
   Object* state
)
C++/CLI
public:
void Marshal(
   String^ message,
   Object^ state
)

Parameters

message
The message to be marshaled.
state
The user state information to be marshaled. Can be null.

Remarks

Used to marshal a string and/or object from a worker thread to the UI thread for typical display purposes. It calls OnUserState, which raises the UserState event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members
Overload List


Marshal(Exception) Method

[image]
PowerTCP Telnet for .NET
Marshal(Exception) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class > Marshal Method : Marshal(Exception) Method

exception
The Exception to be marshaled.
Marshals an exception to the UI thread.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Marshal( _
   ByVal exception As Exception _
)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim exception As Exception

instance.Marshal(exception)
C#
public void Marshal(
   Exception exception
)
Managed Extensions for C++
public: void Marshal(
   Exception* exception
)
C++/CLI
public:
void Marshal(
   Exception^ exception
)

Parameters

exception
The Exception to be marshaled.

Remarks

Used to marshal exceptions from a worker thread to the UI thread for typical display purposes. It calls OnError, which raises the Error event.

When Start is used, unhandled exceptions generated on worker threads are marshaled to the UI thread by this method.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members
Overload List


OnError Method

[image]
PowerTCP Telnet for .NET
OnError Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : OnError Method

e
A ErrorEventArgs object that contains the exception.
Raises the Error event.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnError( _
   ByVal e As ErrorEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim e As ErrorEventArgs

instance.OnError(e)
C#
protected virtual void OnError(
   ErrorEventArgs e
)
Managed Extensions for C++
protected: virtual void OnError(
   ErrorEventArgs* e
)
C++/CLI
protected:
virtual void OnError(
   ErrorEventArgs^ e
)

Parameters

e
A ErrorEventArgs object that contains the exception.

Remarks

If the Synchronizing property is set, this method invokes Error asynchronously on the UI thread. If the Synchronizing property is null, this method invokes the Error event on the executing thread.

OnError allows derived classes to handle the Error event without attaching a delegate, but marshaling is not provided. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnError in a derived class, be sure to call the base class OnError method, so that registered delegates receive the event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


OnUserState Method

[image]
PowerTCP Telnet for .NET
OnUserState Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : OnUserState Method

e
A UserStateEventArgs object that contains the user information.
Raises the UserState event.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnUserState( _
   ByVal e As UserStateEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim e As UserStateEventArgs

instance.OnUserState(e)
C#
protected virtual void OnUserState(
   UserStateEventArgs e
)
Managed Extensions for C++
protected: virtual void OnUserState(
   UserStateEventArgs* e
)
C++/CLI
protected:
virtual void OnUserState(
   UserStateEventArgs^ e
)

Parameters

e
A UserStateEventArgs object that contains the user information.

Remarks

If the Synchronizing property is set, this method invokes UserState asynchronously on the UI thread. If the Synchronizing property is null, this method invokes UserState on the executing thread.

OnUserState allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class, but marshaling is not provided.

Note to Inheritors: When overriding OnUserState in a derived class, be sure to call the base class OnUserState method, so that registered delegates receive the event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


Serialize Method

[image]
PowerTCP Telnet for .NET
Serialize Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : Serialize Method

objectToSerialize
destination
Serialize an object to the provided destination stream.

Syntax

Visual Basic (Declaration)
Public Sub Serialize( _
   ByVal objectToSerialize As Object, _
   ByVal destination As Stream _
)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim objectToSerialize As Object
Dim destination As Stream

instance.Serialize(objectToSerialize, destination)
C#
public void Serialize(
   object objectToSerialize,
   Stream destination
)
Managed Extensions for C++
public: void Serialize(
   Object* objectToSerialize,
   Stream* destination
)
C++/CLI
public:
void Serialize(
   Object^ objectToSerialize,
   Stream^ destination
)

Parameters

objectToSerialize
destination

Return Value

System.IO.MemoryStream.

Remarks

Can be used at runtime to persist the state of an object. For example, all runtime parameters of a Session object could be saved.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


ComponentBase Class Properties

[image]
PowerTCP Telnet for .NET
ComponentBase Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : ComponentBase Class

"

For a list of all members of this type, see ComponentBase members.

"

Public Properties

 | Name | Description
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component.
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events).
public Property | Tag | Gets or sets an object that stores any user data.
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

ComponentBase Class
Dart.Telnet Namespace


Encoding Property

[image]
PowerTCP Telnet for .NET
Encoding Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : Encoding Property

Character encoding used by the component.

Syntax

Visual Basic (Declaration)
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)>
<BrowsableAttribute(False)>
Public Property Encoding As Encoding
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim value As Encoding

instance.Encoding = value

value = instance.Encoding
C#
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)]
[BrowsableAttribute(false)]
public Encoding Encoding {get; set;}
Managed Extensions for C++
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)]
[BrowsableAttribute(false)]
public: __property Encoding* get_Encoding();
public: __property void set_Encoding(
   Encoding* value
);
C++/CLI
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)]
[BrowsableAttribute(false)]
public:
property Encoding^ Encoding {
   Encoding^ get();
   void set (    Encoding^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


SynchronizingObject Property

[image]
PowerTCP Telnet for .NET
SynchronizingObject Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : SynchronizingObject Property

Gets or sets the object used to marshal data to the UI thread (for raising events).

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Marshaling Data")>
<DefaultValueAttribute()>
<DescriptionAttribute("The object used to marshal data to the UI thread (for raising events).")>
Public Property SynchronizingObject As ISynchronizeInvoke
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim value As ISynchronizeInvoke

instance.SynchronizingObject = value

value = instance.SynchronizingObject
C#
[CategoryAttribute("Marshaling Data")]
[DefaultValueAttribute()]
[DescriptionAttribute("The object used to marshal data to the UI thread (for raising events).")]
public ISynchronizeInvoke SynchronizingObject {get; set;}
Managed Extensions for C++
[CategoryAttribute("Marshaling Data")]
[DefaultValueAttribute()]
[DescriptionAttribute("The object used to marshal data to the UI thread (for raising events).")]
public: __property ISynchronizeInvoke* get_SynchronizingObject();
public: __property void set_SynchronizingObject(
   ISynchronizeInvoke* value
);
C++/CLI
[CategoryAttribute("Marshaling Data")]
[DefaultValueAttribute()]
[DescriptionAttribute("The object used to marshal data to the UI thread (for raising events).")]
public:
property ISynchronizeInvoke^ SynchronizingObject {
   ISynchronizeInvoke^ get();
   void set (    ISynchronizeInvoke^ value);
}

Remarks

This property determines the thread on which the component's event handlers are raised. If set to a UI control, events are raised on the UI thread. If null, events are raised on the current thread.

This property is automatically set to the containing control when used in the Windows Forms designer. When a derived class is dynamically created this property must be set if marshaling to the UI thread is desired.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


Tag Property

[image]
PowerTCP Telnet for .NET
Tag Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : Tag Property

Gets or sets an object that stores any user data.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<BrowsableAttribute(False)>
Public Property Tag As Object
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim value As Object

instance.Tag = value

value = instance.Tag
C#
[DefaultValueAttribute()]
[BrowsableAttribute(false)]
public object Tag {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[BrowsableAttribute(false)]
public: __property Object* get_Tag();
public: __property void set_Tag(
   Object* value
);
C++/CLI
[DefaultValueAttribute()]
[BrowsableAttribute(false)]
public:
property Object^ Tag {
   Object^ get();
   void set (    Object^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


ComponentBase Class Events

[image]
PowerTCP Telnet for .NET
ComponentBase Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : ComponentBase Class

"

For a list of all members of this type, see ComponentBase members.

"

Public Events

 | Name | Description
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start.
public Event | UserState | Raised when Marshal(String,Object) is used.
Top

See Also

Reference

ComponentBase Class
Dart.Telnet Namespace


Error Event

[image]
PowerTCP Telnet for .NET
Error Event
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : Error Event

Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Marshaled Data")>
<DescriptionAttribute("Raised when an unhandled Exception is thrown on a worker thread or Marshal(Exception) is used.")>
Public Event Error As EventHandler(Of ErrorEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim handler As EventHandler(Of ErrorEventArgs)

AddHandler instance.Error, handler
C#
[CategoryAttribute("Marshaled Data")]
[DescriptionAttribute("Raised when an unhandled Exception is thrown on a worker thread or Marshal(Exception) is used.")]
public event EventHandler<ErrorEventArgs> Error
Managed Extensions for C++
[CategoryAttribute("Marshaled Data")]
[DescriptionAttribute("Raised when an unhandled Exception is thrown on a worker thread or Marshal(Exception) is used.")]
public: __event EventHandler<ErrorEventArgs*>* Error
C++/CLI
[CategoryAttribute("Marshaled Data")]
[DescriptionAttribute("Raised when an unhandled Exception is thrown on a worker thread or Marshal(Exception) is used.")]
public:
event EventHandler<ErrorEventArgs^>^ Error

Remarks

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


UserState Event

[image]
PowerTCP Telnet for .NET
UserState Event
See Also Send comments on this topic.
Dart.Telnet Namespace > ComponentBase Class : UserState Event

Raised when Marshal(String,Object) is used.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Marshaled Data")>
<DescriptionAttribute("Raised when Marshal(string, object) is used.")>
Public Event UserState As EventHandler(Of UserStateEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As ComponentBase
Dim handler As EventHandler(Of UserStateEventArgs)

AddHandler instance.UserState, handler
C#
[CategoryAttribute("Marshaled Data")]
[DescriptionAttribute("Raised when Marshal(string, object) is used.")]
public event EventHandler<UserStateEventArgs> UserState
Managed Extensions for C++
[CategoryAttribute("Marshaled Data")]
[DescriptionAttribute("Raised when Marshal(string, object) is used.")]
public: __event EventHandler<UserStateEventArgs*>* UserState
C++/CLI
[CategoryAttribute("Marshaled Data")]
[DescriptionAttribute("Raised when Marshal(string, object) is used.")]
public:
event EventHandler<UserStateEventArgs^>^ UserState

Event Data

The event handler receives an argument of type UserStateEventArgs containing data related to this event. The following UserStateEventArgs properties provide information specific to this event.

Property | Description
Message | Gets the user message provided by the Message event.
UserState | Gets the user state provided by the UserState event.

Remarks

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ComponentBase Class
ComponentBase Members


Credentials Class

[image]
PowerTCP Telnet for .NET
Credentials Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Credentials Class

Provides a holder for parameters used to login to a remote host.

Object Model

Credentials Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class Credentials
Visual Basic (Usage) Copy Code
Dim instance As Credentials
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class Credentials
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class Credentials
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class Credentials

Inheritance Hierarchy

System.Object
Dart.Telnet.Credentials

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Members
Dart.Telnet Namespace


Credentials Class Members

[image]
PowerTCP Telnet for .NET
Credentials Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : Credentials Class

The following tables list the members exposed by Credentials.

Public Constructors

 | Name | Description
public Constructor | Credentials Constructor | Overloaded.
Top

Public Properties

 | Name | Description
public Property | CommandPrompt | Defines the command prompt to look for after login. An empty string indicates the Login should return immediately.
public Property | Password | Defines the password used during login.
public Property | PasswordPrompt | Defines the password prompt to look for after login.
public Property | PromptTimeout | Defines the timeout period while waiting for prompts to be read.
public Property | Username | Defines the username used during login.
public Property | UsernamePrompt | Defines the username prompt to look for during login.
Top

See Also

Reference

Credentials Class
Dart.Telnet Namespace


Credentials Constructor

[image]
PowerTCP Telnet for .NET
Credentials Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : Credentials Constructor

Overload List

Overload | Description
Credentials Constructor() | Default constructor for Credentials.
Credentials Constructor(String,String,String) | Constructor for Credentials with username, password and command prompt parameters.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


Credentials Constructor()

[image]
PowerTCP Telnet for .NET
Credentials Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class > Credentials Constructor : Credentials Constructor()

Default constructor for Credentials.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Credentials()
C#
public Credentials()
Managed Extensions for C++
public: Credentials();
C++/CLI
public:
Credentials();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members
Overload List


Credentials Constructor(String,String,String)

[image]
PowerTCP Telnet for .NET
Credentials Constructor(String,String,String)
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class > Credentials Constructor : Credentials Constructor(String,String,String)

username
The username used during login.
password
The password used during login.
commandPrompt
The command prompt to look for after login.
Constructor for Credentials with username, password and command prompt parameters.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal username As String, _
   ByVal password As String, _
   ByVal commandPrompt As String _
)
Visual Basic (Usage) Copy Code
Dim username As String
Dim password As String
Dim commandPrompt As String

Dim instance As New Credentials(username, password, commandPrompt)
C#
public Credentials(
   string username,
   string password,
   string commandPrompt
)
Managed Extensions for C++
public: Credentials(
   string* username,
   string* password,
   string* commandPrompt
)
C++/CLI
public:
Credentials(
   String^ username,
   String^ password,
   String^ commandPrompt
)

Parameters

username
The username used during login.
password
The password used during login.
commandPrompt
The command prompt to look for after login.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members
Overload List


Credentials Class Properties

[image]
PowerTCP Telnet for .NET
Credentials Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Credentials Class

"

For a list of all members of this type, see Credentials members.

"

Public Properties

 | Name | Description
public Property | CommandPrompt | Defines the command prompt to look for after login. An empty string indicates the Login should return immediately.
public Property | Password | Defines the password used during login.
public Property | PasswordPrompt | Defines the password prompt to look for after login.
public Property | PromptTimeout | Defines the timeout period while waiting for prompts to be read.
public Property | Username | Defines the username used during login.
public Property | UsernamePrompt | Defines the username prompt to look for during login.
Top

See Also

Reference

Credentials Class
Dart.Telnet Namespace


CommandPrompt Property

[image]
PowerTCP Telnet for .NET
CommandPrompt Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : CommandPrompt Property

Defines the command prompt to look for after login. An empty string indicates the Login should return immediately.

Syntax

Visual Basic (Declaration)
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<CategoryAttribute("Design")>
<DescriptionAttribute("Defines the command prompt to look for after login.")>
Public Property CommandPrompt As String
Visual Basic (Usage) Copy Code
Dim instance As Credentials
Dim value As String

instance.CommandPrompt = value

value = instance.CommandPrompt
C#
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the command prompt to look for after login.")]
public string CommandPrompt {get; set;}
Managed Extensions for C++
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the command prompt to look for after login.")]
public: __property string* get_CommandPrompt();
public: __property void set_CommandPrompt(
   string* value
);
C++/CLI
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the command prompt to look for after login.")]
public:
property String^ CommandPrompt {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


Password Property

[image]
PowerTCP Telnet for .NET
Password Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : Password Property

Defines the password used during login.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Design")>
<DescriptionAttribute("Defines the password used during login.")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
Public Property Password As String
Visual Basic (Usage) Copy Code
Dim instance As Credentials
Dim value As String

instance.Password = value

value = instance.Password
C#
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the password used during login.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public string Password {get; set;}
Managed Extensions for C++
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the password used during login.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public: __property string* get_Password();
public: __property void set_Password(
   string* value
);
C++/CLI
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the password used during login.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public:
property String^ Password {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


PasswordPrompt Property

[image]
PowerTCP Telnet for .NET
PasswordPrompt Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : PasswordPrompt Property

Defines the password prompt to look for after login.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Defines the password prompt to look for during login.")>
<CategoryAttribute("Design")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
Public Property PasswordPrompt As String
Visual Basic (Usage) Copy Code
Dim instance As Credentials
Dim value As String

instance.PasswordPrompt = value

value = instance.PasswordPrompt
C#
[DescriptionAttribute("Defines the password prompt to look for during login.")]
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public string PasswordPrompt {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Defines the password prompt to look for during login.")]
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public: __property string* get_PasswordPrompt();
public: __property void set_PasswordPrompt(
   string* value
);
C++/CLI
[DescriptionAttribute("Defines the password prompt to look for during login.")]
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public:
property String^ PasswordPrompt {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


PromptTimeout Property

[image]
PowerTCP Telnet for .NET
PromptTimeout Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : PromptTimeout Property

Defines the timeout period while waiting for prompts to be read.

Syntax

Visual Basic (Declaration)
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<CategoryAttribute("Design")>
<DescriptionAttribute("Defines the timeout period while waiting for prompts to be read.")>
Public Property PromptTimeout As Integer
Visual Basic (Usage) Copy Code
Dim instance As Credentials
Dim value As Integer

instance.PromptTimeout = value

value = instance.PromptTimeout
C#
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the timeout period while waiting for prompts to be read.")]
public int PromptTimeout {get; set;}
Managed Extensions for C++
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the timeout period while waiting for prompts to be read.")]
public: __property int get_PromptTimeout();
public: __property void set_PromptTimeout(
   int value
);
C++/CLI
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the timeout period while waiting for prompts to be read.")]
public:
property int PromptTimeout {
   int get();
   void set (    int value);
}

Property Value

The default value is 6000 (ms).

Remarks

This property overrides SocketOption.ReceiveTimeout during the Login call.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


Username Property

[image]
PowerTCP Telnet for .NET
Username Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : Username Property

Defines the username used during login.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Design")>
<DescriptionAttribute("Defines the username used during login.")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
Public Property Username As String
Visual Basic (Usage) Copy Code
Dim instance As Credentials
Dim value As String

instance.Username = value

value = instance.Username
C#
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the username used during login.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public string Username {get; set;}
Managed Extensions for C++
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the username used during login.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public: __property string* get_Username();
public: __property void set_Username(
   string* value
);
C++/CLI
[CategoryAttribute("Design")]
[DescriptionAttribute("Defines the username used during login.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public:
property String^ Username {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


UsernamePrompt Property

[image]
PowerTCP Telnet for .NET
UsernamePrompt Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Credentials Class : UsernamePrompt Property

Defines the username prompt to look for during login.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Defines the username prompt to look for during login.")>
<CategoryAttribute("Design")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
Public Property UsernamePrompt As String
Visual Basic (Usage) Copy Code
Dim instance As Credentials
Dim value As String

instance.UsernamePrompt = value

value = instance.UsernamePrompt
C#
[DescriptionAttribute("Defines the username prompt to look for during login.")]
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public string UsernamePrompt {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Defines the username prompt to look for during login.")]
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public: __property string* get_UsernamePrompt();
public: __property void set_UsernamePrompt(
   string* value
);
C++/CLI
[DescriptionAttribute("Defines the username prompt to look for during login.")]
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public:
property String^ UsernamePrompt {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Credentials Class
Credentials Members


DartLicenseException Class

[image]
PowerTCP Telnet for .NET
DartLicenseException Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : DartLicenseException Class

The base class for all Dart component license exceptions.

Object Model

DartLicenseException Class

Syntax

Visual Basic (Declaration)
Public MustInherit Class DartLicenseException
   Inherits System.Exception
Visual Basic (Usage) Copy Code
Dim instance As DartLicenseException
C#
public abstract class DartLicenseException : System.Exception
Managed Extensions for C++
public __gc abstract class DartLicenseException : public System.Exception
C++/CLI
public ref class DartLicenseException abstract : public System.Exception

Remarks

Use the DartLicenseException class to catch runtime licensing exceptions. These exceptions are thrown at component creation time and during access of select properites or methods. The Message property will provide a description of the specific licensing problem encountered. The InnerException property should also be examined for additional details.

Inheritance Hierarchy

System.Object
System.Exception
Dart.Telnet.DartLicenseException

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

DartLicenseException Members
Dart.Telnet Namespace


DartLicenseException Class Members

[image]
PowerTCP Telnet for .NET
DartLicenseException Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : DartLicenseException Class

The following tables list the members exposed by DartLicenseException.

Public Properties

 | Name | Description
public Property | Data | Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Inherited from System.Exception)
public Property | HelpLink | Gets or sets a link to the help file associated with this exception. (Inherited from System.Exception)
public Property | InnerException | Gets the System.Exception instance that caused the current exception. (Inherited from System.Exception)
public Property | Message | Gets a message that describes the current exception. (Inherited from System.Exception)
public Property | Source | Gets or sets the name of the application or the object that causes the error. (Inherited from System.Exception)
public Property | StackTrace | Gets a string representation of the frames on the call stack at the time the current exception was thrown. (Inherited from System.Exception)
public Property | TargetSite | Gets the method that throws the current exception. (Inherited from System.Exception)
Top

Protected Properties

 | Name | Description
protected Property | HResult | Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Inherited from System.Exception)
Top

Public Methods

 | Name | Description
public Method | GetBaseException | When overridden in a derived class, returns the System.Exception that is the root cause of one or more subsequent exceptions. (Inherited from System.Exception)
public Method | GetObjectData | When overridden in a derived class, sets the System.Runtime.Serialization.SerializationInfo with information about the exception. (Inherited from System.Exception)
public Method | GetType | Gets the runtime type of the current instance. (Inherited from System.Exception)
Top

See Also

Reference

DartLicenseException Class
Dart.Telnet Namespace


Data Class

[image]
PowerTCP Telnet for .NET
Data Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Data Class

Encapsulates data read or written.

Object Model

Data Class

Syntax

Visual Basic (Declaration)
Public Class Data
   Inherits Segment
Visual Basic (Usage) Copy Code
Dim instance As Data
C#
public class Data : Segment
Managed Extensions for C++
public __gc class Data : public Segment
C++/CLI
public ref class Data : public Segment

Inheritance Hierarchy

System.Object
Dart.Telnet.Segment
Dart.Telnet.Data

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Data Members
Dart.Telnet Namespace


Data Class Members

[image]
PowerTCP Telnet for .NET
Data Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : Data Class

The following tables list the members exposed by Data.

Public Properties

 | Name | Description
public Property | Buffer | Gets the buffer that holds data. (Inherited from Dart.Telnet.Segment)
public Property | Count | Byte count of data. (Inherited from Dart.Telnet.Segment)
public Property | Delimiter | Gets the delimiter string used by the ReadToDelimiter method.
public Property | Direction | Indicates whether data is inbound or outbound.
public Property | Encoding | Gets the character encoding used by the Data object.
public Property | Offset | The offset into the buffer where the data starts. (Inherited from Dart.Telnet.Segment)
Top

Public Methods

 | Name | Description
public Method | ToString | Gets the data as a decoded string.
Top

See Also

Reference

Data Class
Dart.Telnet Namespace


Data Class Methods

[image]
PowerTCP Telnet for .NET
Data Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : Data Class

"

For a list of all members of this type, see Data members.

"

Public Methods

 | Name | Description
public Method | ToString | Gets the data as a decoded string.
Top

See Also

Reference

Data Class
Dart.Telnet Namespace


ToString Method

[image]
PowerTCP Telnet for .NET
ToString Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Data Class : ToString Method

Gets the data as a decoded string.

Syntax

Visual Basic (Declaration)
Public Overrides Function ToString() As String
Visual Basic (Usage) Copy Code
Dim instance As Data
Dim value As String

value = instance.ToString()
C#
public override string ToString()
Managed Extensions for C++
public: string* ToString(); override
C++/CLI
public:
String^ ToString(); override

Return Value

The System.Buffer decoded into a string using the Encoding property.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Data Class
Data Members


Data Class Properties

[image]
PowerTCP Telnet for .NET
Data Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Data Class

"

For a list of all members of this type, see Data members.

"

Public Properties

 | Name | Description
public Property | Buffer | Gets the buffer that holds data. (Inherited from Dart.Telnet.Segment)
public Property | Count | Byte count of data. (Inherited from Dart.Telnet.Segment)
public Property | Delimiter | Gets the delimiter string used by the ReadToDelimiter method.
public Property | Direction | Indicates whether data is inbound or outbound.
public Property | Encoding | Gets the character encoding used by the Data object.
public Property | Offset | The offset into the buffer where the data starts. (Inherited from Dart.Telnet.Segment)
Top

See Also

Reference

Data Class
Dart.Telnet Namespace


Delimiter Property

[image]
PowerTCP Telnet for .NET
Delimiter Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Data Class : Delimiter Property

Gets the delimiter string used by the ReadToDelimiter method.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Delimiter As String
Visual Basic (Usage) Copy Code
Dim instance As Data
Dim value As String

value = instance.Delimiter
C#
public string Delimiter {get;}
Managed Extensions for C++
public: __property string* get_Delimiter();
C++/CLI
public:
property String^ Delimiter {
   String^ get();
}

Property Value

Null if no delimiter was used in the Read call or no delimiter was found. Otherwise, the delimiter string.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Data Class
Data Members


Direction Property

[image]
PowerTCP Telnet for .NET
Direction Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Data Class : Direction Property

Indicates whether data is inbound or outbound.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Direction As DataDirection
Visual Basic (Usage) Copy Code
Dim instance As Data
Dim value As DataDirection

value = instance.Direction
C#
public DataDirection Direction {get;}
Managed Extensions for C++
public: __property DataDirection get_Direction();
C++/CLI
public:
property DataDirection Direction {
   DataDirection get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Data Class
Data Members


Encoding Property

[image]
PowerTCP Telnet for .NET
Encoding Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Data Class : Encoding Property

Gets the character encoding used by the Data object.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Encoding As Encoding
Visual Basic (Usage) Copy Code
Dim instance As Data
Dim value As Encoding

value = instance.Encoding
C#
public Encoding Encoding {get;}
Managed Extensions for C++
public: __property Encoding* get_Encoding();
C++/CLI
public:
property Encoding^ Encoding {
   Encoding^ get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Data Class
Data Members


DataEventArgs Class

[image]
PowerTCP Telnet for .NET
DataEventArgs Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : DataEventArgs Class

Provides data for the Data event.

Object Model

DataEventArgs ClassData Class

Syntax

Visual Basic (Declaration)
Public Class DataEventArgs
   Inherits UserStateEventArgs
Visual Basic (Usage) Copy Code
Dim instance As DataEventArgs
C#
public class DataEventArgs : UserStateEventArgs
Managed Extensions for C++
public __gc class DataEventArgs : public UserStateEventArgs
C++/CLI
public ref class DataEventArgs : public UserStateEventArgs

Inheritance Hierarchy

System.Object
System.EventArgs
Dart.Telnet.UserStateEventArgs
Dart.Telnet.DataEventArgs

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

DataEventArgs Members
Dart.Telnet Namespace


DataEventArgs Class Members

[image]
PowerTCP Telnet for .NET
DataEventArgs Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : DataEventArgs Class

The following tables list the members exposed by DataEventArgs.

Public Properties

 | Name | Description
public Property | Data | Gets data provided by Data and Log events.
public Property | Message | Gets the user message provided by the Message event. (Inherited from Dart.Telnet.UserStateEventArgs)
public Property | UserState | Gets the user state provided by the UserState event. (Inherited from Dart.Telnet.UserStateEventArgs)
Top

Public Methods

 | Name | Description
public Method | ToString | Gets the Data property as a decoded string.
Top

See Also

Reference

DataEventArgs Class
Dart.Telnet Namespace


DataEventArgs Class Methods

[image]
PowerTCP Telnet for .NET
DataEventArgs Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : DataEventArgs Class

"

For a list of all members of this type, see DataEventArgs members.

"

Public Methods

 | Name | Description
public Method | ToString | Gets the Data property as a decoded string.
Top

See Also

Reference

DataEventArgs Class
Dart.Telnet Namespace


ToString Method

[image]
PowerTCP Telnet for .NET
ToString Method
See Also Send comments on this topic.
Dart.Telnet Namespace > DataEventArgs Class : ToString Method

Gets the Data property as a decoded string.

Syntax

Visual Basic (Declaration)
Public Overrides Function ToString() As String
Visual Basic (Usage) Copy Code
Dim instance As DataEventArgs
Dim value As String

value = instance.ToString()
C#
public override string ToString()
Managed Extensions for C++
public: string* ToString(); override
C++/CLI
public:
String^ ToString(); override

Return Value

The Data.Buffer decoded into a string using the Data.Encoding specified.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

DataEventArgs Class
DataEventArgs Members


DataEventArgs Class Properties

[image]
PowerTCP Telnet for .NET
DataEventArgs Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : DataEventArgs Class

"

For a list of all members of this type, see DataEventArgs members.

"

Public Properties

 | Name | Description
public Property | Data | Gets data provided by Data and Log events.
public Property | Message | Gets the user message provided by the Message event. (Inherited from Dart.Telnet.UserStateEventArgs)
public Property | UserState | Gets the user state provided by the UserState event. (Inherited from Dart.Telnet.UserStateEventArgs)
Top

See Also

Reference

DataEventArgs Class
Dart.Telnet Namespace


Data Property

[image]
PowerTCP Telnet for .NET
Data Property
See Also Send comments on this topic.
Dart.Telnet Namespace > DataEventArgs Class : Data Property

Gets data provided by Data and Log events.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Data As Data
Visual Basic (Usage) Copy Code
Dim instance As DataEventArgs
Dim value As Data

value = instance.Data
C#
public Data Data {get;}
Managed Extensions for C++
public: __property Data* get_Data();
C++/CLI
public:
property Data^ Data {
   Data^ get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

DataEventArgs Class
DataEventArgs Members


DataException Class

[image]
PowerTCP Telnet for .NET
DataException Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : DataException Class

Thrown when the expected data could not be read.

Object Model

DataException Class

Syntax

Visual Basic (Declaration)
Public Class DataException
   Inherits System.ApplicationException
Visual Basic (Usage) Copy Code
Dim instance As DataException
C#
public class DataException : System.ApplicationException
Managed Extensions for C++
public __gc class DataException : public System.ApplicationException
C++/CLI
public ref class DataException : public System.ApplicationException

Inheritance Hierarchy

System.Object
System.Exception
System.ApplicationException
Dart.Telnet.DataException

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

DataException Members
Dart.Telnet Namespace


DataException Class Members

[image]
PowerTCP Telnet for .NET
DataException Class Members
See Also Fields Properties Methods Send comments on this topic.
Dart.Telnet Namespace : DataException Class

The following tables list the members exposed by DataException.

Public Fields

 | Name | Description
public Field | DataRead | Data read from the socket before a failure generated this exception.
Top

Public Properties

 | Name | Description
public Property | Data | Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Inherited from System.Exception)
public Property | HelpLink | Gets or sets a link to the help file associated with this exception. (Inherited from System.Exception)
public Property | InnerException | Gets the System.Exception instance that caused the current exception. (Inherited from System.Exception)
public Property | Message | Gets a message that describes the current exception. (Inherited from System.Exception)
public Property | Source | Gets or sets the name of the application or the object that causes the error. (Inherited from System.Exception)
public Property | StackTrace | Gets a string representation of the frames on the call stack at the time the current exception was thrown. (Inherited from System.Exception)
public Property | TargetSite | Gets the method that throws the current exception. (Inherited from System.Exception)
Top

Protected Properties

 | Name | Description
protected Property | HResult | Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Inherited from System.Exception)
Top

Public Methods

 | Name | Description
public Method | GetBaseException | When overridden in a derived class, returns the System.Exception that is the root cause of one or more subsequent exceptions. (Inherited from System.Exception)
public Method | GetObjectData | When overridden in a derived class, sets the System.Runtime.Serialization.SerializationInfo with information about the exception. (Inherited from System.Exception)
public Method | GetType | Gets the runtime type of the current instance. (Inherited from System.Exception)
Top

See Also

Reference

DataException Class
Dart.Telnet Namespace


DataException Class Fields

[image]
PowerTCP Telnet for .NET
DataException Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : DataException Class

"

For a list of all members of this type, see DataException members.

"

Public Fields

 | Name | Description
public Field | DataRead | Data read from the socket before a failure generated this exception.
Top

See Also

Reference

DataException Class
Dart.Telnet Namespace


DataRead Field

[image]
PowerTCP Telnet for .NET
DataRead Field
See Also Send comments on this topic.
Dart.Telnet Namespace > DataException Class : DataRead Field

Data read from the socket before a failure generated this exception.

Syntax

Visual Basic (Declaration)
Public ReadOnly DataRead As Data
Visual Basic (Usage) Copy Code
Dim instance As DataException
Dim value As Data

value = instance.DataRead
C#
public readonly Data DataRead
Managed Extensions for C++
public: readonly Data* DataRead
C++/CLI
public:
readonly Data^ DataRead

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

DataException Class
DataException Members


ErrorEventArgs Class

[image]
PowerTCP Telnet for .NET
ErrorEventArgs Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : ErrorEventArgs Class

Provides data for the Error event.

Object Model

ErrorEventArgs Class

Syntax

Visual Basic (Declaration)
Public Class ErrorEventArgs
   Inherits System.EventArgs
Visual Basic (Usage) Copy Code
Dim instance As ErrorEventArgs
C#
public class ErrorEventArgs : System.EventArgs
Managed Extensions for C++
public __gc class ErrorEventArgs : public System.EventArgs
C++/CLI
public ref class ErrorEventArgs : public System.EventArgs

Inheritance Hierarchy

System.Object
System.EventArgs
Dart.Telnet.ErrorEventArgs

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ErrorEventArgs Members
Dart.Telnet Namespace


ErrorEventArgs Class Members

[image]
PowerTCP Telnet for .NET
ErrorEventArgs Class Members
See Also Methods Send comments on this topic.
Dart.Telnet Namespace : ErrorEventArgs Class

The following tables list the members exposed by ErrorEventArgs.

Public Constructors

 | Name | Description
public Constructor | ErrorEventArgs Constructor | Save an exception within this class.
Top

Public Methods

 | Name | Description
public Method | GetException | Returns the Exception marshaled to the UI thread.
Top

See Also

Reference

ErrorEventArgs Class
Dart.Telnet Namespace


ErrorEventArgs Constructor

[image]
PowerTCP Telnet for .NET
ErrorEventArgs Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > ErrorEventArgs Class : ErrorEventArgs Constructor

exception
Exception to save.
Save an exception within this class.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal exception As Exception _
)
Visual Basic (Usage) Copy Code
Dim exception As Exception

Dim instance As New ErrorEventArgs(exception)
C#
public ErrorEventArgs(
   Exception exception
)
Managed Extensions for C++
public: ErrorEventArgs(
   Exception* exception
)
C++/CLI
public:
ErrorEventArgs(
   Exception^ exception
)

Parameters

exception
Exception to save.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ErrorEventArgs Class
ErrorEventArgs Members


ErrorEventArgs Class Methods

[image]
PowerTCP Telnet for .NET
ErrorEventArgs Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : ErrorEventArgs Class

"

For a list of all members of this type, see ErrorEventArgs members.

"

Public Methods

 | Name | Description
public Method | GetException | Returns the Exception marshaled to the UI thread.
Top

See Also

Reference

ErrorEventArgs Class
Dart.Telnet Namespace


GetException Method

[image]
PowerTCP Telnet for .NET
GetException Method
See Also Send comments on this topic.
Dart.Telnet Namespace > ErrorEventArgs Class : GetException Method

Returns the Exception marshaled to the UI thread.

Syntax

Visual Basic (Declaration)
Public Function GetException() As Exception
Visual Basic (Usage) Copy Code
Dim instance As ErrorEventArgs
Dim value As Exception

value = instance.GetException()
C#
public Exception GetException()
Managed Extensions for C++
public: Exception* GetException();
C++/CLI
public:
Exception^ GetException();

Return Value

Exception

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ErrorEventArgs Class
ErrorEventArgs Members


IPEndPoint Class

[image]
PowerTCP Telnet for .NET
IPEndPoint Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : IPEndPoint Class

Allows user to specify a range of IPEndPoints for local binding. Also resolves hostnames and saves them for future use.

Object Model

IPEndPoint Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class IPEndPoint
   Inherits System.Net.IPEndPoint
Visual Basic (Usage) Copy Code
Dim instance As IPEndPoint
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class IPEndPoint : System.Net.IPEndPoint
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class IPEndPoint : public System.Net.IPEndPoint
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class IPEndPoint : public System.Net.IPEndPoint

Remarks

Used to specify a local IPEndPoint using a possible range of ports. It is useful for configuring a connection for firewall penetration. The default value of Address is IPAddress.Any and the default value of Port and Range are 0.

Inheritance Hierarchy

System.Object
System.Net.EndPoint
System.Net.IPEndPoint
Dart.Telnet.IPEndPoint

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Members
Dart.Telnet Namespace


IPEndPoint Class Members

[image]
PowerTCP Telnet for .NET
IPEndPoint Class Members
See Also Fields Properties Methods Send comments on this topic.
Dart.Telnet Namespace : IPEndPoint Class

The following tables list the members exposed by IPEndPoint.

Public Constructors

 | Name | Description
public Constructor | IPEndPoint Constructor | Overloaded.
Top

Public Fields

 | Name | Description
public Field | Range | The socket will be bound to a port between IPEndPoint.Port and (IPEndPoint.Port + Range), inclusive.
Top

Public Properties

 | Name | Description
public Property | Address | Gets or sets the IP address of the endpoint. (Inherited from System.Net.IPEndPoint)
public Property | AddressFamily | Gets the address family to which the endpoint belongs. (Inherited from System.Net.EndPoint)
public Property | HostNameOrAddress | Gets or sets the host name or address resolved to create this IPEndPoint.
public Property | Port | Gets or sets the port number of the endpoint.
Top

Public Methods

 | Name | Description
public Method | Create | Creates an System.Net.EndPoint instance from a System.Net.SocketAddress instance. (Inherited from System.Net.EndPoint)
public Method | Serialize | Serializes endpoint information into a System.Net.SocketAddress instance. (Inherited from System.Net.EndPoint)
Top

See Also

Reference

IPEndPoint Class
Dart.Telnet Namespace


IPEndPoint Constructor

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class : IPEndPoint Constructor

Overload List

Overload | Description
IPEndPoint Constructor() | Creates an IPEndPoint using IPAddress.Any and an ephemeral port (0).
IPEndPoint Constructor(AddressFamily) | Creates an IPEndPoint using IPAddress.Any or IPAddress.IPv6Any and an ephemeral port (0).
IPEndPoint Constructor(IPAddress,Int32) | Creates an IPEndPoint using a specified IPAddress and port.
IPEndPoint Constructor(IPAddress,Int32,Int32) | Creates an IPEndPoint using an IPAddress, port, and port range.
IPEndPoint Constructor(String,Int32) | Creates an IPEndPoint using a hostname or address, and port.
IPEndPoint Constructor(String,AddressFamily,Int32) | Creates an IPEndPoint using a hostname or address, port, and AddressFamily.
IPEndPoint Constructor(String,AddressFamily,Int32,Int32) | Creates an IPEndPoint using a hostname or address, address family, port and range.
IPEndPoint Constructor(String,String,Int32,Int32) | Creates an IPEndPoint using a hostname or address, address, port and range.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members


IPEndPoint Constructor()

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor()

Creates an IPEndPoint using IPAddress.Any and an ephemeral port (0).

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New IPEndPoint()
C#
public IPEndPoint()
Managed Extensions for C++
public: IPEndPoint();
C++/CLI
public:
IPEndPoint();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(AddressFamily)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(AddressFamily)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(AddressFamily)

addressFamily
AddressFamily to match.
Creates an IPEndPoint using IPAddress.Any or IPAddress.IPv6Any and an ephemeral port (0).

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal addressFamily As AddressFamily _
)
Visual Basic (Usage) Copy Code
Dim addressFamily As AddressFamily

Dim instance As New IPEndPoint(addressFamily)
C#
public IPEndPoint(
   AddressFamily addressFamily
)
Managed Extensions for C++
public: IPEndPoint(
   AddressFamily addressFamily
)
C++/CLI
public:
IPEndPoint(
   AddressFamily addressFamily
)

Parameters

addressFamily
AddressFamily to match.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(IPAddress,Int32)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(IPAddress,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(IPAddress,Int32)

address
An IPv4 or IPv6 address.
port
The port to bind to.
Creates an IPEndPoint using a specified IPAddress and port.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal address As IPAddress, _
   ByVal port As Integer _
)
Visual Basic (Usage) Copy Code
Dim address As IPAddress
Dim port As Integer

Dim instance As New IPEndPoint(address, port)
C#
public IPEndPoint(
   IPAddress address,
   int port
)
Managed Extensions for C++
public: IPEndPoint(
   IPAddress* address,
   int port
)
C++/CLI
public:
IPEndPoint(
   IPAddress^ address,
   int port
)

Parameters

address
An IPv4 or IPv6 address.
port
The port to bind to.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(IPAddress,Int32,Int32)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(IPAddress,Int32,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(IPAddress,Int32,Int32)

address
An IPv4 or IPv6 address.
port
The port to bind to.
range
The range of ports, starting at port, to attempt to bind to.
Creates an IPEndPoint using an IPAddress, port, and port range.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal address As IPAddress, _
   ByVal port As Integer, _
   ByVal range As Integer _
)
Visual Basic (Usage) Copy Code
Dim address As IPAddress
Dim port As Integer
Dim range As Integer

Dim instance As New IPEndPoint(address, port, range)
C#
public IPEndPoint(
   IPAddress address,
   int port,
   int range
)
Managed Extensions for C++
public: IPEndPoint(
   IPAddress* address,
   int port,
   int range
)
C++/CLI
public:
IPEndPoint(
   IPAddress^ address,
   int port,
   int range
)

Parameters

address
An IPv4 or IPv6 address.
port
The port to bind to.
range
The range of ports, starting at port, to attempt to bind to.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(String,Int32)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(String,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(String,Int32)

hostNameOrAddress
An IP4 hostname or string address (IP4 or IP6). Empty string resolves to the localhost.
port
The port to bind to.
Creates an IPEndPoint using a hostname or address, and port.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal hostNameOrAddress As String, _
   ByVal port As Integer _
)
Visual Basic (Usage) Copy Code
Dim hostNameOrAddress As String
Dim port As Integer

Dim instance As New IPEndPoint(hostNameOrAddress, port)
C#
public IPEndPoint(
   string hostNameOrAddress,
   int port
)
Managed Extensions for C++
public: IPEndPoint(
   string* hostNameOrAddress,
   int port
)
C++/CLI
public:
IPEndPoint(
   String^ hostNameOrAddress,
   int port
)

Parameters

hostNameOrAddress
An IP4 hostname or string address (IP4 or IP6). Empty string resolves to the localhost.
port
The port to bind to.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(String,AddressFamily,Int32)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(String,AddressFamily,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(String,AddressFamily,Int32)

hostNameOrAddress
A hostname or string address. Empty string resolves to the localhost.
addressFamily
The System.Net.Sockets.AddressFamily to match if resolving a hostname.
port
The port to bind to.
Creates an IPEndPoint using a hostname or address, port, and AddressFamily.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal hostNameOrAddress As String, _
   ByVal addressFamily As AddressFamily, _
   ByVal port As Integer _
)
Visual Basic (Usage) Copy Code
Dim hostNameOrAddress As String
Dim addressFamily As AddressFamily
Dim port As Integer

Dim instance As New IPEndPoint(hostNameOrAddress, addressFamily, port)
C#
public IPEndPoint(
   string hostNameOrAddress,
   AddressFamily addressFamily,
   int port
)
Managed Extensions for C++
public: IPEndPoint(
   string* hostNameOrAddress,
   AddressFamily addressFamily,
   int port
)
C++/CLI
public:
IPEndPoint(
   String^ hostNameOrAddress,
   AddressFamily addressFamily,
   int port
)

Parameters

hostNameOrAddress
A hostname or string address. Empty string resolves to the localhost.
addressFamily
The System.Net.Sockets.AddressFamily to match if resolving a hostname.
port
The port to bind to.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(String,AddressFamily,Int32,Int32)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(String,AddressFamily,Int32,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(String,AddressFamily,Int32,Int32)

hostNameOrAddress
A hostname or string address. Empty string resolves to the localhost.
addressFamily
The System.Net.Sockets.AddressFamily to match if resolving a hostname.
port
The port to bind to.
range
The range of ports, starting at port, to attempt to bind to.
Creates an IPEndPoint using a hostname or address, address family, port and range.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal hostNameOrAddress As String, _
   ByVal addressFamily As AddressFamily, _
   ByVal port As Integer, _
   ByVal range As Integer _
)
Visual Basic (Usage) Copy Code
Dim hostNameOrAddress As String
Dim addressFamily As AddressFamily
Dim port As Integer
Dim range As Integer

Dim instance As New IPEndPoint(hostNameOrAddress, addressFamily, port, range)
C#
public IPEndPoint(
   string hostNameOrAddress,
   AddressFamily addressFamily,
   int port,
   int range
)
Managed Extensions for C++
public: IPEndPoint(
   string* hostNameOrAddress,
   AddressFamily addressFamily,
   int port,
   int range
)
C++/CLI
public:
IPEndPoint(
   String^ hostNameOrAddress,
   AddressFamily addressFamily,
   int port,
   int range
)

Parameters

hostNameOrAddress
A hostname or string address. Empty string resolves to the localhost.
addressFamily
The System.Net.Sockets.AddressFamily to match if resolving a hostname.
port
The port to bind to.
range
The range of ports, starting at port, to attempt to bind to.

Remarks

The socket will try to bind to the specified port. Upon failure, it will try with each successive port up to (port + range), until successful. An Exception is raised if all binding attempts fail.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Constructor(String,String,Int32,Int32)

[image]
PowerTCP Telnet for .NET
IPEndPoint Constructor(String,String,Int32,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class > IPEndPoint Constructor : IPEndPoint Constructor(String,String,Int32,Int32)

hostNameOrAddress
A hostname or string address. Empty string resolves to the localhost.
address
The IPAddress in string notation.
port
The port to bind to.
range
The range of ports, starting at port, to attempt to bind to.
Creates an IPEndPoint using a hostname or address, address, port and range.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal hostNameOrAddress As String, _
   ByVal address As String, _
   ByVal port As Integer, _
   ByVal range As Integer _
)
Visual Basic (Usage) Copy Code
Dim hostNameOrAddress As String
Dim address As String
Dim port As Integer
Dim range As Integer

Dim instance As New IPEndPoint(hostNameOrAddress, address, port, range)
C#
public IPEndPoint(
   string hostNameOrAddress,
   string address,
   int port,
   int range
)
Managed Extensions for C++
public: IPEndPoint(
   string* hostNameOrAddress,
   string* address,
   int port,
   int range
)
C++/CLI
public:
IPEndPoint(
   String^ hostNameOrAddress,
   String^ address,
   int port,
   int range
)

Parameters

hostNameOrAddress
A hostname or string address. Empty string resolves to the localhost.
address
The IPAddress in string notation.
port
The port to bind to.
range
The range of ports, starting at port, to attempt to bind to.

Remarks

This constructor is typically used to serialize the IPEndPoint and does not resolve hostNameOrAddress. The hostname can be needed for some proxies.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members
Overload List


IPEndPoint Class Properties

[image]
PowerTCP Telnet for .NET
IPEndPoint Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : IPEndPoint Class

"

For a list of all members of this type, see IPEndPoint members.

"

Public Properties

 | Name | Description
public Property | Address | Gets or sets the IP address of the endpoint. (Inherited from System.Net.IPEndPoint)
public Property | AddressFamily | Gets the address family to which the endpoint belongs. (Inherited from System.Net.EndPoint)
public Property | HostNameOrAddress | Gets or sets the host name or address resolved to create this IPEndPoint.
public Property | Port | Gets or sets the port number of the endpoint.
Top

See Also

Reference

IPEndPoint Class
Dart.Telnet Namespace


HostNameOrAddress Property

[image]
PowerTCP Telnet for .NET
HostNameOrAddress Property
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class : HostNameOrAddress Property

Gets or sets the host name or address resolved to create this IPEndPoint.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("The string value that was resolved to create this IPEndPoint.")>
<RefreshPropertiesAttribute(RefreshProperties.All)>
<DefaultValueAttribute()>
Public Property HostNameOrAddress As String
Visual Basic (Usage) Copy Code
Dim instance As IPEndPoint
Dim value As String

instance.HostNameOrAddress = value

value = instance.HostNameOrAddress
C#
[DescriptionAttribute("The string value that was resolved to create this IPEndPoint.")]
[RefreshPropertiesAttribute(RefreshProperties.All)]
[DefaultValueAttribute()]
public string HostNameOrAddress {get; set;}
Managed Extensions for C++
[DescriptionAttribute("The string value that was resolved to create this IPEndPoint.")]
[RefreshPropertiesAttribute(RefreshProperties.All)]
[DefaultValueAttribute()]
public: __property string* get_HostNameOrAddress();
public: __property void set_HostNameOrAddress(
   string* value
);
C++/CLI
[DescriptionAttribute("The string value that was resolved to create this IPEndPoint.")]
[RefreshPropertiesAttribute(RefreshProperties.All)]
[DefaultValueAttribute()]
public:
property String^ HostNameOrAddress {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members


Port Property

[image]
PowerTCP Telnet for .NET
Port Property
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class : Port Property

Gets or sets the port number of the endpoint.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<RefreshPropertiesAttribute(RefreshProperties.All)>
<DescriptionAttribute("Gets or sets the port number of the endpoint.")>
Public Shadows Property Port As Integer
Visual Basic (Usage) Copy Code
Dim instance As IPEndPoint
Dim value As Integer

instance.Port = value

value = instance.Port
C#
[DefaultValueAttribute()]
[RefreshPropertiesAttribute(RefreshProperties.All)]
[DescriptionAttribute("Gets or sets the port number of the endpoint.")]
public new int Port {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[RefreshPropertiesAttribute(RefreshProperties.All)]
[DescriptionAttribute("Gets or sets the port number of the endpoint.")]
public: __property new int get_Port();
public: __property new void set_Port(
   int value
);
C++/CLI
[DefaultValueAttribute()]
[RefreshPropertiesAttribute(RefreshProperties.All)]
[DescriptionAttribute("Gets or sets the port number of the endpoint.")]
public:
new property int Port {
   int get();
   void set (    int value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members


IPEndPoint Class Fields

[image]
PowerTCP Telnet for .NET
IPEndPoint Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : IPEndPoint Class

"

For a list of all members of this type, see IPEndPoint members.

"

Public Fields

 | Name | Description
public Field | Range | The socket will be bound to a port between IPEndPoint.Port and (IPEndPoint.Port + Range), inclusive.
Top

See Also

Reference

IPEndPoint Class
Dart.Telnet Namespace


Range Field

[image]
PowerTCP Telnet for .NET
Range Field
See Also Send comments on this topic.
Dart.Telnet Namespace > IPEndPoint Class : Range Field

The socket will be bound to a port between IPEndPoint.Port and (IPEndPoint.Port + Range), inclusive.

Syntax

Visual Basic (Declaration)
Public Range As Integer
Visual Basic (Usage) Copy Code
Dim instance As IPEndPoint
Dim value As Integer

value = instance.Range

instance.Range = value
C#
public int Range
Managed Extensions for C++
public: int Range
C++/CLI
public:
int Range

Remarks

Defaults to 0.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

IPEndPoint Class
IPEndPoint Members


Option Class

[image]
PowerTCP Telnet for .NET
Option Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Option Class

Encapsulates a Telnet option.

Object Model

Option Class

Syntax

Visual Basic (Declaration)
Public Class Option
Visual Basic (Usage) Copy Code
Dim instance As Option
C#
public class Option
Managed Extensions for C++
public __gc class Option
C++/CLI
public ref class Option

Remarks

The Telnet protocol allows for option negotiation to provide advanced capabilities to the default NVT (Network Virtual Terminal). Both client and server can request to enable or disable options. Both hosts can accept or deny requests as well. The Option object represents an option.

To add a Telnet option, create a new Option object, and add it to the ClientOptions or ServerOptions collection. Adding the Option to Telnet.ClientOptions causes the Telnet component to send a WILL or WONT command to the server concerning the option. Adding the Option to Telnet.ServerOptions causes the Telnet component to sent a DO or DONT command to the server concerning the option. The State can either be set to OptionState.RequestOn (to use the option by requesting it), or OptionState.Allow (to use the option if the remote host requests it). To not use an option, either do not add it to a OptionCollection, or, if already present, remove it. After option negotiation occurs, check the State property to see if the option was negotiated successfully (OptionState.On) or negotiated unsuccessfully (OptionState.Off).

Inheritance Hierarchy

System.Object
Dart.Telnet.Option

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Members
Dart.Telnet Namespace


Option Class Members

[image]
PowerTCP Telnet for .NET
Option Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : Option Class

The following tables list the members exposed by Option.

Public Constructors

 | Name | Description
public Constructor | Option Constructor | Overloaded.
Top

Public Properties

 | Name | Description
public Property | Code | Gets or sets the code of the option to use.
public Property | State | Gets or sets the current state of the Option.
public Property | SubOption | Gets or sets the suboption information for options.
Top

Public Methods

 | Name | Description
public Method | Reset | Reinitializes the Option.State for a new connection.
Top

See Also

Reference

Option Class
Dart.Telnet Namespace


Option Constructor

[image]
PowerTCP Telnet for .NET
Option Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class : Option Constructor

Overload List

Overload | Description
Option Constructor() | Initializes a new instance of Option.
Option Constructor(OptionCode) | Initializes a new instance of Option.
Option Constructor(OptionCode,OptionState) | Initializes a new instance of Option.
Option Constructor(OptionCode,Byte[]) | Initializes a new instance of Option.
Option Constructor(OptionCode,Byte[],OptionState) | Initializes a new instance of Option.
Option Constructor(Byte[],Int32,Int32) | Initializes a new instance of Option.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members


Option Constructor()

[image]
PowerTCP Telnet for .NET
Option Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class > Option Constructor : Option Constructor()

Initializes a new instance of Option.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Option()
C#
public Option()
Managed Extensions for C++
public: Option();
C++/CLI
public:
Option();

Remarks

This constructor creates a new instance of Option with the State set to OptionState.Off.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members
Overload List


Option Constructor(OptionCode)

[image]
PowerTCP Telnet for .NET
Option Constructor(OptionCode)
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class > Option Constructor : Option Constructor(OptionCode)

code
The option code.
Initializes a new instance of Option.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal code As OptionCode _
)
Visual Basic (Usage) Copy Code
Dim code As OptionCode

Dim instance As New Option(code)
C#
public Option(
   OptionCode code
)
Managed Extensions for C++
public: Option(
   OptionCode code
)
C++/CLI
public:
Option(
   OptionCode code
)

Parameters

code
The option code.

Remarks

This constructor creates a new instance of Option, with Code set to the value of code and State set to OptionState.Off.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members
Overload List


Option Constructor(OptionCode,OptionState)

[image]
PowerTCP Telnet for .NET
Option Constructor(OptionCode,OptionState)
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class > Option Constructor : Option Constructor(OptionCode,OptionState)

code
The option code.
state
The option state.
Initializes a new instance of Option.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal code As OptionCode, _
   ByVal state As OptionState _
)
Visual Basic (Usage) Copy Code
Dim code As OptionCode
Dim state As OptionState

Dim instance As New Option(code, state)
C#
public Option(
   OptionCode code,
   OptionState state
)
Managed Extensions for C++
public: Option(
   OptionCode code,
   OptionState state
)
C++/CLI
public:
Option(
   OptionCode code,
   OptionState state
)

Parameters

code
The option code.
state
The option state.

Remarks

This constructor creates a new instance of Option, with Code and State set.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members
Overload List


Option Constructor(OptionCode,Byte[])

[image]
PowerTCP Telnet for .NET
Option Constructor(OptionCode,Byte[])
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class > Option Constructor : Option Constructor(OptionCode,Byte[])

code
The option code.
subOption
The option suboption.
Initializes a new instance of Option.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal code As OptionCode, _
   ByVal subOption() As Byte _
)
Visual Basic (Usage) Copy Code
Dim code As OptionCode
Dim subOption() As Byte

Dim instance As New Option(code, subOption)
C#
public Option(
   OptionCode code,
   byte[] subOption
)
Managed Extensions for C++
public: Option(
   OptionCode code,
   byte[]* subOption
)
C++/CLI
public:
Option(
   OptionCode code,
   array<byte>^ subOption
)

Parameters

code
The option code.
subOption
The option suboption.

Remarks

This constructor creates a new instance of Option, with Code set to the value of code, SubOption set to the value of subOption and State set to OptionState.Off.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members
Overload List


Option Constructor(OptionCode,Byte[],OptionState)

[image]
PowerTCP Telnet for .NET
Option Constructor(OptionCode,Byte[],OptionState)
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class > Option Constructor : Option Constructor(OptionCode,Byte[],OptionState)

code
The option code.
subOption
The option suboption.
state
The option state.
Initializes a new instance of Option.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal code As OptionCode, _
   ByVal subOption() As Byte, _
   ByVal state As OptionState _
)
Visual Basic (Usage) Copy Code
Dim code As OptionCode
Dim subOption() As Byte
Dim state As OptionState

Dim instance As New Option(code, subOption, state)
C#
public Option(
   OptionCode code,
   byte[] subOption,
   OptionState state
)
Managed Extensions for C++
public: Option(
   OptionCode code,
   byte[]* subOption,
   OptionState state
)
C++/CLI
public:
Option(
   OptionCode code,
   array<byte>^ subOption,
   OptionState state
)

Parameters

code
The option code.
subOption
The option suboption.
state
The option state.

Remarks

This constructor creates a new instance of Option, with Code, SubOption and State set.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members
Overload List


Option Constructor(Byte[],Int32,Int32)

[image]
PowerTCP Telnet for .NET
Option Constructor(Byte[],Int32,Int32)
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class > Option Constructor : Option Constructor(Byte[],Int32,Int32)

buffer
Contains option data.
offset
Contains the offset into buffer.
count
Contains the option data count.
Initializes a new instance of Option.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal buffer() As Byte, _
   ByVal offset As Integer, _
   ByVal count As Integer _
)
Visual Basic (Usage) Copy Code
Dim buffer() As Byte
Dim offset As Integer
Dim count As Integer

Dim instance As New Option(buffer, offset, count)
C#
public Option(
   byte[] buffer,
   int offset,
   int count
)
Managed Extensions for C++
public: Option(
   byte[]* buffer,
   int offset,
   int count
)
C++/CLI
public:
Option(
   array<byte>^ buffer,
   int offset,
   int count
)

Parameters

buffer
Contains option data.
offset
Contains the offset into buffer.
count
Contains the option data count.

Remarks

This constructor creates a new instance of Option with State set to OptionState.Off.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members
Overload List


Option Class Methods

[image]
PowerTCP Telnet for .NET
Option Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : Option Class

"

For a list of all members of this type, see Option members.

"

Public Methods

 | Name | Description
public Method | Reset | Reinitializes the Option.State for a new connection.
Top

See Also

Reference

Option Class
Dart.Telnet Namespace


Reset Method

[image]
PowerTCP Telnet for .NET
Reset Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class : Reset Method

Reinitializes the Option.State for a new connection.

Syntax

Visual Basic (Declaration)
Public Sub Reset()
Visual Basic (Usage) Copy Code
Dim instance As Option

instance.Reset()
C#
public void Reset()
Managed Extensions for C++
public: void Reset();
C++/CLI
public:
void Reset();

Remarks

This method causes the State property of the Option object to revert back to its original state. If the Option.State was OptionState.RequestOff, it is set to OptionState.Off.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members


Option Class Properties

[image]
PowerTCP Telnet for .NET
Option Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Option Class

"

For a list of all members of this type, see Option members.

"

Public Properties

 | Name | Description
public Property | Code | Gets or sets the code of the option to use.
public Property | State | Gets or sets the current state of the Option.
public Property | SubOption | Gets or sets the suboption information for options.
Top

See Also

Reference

Option Class
Dart.Telnet Namespace


Code Property

[image]
PowerTCP Telnet for .NET
Code Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class : Code Property

Gets or sets the code of the option to use.

Syntax

Visual Basic (Declaration)
Public Property Code As OptionCode
Visual Basic (Usage) Copy Code
Dim instance As Option
Dim value As OptionCode

instance.Code = value

value = instance.Code
C#
public OptionCode Code {get; set;}
Managed Extensions for C++
public: __property OptionCode get_Code();
public: __property void set_Code(
   OptionCode value
);
C++/CLI
public:
property OptionCode Code {
   OptionCode get();
   void set (    OptionCode value);
}

Property Value

An OptionCode value representing the code for the option.

Remarks

This property will reflect one of the defined Telnet option code values represented by the OptionCode enumeration. For information about each option, please see the appropriate RFC for that option.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members


State Property

[image]
PowerTCP Telnet for .NET
State Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class : State Property

Gets or sets the current state of the Option.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("The requested state for the option.")>
<DefaultValueAttribute()>
Public Property State As OptionState
Visual Basic (Usage) Copy Code
Dim instance As Option
Dim value As OptionState

instance.State = value

value = instance.State
C#
[DescriptionAttribute("The requested state for the option.")]
[DefaultValueAttribute()]
public OptionState State {get; set;}
Managed Extensions for C++
[DescriptionAttribute("The requested state for the option.")]
[DefaultValueAttribute()]
public: __property OptionState get_State();
public: __property void set_State(
   OptionState value
);
C++/CLI
[DescriptionAttribute("The requested state for the option.")]
[DefaultValueAttribute()]
public:
property OptionState State {
   OptionState get();
   void set (    OptionState value);
}

Property Value

An OptionState value representing the current state of the Option.

Remarks

Option negotiation with PowerTCP Telnet for .NET can be broken down into three general states:

State 1 - Setting the option:

Any requested options must be added to either the ClientOptions or ServerOptions collections. Any options added to these collections are part of the automatic option negotiation. When adding new options to the collection:

  • Set to OptionState.RequestOn to request the option (default value).
  • Set to OptionState.Allow to enable the option if the remote host requests it.
  • Remove Options from the collection to respond negatively to server requests.

State 2 - Requesting the option:

Option negotiation is typically handled internally by the Telnet component when a new connection occurs. During this time, Code is OptionCode.Waiting, indicating a request has been sent but a response has not yet been received.

State 3 - Negotiation complete:

After option negotiation has completed, check Option.Code to see the negotiation results. It should be one of two values:

  • OptionCode.Off if the option is not used.
  • OptionCode.On if the option is used.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members


SubOption Property

[image]
PowerTCP Telnet for .NET
SubOption Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Option Class : SubOption Property

Gets or sets the suboption information for options.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Optional sub-options for the option.")>
Public Property SubOption As Byte()
Visual Basic (Usage) Copy Code
Dim instance As Option
Dim value() As Byte

instance.SubOption = value

value = instance.SubOption
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Optional sub-options for the option.")]
public byte[] SubOption {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Optional sub-options for the option.")]
public: __property byte[]* get_SubOption();
public: __property void set_SubOption(
   byte[]* value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Optional sub-options for the option.")]
public:
property array<byte>^ SubOption {
   array<byte>^ get();
   void set (    array<byte>^ value);
}

Property Value

A byte array representing the suboption information.

Remarks

Some options require addition suboption information. Set this property to a byte array representing the suboption data. The formatting of the data in the byte array will vary depending on the option. See the appropriate RFC for the option to determine how to format the data.

Popular suboptions are encapsulated by high level properties for ease of use. Examples include TerminalType and WindowSize.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Option Class
Option Members


OptionCollection Class

[image]
PowerTCP Telnet for .NET
OptionCollection Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : OptionCollection Class

A collection of Option objects.

Object Model

OptionCollection ClassOption Class

Syntax

Visual Basic (Declaration)
Public Class OptionCollection
   Inherits System.Collections.Generic.List(Of Option)
Visual Basic (Usage) Copy Code
Dim instance As OptionCollection
C#
public class OptionCollection : System.Collections.Generic.List<Option>
Managed Extensions for C++
public __gc class OptionCollection : public System.Collections.Generic.List<Option>
C++/CLI
public ref class OptionCollection : public System.Collections.Generic.List<Option>

Inheritance Hierarchy

System.Object
System.Collections.Generic.List<T>
Dart.Telnet.OptionCollection

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Members
Dart.Telnet Namespace


OptionCollection Class Members

[image]
PowerTCP Telnet for .NET
OptionCollection Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : OptionCollection Class

The following tables list the members exposed by OptionCollection.

Public Constructors

 | Name | Description
public Constructor | OptionCollection Constructor | Initializes an instance of the OptionCollection object.
Top

Public Properties

 | Name | Description
public Property | Capacity | Gets or sets the total number of elements the internal data structure can hold without resizing. (Inherited from System.Collections.Generic.List<Option>)
public Property | Count | Gets the number of elements actually contained in the List. (Inherited from System.Collections.Generic.List<Option>)
public Property | Item | Gets or sets the element at the specified index. (Inherited from System.Collections.Generic.List<Option>)
public Property | TransmitBinary | Gets a value indicating if the "TRANSMIT-BINARY" option was negotiated for the OptionCollection.
Top

Public Methods

 | Name | Description
public Method | Add | Adds a new Option to the OptionCollection object.
public Method | AddRange | Overloaded. Adds an array of Option objects to the OptionCollection.
public Method | AsReadOnly | Returns a read-only IList wrapper for the current collection. (Inherited from System.Collections.Generic.List<Option>)
public Method | BinarySearch | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Clear | Removes all elements from the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | Contains | Determines whether an element is in the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | ConvertAll | Converts the elements in the current List to another type, and returns a list containing the converted elements. (Inherited from System.Collections.Generic.List<Option>)
public Method | CopyTo | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Exists | Determines whether the List contains elements that match the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
public Method | Find | Overloaded. Returns the Option object which matches the specified code.
public Method | FindAll | Retrieves all the elements that match the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
public Method | FindIndex | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | FindLast | Searches for an element that matches the conditions defined by the specified predicate, and returns the last occurrence within the entire List. (Inherited from System.Collections.Generic.List<Option>)
public Method | FindLastIndex | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | ForEach | Performs the specified action on each element of the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | GetEnumerator | Returns an enumerator that iterates through the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | GetRange | Creates a shallow copy of a range of elements in the source List. (Inherited from System.Collections.Generic.List<Option>)
public Method | IndexOf | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Insert | Inserts an element into the List at the specified index. (Inherited from System.Collections.Generic.List<Option>)
public Method | InsertRange | Inserts the elements of a collection into the List at the specified index. (Inherited from System.Collections.Generic.List<Option>)
public Method | LastIndexOf | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Remove | Removes the first occurrence of a specific object from the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | RemoveAll | Removes the all the elements that match the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
public Method | RemoveAt | Removes the element at the specified index of the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | RemoveRange | Removes a range of elements from the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | Reverse | Overloaded. Reverses the order of the elements in the entire List. (Inherited from System.Collections.Generic.List<Option>)
public Method | Sort | Overloaded. Sorts the elements in the entire List using the default comparer. (Inherited from System.Collections.Generic.List<Option>)
public Method | ToArray | Copies the elements of the List to a new array. (Inherited from System.Collections.Generic.List<Option>)
public Method | TrimExcess | Sets the capacity to the actual number of elements in the List, if that number is less than a threshold value. (Inherited from System.Collections.Generic.List<Option>)
public Method | TrueForAll | Determines whether every element in the List matches the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
Top

See Also

Reference

OptionCollection Class
Dart.Telnet Namespace


OptionCollection Constructor

[image]
PowerTCP Telnet for .NET
OptionCollection Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class : OptionCollection Constructor

Initializes an instance of the OptionCollection object.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New OptionCollection()
C#
public OptionCollection()
Managed Extensions for C++
public: OptionCollection();
C++/CLI
public:
OptionCollection();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members


OptionCollection Class Methods

[image]
PowerTCP Telnet for .NET
OptionCollection Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : OptionCollection Class

"

For a list of all members of this type, see OptionCollection members.

"

Public Methods

 | Name | Description
public Method | Add | Adds a new Option to the OptionCollection object.
public Method | AddRange | Overloaded. Adds an array of Option objects to the OptionCollection.
public Method | AsReadOnly | Returns a read-only IList wrapper for the current collection. (Inherited from System.Collections.Generic.List<Option>)
public Method | BinarySearch | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Clear | Removes all elements from the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | Contains | Determines whether an element is in the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | ConvertAll | Converts the elements in the current List to another type, and returns a list containing the converted elements. (Inherited from System.Collections.Generic.List<Option>)
public Method | CopyTo | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Exists | Determines whether the List contains elements that match the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
public Method | Find | Overloaded. Returns the Option object which matches the specified code.
public Method | FindAll | Retrieves all the elements that match the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
public Method | FindIndex | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | FindLast | Searches for an element that matches the conditions defined by the specified predicate, and returns the last occurrence within the entire List. (Inherited from System.Collections.Generic.List<Option>)
public Method | FindLastIndex | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | ForEach | Performs the specified action on each element of the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | GetEnumerator | Returns an enumerator that iterates through the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | GetRange | Creates a shallow copy of a range of elements in the source List. (Inherited from System.Collections.Generic.List<Option>)
public Method | IndexOf | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Insert | Inserts an element into the List at the specified index. (Inherited from System.Collections.Generic.List<Option>)
public Method | InsertRange | Inserts the elements of a collection into the List at the specified index. (Inherited from System.Collections.Generic.List<Option>)
public Method | LastIndexOf | Overloaded. (Inherited from System.Collections.Generic.List<Option>)
public Method | Remove | Removes the first occurrence of a specific object from the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | RemoveAll | Removes the all the elements that match the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
public Method | RemoveAt | Removes the element at the specified index of the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | RemoveRange | Removes a range of elements from the List. (Inherited from System.Collections.Generic.List<Option>)
public Method | Reverse | Overloaded. Reverses the order of the elements in the entire List. (Inherited from System.Collections.Generic.List<Option>)
public Method | Sort | Overloaded. Sorts the elements in the entire List using the default comparer. (Inherited from System.Collections.Generic.List<Option>)
public Method | ToArray | Copies the elements of the List to a new array. (Inherited from System.Collections.Generic.List<Option>)
public Method | TrimExcess | Sets the capacity to the actual number of elements in the List, if that number is less than a threshold value. (Inherited from System.Collections.Generic.List<Option>)
public Method | TrueForAll | Determines whether every element in the List matches the conditions defined by the specified predicate. (Inherited from System.Collections.Generic.List<Option>)
Top

See Also

Reference

OptionCollection Class
Dart.Telnet Namespace


Add Method

[image]
PowerTCP Telnet for .NET
Add Method
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class : Add Method

value
The Option to add to the OptionCollection object.
Adds a new Option to the OptionCollection object.

Syntax

Visual Basic (Declaration)
Public Shadows Sub Add( _
   ByVal value As Option _
)
Visual Basic (Usage) Copy Code
Dim instance As OptionCollection
Dim value As Option

instance.Add(value)
C#
public new void Add(
   Option value
)
Managed Extensions for C++
public: new void Add(
   Option* value
)
C++/CLI
public:
new void Add(
   Option^ value
)

Parameters

value
The Option to add to the OptionCollection object.

Remarks

Use this method to add a new Option to the OptionCollection, to ensure it is used during option negotiation.

If an existing item has the same Code as the new option, the existing item is removed to prevent duplication.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members


AddRange Method

[image]
PowerTCP Telnet for .NET
AddRange Method
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class : AddRange Method

Adds an array of Option objects to the OptionCollection.

Overload List

Overload | Description
AddRange(Option[]) | Adds an array of Option objects to the OptionCollection.
AddRange(IEnumerable{Option}) | Adds the elements of the specified collection to the end of the List. (Inherited from System.Collections.Generic.List<Option>)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members


AddRange(Option[]) Method

[image]
PowerTCP Telnet for .NET
AddRange(Option[]) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class > AddRange Method : AddRange(Option[]) Method

items
The array of Option objects to add to the OptionCollection.
Adds an array of Option objects to the OptionCollection.

Syntax

Visual Basic (Declaration)
Public Overloads Sub AddRange( _
   ByVal items() As Option _
)
Visual Basic (Usage) Copy Code
Dim instance As OptionCollection
Dim items() As Option

instance.AddRange(items)
C#
public void AddRange(
   Option[] items
)
Managed Extensions for C++
public: void AddRange(
   Option*[]* items
)
C++/CLI
public:
void AddRange(
   array<Option^>^ items
)

Parameters

items
The array of Option objects to add to the OptionCollection.

Remarks

Use this method to add an array of Options to the OptionCollection, to ensure they are used during option negotiation.

If an existing item has the same Code as the new option, the existing item is removed to prevent duplication.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members
Overload List


Find Method

[image]
PowerTCP Telnet for .NET
Find Method
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class : Find Method

Returns the Option object which matches the specified code.

Overload List

Overload | Description
Find(OptionCode) | Returns the Option object which matches the specified code.
Find(Predicate{Option}) | Searches for an element that matches the conditions defined by the specified predicate, and returns the first occurrence within the entire List. (Inherited from System.Collections.Generic.List<Option>)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members


Find(OptionCode) Method

[image]
PowerTCP Telnet for .NET
Find(OptionCode) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class > Find Method : Find(OptionCode) Method

code
The OptionCode of the option to find.
Returns the Option object which matches the specified code.

Syntax

Visual Basic (Declaration)
Public Overloads Function Find( _
   ByVal code As OptionCode _
) As Option
Visual Basic (Usage) Copy Code
Dim instance As OptionCollection
Dim code As OptionCode
Dim value As Option

value = instance.Find(code)
C#
public Option Find(
   OptionCode code
)
Managed Extensions for C++
public: Option* Find(
   OptionCode code
)
C++/CLI
public:
Option^ Find(
   OptionCode code
)

Parameters

code
The OptionCode of the option to find.

Return Value

The Option which matches the specified code.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members
Overload List


OptionCollection Class Properties

[image]
PowerTCP Telnet for .NET
OptionCollection Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : OptionCollection Class

"

For a list of all members of this type, see OptionCollection members.

"

Public Properties

 | Name | Description
public Property | Capacity | Gets or sets the total number of elements the internal data structure can hold without resizing. (Inherited from System.Collections.Generic.List<Option>)
public Property | Count | Gets the number of elements actually contained in the List. (Inherited from System.Collections.Generic.List<Option>)
public Property | Item | Gets or sets the element at the specified index. (Inherited from System.Collections.Generic.List<Option>)
public Property | TransmitBinary | Gets a value indicating if the "TRANSMIT-BINARY" option was negotiated for the OptionCollection.
Top

See Also

Reference

OptionCollection Class
Dart.Telnet Namespace


TransmitBinary Property

[image]
PowerTCP Telnet for .NET
TransmitBinary Property
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionCollection Class : TransmitBinary Property

Gets a value indicating if the "TRANSMIT-BINARY" option was negotiated for the OptionCollection.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property TransmitBinary As Boolean
Visual Basic (Usage) Copy Code
Dim instance As OptionCollection
Dim value As Boolean

value = instance.TransmitBinary
C#
public bool TransmitBinary {get;}
Managed Extensions for C++
public: __property bool get_TransmitBinary();
C++/CLI
public:
property bool TransmitBinary {
   bool get();
}

Property Value

A boolean which determines if the TRANSMIT-BINARY option has been negotiated.

Remarks

Setting the Binary property to true will cause the Telnet component to attempt to negotiate the "TRANSMIT-BINARY" option for both ClientOptions and ServerOptions. Check this property for both these collections after option negotiation has completed to determine if negotiation was successful.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionCollection Class
OptionCollection Members


OptionEventArgs Class

[image]
PowerTCP Telnet for .NET
OptionEventArgs Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : OptionEventArgs Class

Contains option event data.

Object Model

OptionEventArgs ClassOption Class

Syntax

Visual Basic (Declaration)
Public Class OptionEventArgs
   Inherits System.EventArgs
Visual Basic (Usage) Copy Code
Dim instance As OptionEventArgs
C#
public class OptionEventArgs : System.EventArgs
Managed Extensions for C++
public __gc class OptionEventArgs : public System.EventArgs
C++/CLI
public ref class OptionEventArgs : public System.EventArgs

Inheritance Hierarchy

System.Object
System.EventArgs
Dart.Telnet.OptionEventArgs

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionEventArgs Members
Dart.Telnet Namespace


OptionEventArgs Class Members

[image]
PowerTCP Telnet for .NET
OptionEventArgs Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : OptionEventArgs Class

The following tables list the members exposed by OptionEventArgs.

Public Properties

 | Name | Description
public Property | Option | The updated option causing the event.
Top

See Also

Reference

OptionEventArgs Class
Dart.Telnet Namespace


OptionEventArgs Class Properties

[image]
PowerTCP Telnet for .NET
OptionEventArgs Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : OptionEventArgs Class

"

For a list of all members of this type, see OptionEventArgs members.

"

Public Properties

 | Name | Description
public Property | Option | The updated option causing the event.
Top

See Also

Reference

OptionEventArgs Class
Dart.Telnet Namespace


Option Property

[image]
PowerTCP Telnet for .NET
Option Property
See Also Send comments on this topic.
Dart.Telnet Namespace > OptionEventArgs Class : Option Property

The updated option causing the event.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Option As Option
Visual Basic (Usage) Copy Code
Dim instance As OptionEventArgs
Dim value As Option

value = instance.Option
C#
public Option Option {get;}
Managed Extensions for C++
public: __property Option* get_Option();
C++/CLI
public:
property Option^ Option {
   Option^ get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

OptionEventArgs Class
OptionEventArgs Members


ProtocolException Class

[image]
PowerTCP Telnet for .NET
ProtocolException Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : ProtocolException Class

Used to throw protocol exceptions for upper-layer protocols like FTP, SMTP and POP3.

Object Model

ProtocolException Class

Syntax

Visual Basic (Declaration)
<SerializableAttribute()>
Public Class ProtocolException
   Inherits System.ApplicationException
Visual Basic (Usage) Copy Code
Dim instance As ProtocolException
C#
[SerializableAttribute()]
public class ProtocolException : System.ApplicationException
Managed Extensions for C++
[SerializableAttribute()]
public __gc class ProtocolException : public System.ApplicationException
C++/CLI
[SerializableAttribute()]
public ref class ProtocolException : public System.ApplicationException

Remarks

This exception is thrown when a server response is negative. For example, if the server returned "500" (indicating a syntax error) as response to a command being sent, a ProtocolException would be thrown.

Inheritance Hierarchy

System.Object
System.Exception
System.ApplicationException
Dart.Telnet.ProtocolException

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ProtocolException Members
Dart.Telnet Namespace


ProtocolException Class Members

[image]
PowerTCP Telnet for .NET
ProtocolException Class Members
See Also Properties Methods Send comments on this topic.
Dart.Telnet Namespace : ProtocolException Class

The following tables list the members exposed by ProtocolException.

Public Constructors

 | Name | Description
public Constructor | ProtocolException Constructor | Overloaded.
Top

Public Properties

 | Name | Description
public Property | Data | Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Inherited from System.Exception)
public Property | HelpLink | Gets or sets a link to the help file associated with this exception. (Inherited from System.Exception)
public Property | InnerException | Gets the System.Exception instance that caused the current exception. (Inherited from System.Exception)
public Property | Message | Gets a message that describes the current exception. (Inherited from System.Exception)
public Property | Source | Gets or sets the name of the application or the object that causes the error. (Inherited from System.Exception)
public Property | StackTrace | Gets a string representation of the frames on the call stack at the time the current exception was thrown. (Inherited from System.Exception)
public Property | TargetSite | Gets the method that throws the current exception. (Inherited from System.Exception)
Top

Protected Properties

 | Name | Description
protected Property | HResult | Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Inherited from System.Exception)
Top

Public Methods

 | Name | Description
public Method | GetBaseException | When overridden in a derived class, returns the System.Exception that is the root cause of one or more subsequent exceptions. (Inherited from System.Exception)
public Method | GetObjectData | When overridden in a derived class, sets the System.Runtime.Serialization.SerializationInfo with information about the exception. (Inherited from System.Exception)
public Method | GetType | Gets the runtime type of the current instance. (Inherited from System.Exception)
Top

See Also

Reference

ProtocolException Class
Dart.Telnet Namespace


ProtocolException Constructor

[image]
PowerTCP Telnet for .NET
ProtocolException Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > ProtocolException Class : ProtocolException Constructor

Overload List

Overload | Description
ProtocolException Constructor() | Initializes a new ProtocolException.
ProtocolException Constructor(String) | Initializes a new ProtocolException.
ProtocolException Constructor(String,Exception) | Initializes a new ProtocolException.
ProtocolException Constructor(SerializationInfo,StreamingContext) | Initializes a new ProtocolException.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ProtocolException Class
ProtocolException Members


ProtocolException Constructor()

[image]
PowerTCP Telnet for .NET
ProtocolException Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > ProtocolException Class > ProtocolException Constructor : ProtocolException Constructor()

Initializes a new ProtocolException.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New ProtocolException()
C#
public ProtocolException()
Managed Extensions for C++
public: ProtocolException();
C++/CLI
public:
ProtocolException();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ProtocolException Class
ProtocolException Members
Overload List


ProtocolException Constructor(String)

[image]
PowerTCP Telnet for .NET
ProtocolException Constructor(String)
See Also Send comments on this topic.
Dart.Telnet Namespace > ProtocolException Class > ProtocolException Constructor : ProtocolException Constructor(String)

message
Initializes a new ProtocolException.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal message As String _
)
Visual Basic (Usage) Copy Code
Dim message As String

Dim instance As New ProtocolException(message)
C#
public ProtocolException(
   string message
)
Managed Extensions for C++
public: ProtocolException(
   string* message
)
C++/CLI
public:
ProtocolException(
   String^ message
)

Parameters

message

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ProtocolException Class
ProtocolException Members
Overload List


ProtocolException Constructor(String,Exception)

[image]
PowerTCP Telnet for .NET
ProtocolException Constructor(String,Exception)
See Also Send comments on this topic.
Dart.Telnet Namespace > ProtocolException Class > ProtocolException Constructor : ProtocolException Constructor(String,Exception)

message
e
Initializes a new ProtocolException.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal message As String, _
   ByVal e As Exception _
)
Visual Basic (Usage) Copy Code
Dim message As String
Dim e As Exception

Dim instance As New ProtocolException(message, e)
C#
public ProtocolException(
   string message,
   Exception e
)
Managed Extensions for C++
public: ProtocolException(
   string* message,
   Exception* e
)
C++/CLI
public:
ProtocolException(
   String^ message,
   Exception^ e
)

Parameters

message
e

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ProtocolException Class
ProtocolException Members
Overload List


ProtocolException Constructor(SerializationInfo,StreamingContext)

[image]
PowerTCP Telnet for .NET
ProtocolException Constructor(SerializationInfo,StreamingContext)
See Also Send comments on this topic.
Dart.Telnet Namespace > ProtocolException Class > ProtocolException Constructor : ProtocolException Constructor(SerializationInfo,StreamingContext)

info
context
Initializes a new ProtocolException.

Syntax

Visual Basic (Declaration)
Protected Function New( _
   ByVal info As SerializationInfo, _
   ByVal context As StreamingContext _
)
Visual Basic (Usage) Copy Code
Dim info As SerializationInfo
Dim context As StreamingContext

Dim instance As New ProtocolException(info, context)
C#
protected ProtocolException(
   SerializationInfo info,
   StreamingContext context
)
Managed Extensions for C++
protected: ProtocolException(
   SerializationInfo* info,
   StreamingContext context
)
C++/CLI
protected:
ProtocolException(
   SerializationInfo^ info,
   StreamingContext context
)

Parameters

info
context

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ProtocolException Class
ProtocolException Members
Overload List


Proxy Class

[image]
PowerTCP Telnet for .NET
Proxy Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Proxy Class

Describes the server proxy, if any, to connect to.

Object Model

Proxy ClassIPEndPoint Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class Proxy
Visual Basic (Usage) Copy Code
Dim instance As Proxy
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class Proxy
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class Proxy
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class Proxy

Inheritance Hierarchy

System.Object
Dart.Telnet.Proxy

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Proxy Members
Dart.Telnet Namespace


Proxy Class Members

[image]
PowerTCP Telnet for .NET
Proxy Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : Proxy Class

The following tables list the members exposed by Proxy.

Public Constructors

 | Name | Description
public Constructor | Proxy Constructor |
Top

Public Properties

 | Name | Description
public Property | Password | The password to send to the server proxy. Not used for Socks4.
public Property | RemoteEndPoint | IPEndPoint of the server proxy to connect to.
public Property | Type | The ProxyType desired.
public Property | Username | The username to send to the server proxy.
Top

See Also

Reference

Proxy Class
Dart.Telnet Namespace


Proxy Constructor

[image]
PowerTCP Telnet for .NET
Proxy Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Proxy Class : Proxy Constructor

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Proxy()
C#
public Proxy()
Managed Extensions for C++
public: Proxy();
C++/CLI
public:
Proxy();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Proxy Class
Proxy Members


Proxy Class Properties

[image]
PowerTCP Telnet for .NET
Proxy Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Proxy Class

"

For a list of all members of this type, see Proxy members.

"

Public Properties

 | Name | Description
public Property | Password | The password to send to the server proxy. Not used for Socks4.
public Property | RemoteEndPoint | IPEndPoint of the server proxy to connect to.
public Property | Type | The ProxyType desired.
public Property | Username | The username to send to the server proxy.
Top

See Also

Reference

Proxy Class
Dart.Telnet Namespace


Password Property

[image]
PowerTCP Telnet for .NET
Password Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Proxy Class : Password Property

The password to send to the server proxy. Not used for Socks4.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("The password to send to the server proxy. Not used for Socks4.")>
Public Property Password As String
Visual Basic (Usage) Copy Code
Dim instance As Proxy
Dim value As String

instance.Password = value

value = instance.Password
C#
[DefaultValueAttribute()]
[DescriptionAttribute("The password to send to the server proxy. Not used for Socks4.")]
public string Password {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("The password to send to the server proxy. Not used for Socks4.")]
public: __property string* get_Password();
public: __property void set_Password(
   string* value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("The password to send to the server proxy. Not used for Socks4.")]
public:
property String^ Password {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Proxy Class
Proxy Members


RemoteEndPoint Property

[image]
PowerTCP Telnet for .NET
RemoteEndPoint Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Proxy Class : RemoteEndPoint Property

IPEndPoint of the server proxy to connect to.

Syntax

Visual Basic (Declaration)
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<DescriptionAttribute("IPEndPoint of the server proxy to connect to.")>
<DefaultValueAttribute()>
Public Property RemoteEndPoint As IPEndPoint
Visual Basic (Usage) Copy Code
Dim instance As Proxy
Dim value As IPEndPoint

instance.RemoteEndPoint = value

value = instance.RemoteEndPoint
C#
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("IPEndPoint of the server proxy to connect to.")]
[DefaultValueAttribute()]
public IPEndPoint RemoteEndPoint {get; set;}
Managed Extensions for C++
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("IPEndPoint of the server proxy to connect to.")]
[DefaultValueAttribute()]
public: __property IPEndPoint* get_RemoteEndPoint();
public: __property void set_RemoteEndPoint(
   IPEndPoint* value
);
C++/CLI
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("IPEndPoint of the server proxy to connect to.")]
[DefaultValueAttribute()]
public:
property IPEndPoint^ RemoteEndPoint {
   IPEndPoint^ get();
   void set (    IPEndPoint^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Proxy Class
Proxy Members


Type Property

[image]
PowerTCP Telnet for .NET
Type Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Proxy Class : Type Property

The ProxyType desired.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("The type of server proxy desired.")>
Public Property Type As ProxyType
Visual Basic (Usage) Copy Code
Dim instance As Proxy
Dim value As ProxyType

instance.Type = value

value = instance.Type
C#
[DefaultValueAttribute()]
[DescriptionAttribute("The type of server proxy desired.")]
public ProxyType Type {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("The type of server proxy desired.")]
public: __property ProxyType get_Type();
public: __property void set_Type(
   ProxyType value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("The type of server proxy desired.")]
public:
property ProxyType Type {
   ProxyType get();
   void set (    ProxyType value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Proxy Class
Proxy Members


Username Property

[image]
PowerTCP Telnet for .NET
Username Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Proxy Class : Username Property

The username to send to the server proxy.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("The username to send to the server proxy.")>
Public Property Username As String
Visual Basic (Usage) Copy Code
Dim instance As Proxy
Dim value As String

instance.Username = value

value = instance.Username
C#
[DefaultValueAttribute()]
[DescriptionAttribute("The username to send to the server proxy.")]
public string Username {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("The username to send to the server proxy.")]
public: __property string* get_Username();
public: __property void set_Username(
   string* value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("The username to send to the server proxy.")]
public:
property String^ Username {
   String^ get();
   void set (    String^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Proxy Class
Proxy Members


PtyBase Class

[image]
PowerTCP Telnet for .NET
PtyBase Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : PtyBase Class

This class provides support for interactive on-line terminal access using controls derived from TextBoxBase.

Object Model

PtyBase ClassTcpSocketOption Class

Syntax

Visual Basic (Declaration)
Public Class PtyBase
   Inherits TcpBase
Visual Basic (Usage) Copy Code
Dim instance As PtyBase
C#
public class PtyBase : TcpBase
Managed Extensions for C++
public __gc class PtyBase : public TcpBase
C++/CLI
public ref class PtyBase : public TcpBase

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.PtyBase
Dart.Telnet.Rlogin
Dart.Telnet.Telnet

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

PtyBase Members
Dart.Telnet Namespace


PtyBase Class Members

[image]
PowerTCP Telnet for .NET
PtyBase Class Members
See Also Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : PtyBase Class

The following tables list the members exposed by PtyBase.

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | CRLF | Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | LocalEcho | Set to true if the Pty property is used and keystrokes should be displayed in the textbox.
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | Pty | Gets or sets a display control to use for automatic pseudo terminal support.
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Connects to a server using parameters found in the session parameter. (Inherited from Dart.Telnet.TcpBase)
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

PtyBase Class
Dart.Telnet Namespace


PtyBase Class Properties

[image]
PowerTCP Telnet for .NET
PtyBase Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : PtyBase Class

"

For a list of all members of this type, see PtyBase members.

"

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | CRLF | Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | LocalEcho | Set to true if the Pty property is used and keystrokes should be displayed in the textbox.
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | Pty | Gets or sets a display control to use for automatic pseudo terminal support.
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

PtyBase Class
Dart.Telnet Namespace


CRLF Property

[image]
PowerTCP Telnet for .NET
CRLF Property
See Also Send comments on this topic.
Dart.Telnet Namespace > PtyBase Class : CRLF Property

Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.")>
Public Property CRLF As Boolean
Visual Basic (Usage) Copy Code
Dim instance As PtyBase
Dim value As Boolean

instance.CRLF = value

value = instance.CRLF
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.")]
public bool CRLF {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.")]
public: __property bool get_CRLF();
public: __property void set_CRLF(
   bool value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Set to true if the Pty property is used and a CR should be converted to a CRLF for sending.")]
public:
property bool CRLF {
   bool get();
   void set (    bool value);
}

Remarks

This property controls the behavior of the TextBox assigned to the Pty property. For example, the Echo protocol echoes back any sent character. Since as textbox requires a CRLF, set this property to true so that a CRLF will be generated when the return key is pressed. Defaults to false.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

PtyBase Class
PtyBase Members


LocalEcho Property

[image]
PowerTCP Telnet for .NET
LocalEcho Property
See Also Send comments on this topic.
Dart.Telnet Namespace > PtyBase Class : LocalEcho Property

Set to true if the Pty property is used and keystrokes should be displayed in the textbox.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Set to true if the Pty property is used and keystrokes should be displayed in the textbox.")>
Public Property LocalEcho As Boolean
Visual Basic (Usage) Copy Code
Dim instance As PtyBase
Dim value As Boolean

instance.LocalEcho = value

value = instance.LocalEcho
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Set to true if the Pty property is used and keystrokes should be displayed in the textbox.")]
public bool LocalEcho {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Set to true if the Pty property is used and keystrokes should be displayed in the textbox.")]
public: __property bool get_LocalEcho();
public: __property void set_LocalEcho(
   bool value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Set to true if the Pty property is used and keystrokes should be displayed in the textbox.")]
public:
property bool LocalEcho {
   bool get();
   void set (    bool value);
}

Remarks

This property controls the behavior of the TextBox assigned to the Pty property. For example, the Pop protocol does not echo sent characters to the screen. Set this property to true to see the characters being sent to the Pop server. Defaults to false.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

PtyBase Class
PtyBase Members


Pty Property

[image]
PowerTCP Telnet for .NET
Pty Property
See Also Send comments on this topic.
Dart.Telnet Namespace > PtyBase Class : Pty Property

Gets or sets a display control to use for automatic pseudo terminal support.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Provides automatic terminal support to and from the control provided.")>
Public Property Pty As TextBoxBase
Visual Basic (Usage) Copy Code
Dim instance As PtyBase
Dim value As TextBoxBase

instance.Pty = value

value = instance.Pty
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Provides automatic terminal support to and from the control provided.")]
public TextBoxBase Pty {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Provides automatic terminal support to and from the control provided.")]
public: __property TextBoxBase* get_Pty();
public: __property void set_Pty(
   TextBoxBase* value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Provides automatic terminal support to and from the control provided.")]
public:
property TextBoxBase^ Pty {
   TextBoxBase^ get();
   void set (    TextBoxBase^ value);
}

Remarks

Set this property to a control derived from TextBoxBase and call Connect to start an online session. Data received from the host will be displayed, and keyboard input will automatically be sent to the remote host.

The Multiline property on the Pty control is set to true. You may wish to set the Font property to a fixed-width font and set the Wordwrap property to false. Also, if the SynchronizingObject is null, it will be set to the Pty control.

These properties can be changed from their default values after this property is set.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

PtyBase Class
PtyBase Members


Rexec Class

[image]
PowerTCP Telnet for .NET
Rexec Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Rexec Class

The Rexec component enables use of the remote execution protocol within any .NET application.

Object Model

Rexec ClassTcpSocketOption Class

Syntax

Visual Basic (Declaration)
<LicenseProviderAttribute(System.ComponentModel.LicenseProvider)>
<DescriptionAttribute("The Rexec Component integrates event handling, Stream support, and a concise object model for on-line communications")>
<ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")>
Public Class Rexec
   Inherits TcpBase
Visual Basic (Usage) Copy Code
Dim instance As Rexec
C#
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[DescriptionAttribute("The Rexec Component integrates event handling, Stream support, and a concise object model for on-line communications")]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
public class Rexec : TcpBase
Managed Extensions for C++
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[DescriptionAttribute("The Rexec Component integrates event handling, Stream support, and a concise object model for on-line communications")]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
public __gc class Rexec : public TcpBase
C++/CLI
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[DescriptionAttribute("The Rexec Component integrates event handling, Stream support, and a concise object model for on-line communications")]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
public ref class Rexec : public TcpBase

Remarks

Use the Rexec component to execute a command on a remote host (typically a UNIX host). To use the Rexec component, call one of the Connect methods to connect, then call Execute to execute the command, and then use one of the Read methods to read the results of the command.

Rexec and Rsh perform the same task using different authentication techniques. Rsh requires static information be added to .rhosts and/or hosts.equiv, whereas Rexec simply uses dynamic username/password information for authentication.

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.Rexec

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Members
Dart.Telnet Namespace


Rexec Class Members

[image]
PowerTCP Telnet for .NET
Rexec Class Members
See Also Fields Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : Rexec Class

The following tables list the members exposed by Rexec.

Public Constructors

 | Name | Description
public Constructor | Rexec Constructor | Overloaded.
Top

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 512 for Rexec operations.
Top

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to an Rexec server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | Execute | Executes a command on the remote host.
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rexec Class
Dart.Telnet Namespace


Rexec Constructor

[image]
PowerTCP Telnet for .NET
Rexec Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class : Rexec Constructor

Overload List

Overload | Description
Rexec Constructor() | Initializes a new instance of the Rexec component.
Rexec Constructor(IContainer) | Initializes a new instance of the Rexec component.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members


Rexec Constructor()

[image]
PowerTCP Telnet for .NET
Rexec Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class > Rexec Constructor : Rexec Constructor()

Initializes a new instance of the Rexec component.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Rexec()
C#
public Rexec()
Managed Extensions for C++
public: Rexec();
C++/CLI
public:
Rexec();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members
Overload List


Rexec Constructor(IContainer)

[image]
PowerTCP Telnet for .NET
Rexec Constructor(IContainer)
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class > Rexec Constructor : Rexec Constructor(IContainer)

container
The container to which the Rexec component is added.
Initializes a new instance of the Rexec component.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal container As IContainer _
)
Visual Basic (Usage) Copy Code
Dim container As IContainer

Dim instance As New Rexec(container)
C#
public Rexec(
   IContainer container
)
Managed Extensions for C++
public: Rexec(
   IContainer* container
)
C++/CLI
public:
Rexec(
   IContainer^ container
)

Parameters

container
The container to which the Rexec component is added.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members
Overload List


Rexec Class Methods

[image]
PowerTCP Telnet for .NET
Rexec Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : Rexec Class

"

For a list of all members of this type, see Rexec members.

"

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to an Rexec server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | Execute | Executes a command on the remote host.
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rexec Class
Dart.Telnet Namespace


Connect Method

[image]
PowerTCP Telnet for .NET
Connect Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class : Connect Method

Connects to an Rexec server.

Overload List

Overload | Description
Connect(String) | Connects to an Rexec server.
Connect | Connects to a server using parameters found in the session parameter. (Inherited from Dart.Telnet.TcpBase)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members


Connect(String) Method

[image]
PowerTCP Telnet for .NET
Connect(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class > Connect Method : Connect(String) Method

hostNameOrAddress
The remote host name or address to connect to.
Connects to an Rexec server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Connect( _
   ByVal hostNameOrAddress As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rexec
Dim hostNameOrAddress As String

instance.Connect(hostNameOrAddress)
C#
public void Connect(
   string hostNameOrAddress
)
Managed Extensions for C++
public: void Connect(
   string* hostNameOrAddress
)
C++/CLI
public:
void Connect(
   String^ hostNameOrAddress
)

Parameters

hostNameOrAddress
The remote host name or address to connect to.

Remarks

This method attempts to connect to the remote host at the default port of 512.

Use Connect(TcpSession) to connect to a port other than 512.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members
Overload List


Execute Method

[image]
PowerTCP Telnet for .NET
Execute Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class : Execute Method

username
The login name of the user account.
password
The password of the user account.
command
The command to execute.
Executes a command on the remote host.

Syntax

Visual Basic (Declaration)
Public Sub Execute( _
   ByVal username As String, _
   ByVal password As String, _
   ByVal command As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rexec
Dim username As String
Dim password As String
Dim command As String

instance.Execute(username, password, command)
C#
public void Execute(
   string username,
   string password,
   string command
)
Managed Extensions for C++
public: void Execute(
   string* username,
   string* password,
   string* command
)
C++/CLI
public:
void Execute(
   String^ username,
   String^ password,
   String^ command
)

Parameters

username
The login name of the user account.
password
The password of the user account.
command
The command to execute.

Remarks

Use the Connect method to first connect to the remote host on the well-known port of 512. Then use Execute to authenticate using username and password and execute the command specified by command.

Use one of the Read methods to get the server's output.

When the server responds to a REXEC command, the first byte received indicates success/failure (0 for success, 1 for failure). When using the Rexec component, if the first byte is a 1 (meaning failure) an IOException is thrown. The Exception.Message will contain the response from the server without the first byte.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members


Start Method

[image]
PowerTCP Telnet for .NET
Start Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > Rexec Class : Start Method

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.
Starts a worker thread on which the specified delegate function executes.

Syntax

Visual Basic (Declaration)
Public Sub Start( _
   ByVal worker As WaitCallback, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As Rexec
Dim worker As WaitCallback
Dim state As Object

instance.Start(worker, state)
C#
public void Start(
   WaitCallback worker,
   object state
)
Managed Extensions for C++
public: void Start(
   WaitCallback* worker,
   Object* state
)
C++/CLI
public:
void Start(
   WaitCallback^ worker,
   Object^ state
)

Parameters

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method provides an easy means for executing blocking functions on a worker thread. Applications with a UI thread should use this technique to execute processes (like Connect and Read) that can block the UI thread.

The state parameter can be null for cases in which no state information needs to be passed to the worker delegate function.

Unhandled exceptions occurring on the worker thread will be caught and reported in the Error event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members


Rexec Class Fields

[image]
PowerTCP Telnet for .NET
Rexec Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : Rexec Class

"

For a list of all members of this type, see Rexec members.

"

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 512 for Rexec operations.
Top

See Also

Reference

Rexec Class
Dart.Telnet Namespace


DefaultPort Field

[image]
PowerTCP Telnet for .NET
DefaultPort Field
See Also Send comments on this topic.
Dart.Telnet Namespace > Rexec Class : DefaultPort Field

The "well-known" default port 512 for Rexec operations.

Syntax

Visual Basic (Declaration)
Public Const DefaultPort As Integer
Visual Basic (Usage) Copy Code
Dim value As Integer

value = Rexec.DefaultPort
C#
public const int DefaultPort
Managed Extensions for C++
public: const int DefaultPort
C++/CLI
public:
const int DefaultPort

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rexec Class
Rexec Members


Rlogin Class

[image]
PowerTCP Telnet for .NET
Rlogin Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Rlogin Class

The Rlogin component enables use of the remote login protocol within any .NET application.

Object Model

Rlogin ClassTcpSocketOption Class

Syntax

Visual Basic (Declaration)
<LicenseProviderAttribute(System.ComponentModel.LicenseProvider)>
<ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")>
<DescriptionAttribute("The Rlogin Component integrates event handling, Stream support, and a concise object model for on-line communications")>
Public Class Rlogin
   Inherits PtyBase
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
C#
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[DescriptionAttribute("The Rlogin Component integrates event handling, Stream support, and a concise object model for on-line communications")]
public class Rlogin : PtyBase
Managed Extensions for C++
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[DescriptionAttribute("The Rlogin Component integrates event handling, Stream support, and a concise object model for on-line communications")]
public __gc class Rlogin : public PtyBase
C++/CLI
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[DescriptionAttribute("The Rlogin Component integrates event handling, Stream support, and a concise object model for on-line communications")]
public ref class Rlogin : public PtyBase

Remarks

Use the Rlogin component to login to a remote host (typically a UNIX host). To use the Rlogin component, call the Connect and Login methods, passing in the appropriate parameters. Once connected, send commands to the remote host by using Write; receive data from the remote host using Read.

Rlogin is similar to Telnet, but has less complexity. Rlogin does not support telnet option negotiation, but does support the window size construct. Set the DisplayCharacters and DisplayPixels properties and the appropriate window size response is sent when the server requests this information.

Rlogin requires authorization for the local host running the application. To do this, add the appropriate entries to the hosts.equiv or .rhosts files located on the remote host. These files enable login from other machines and users. The hosts.equiv file is a system file containing names of remote hosts authorized to execute the remote protocol. If not authorized in this file, the remote host looks for the .rhosts file located in the user's account on the remote host. The .rhosts file contains lines of host names and login names paired together. If the remote hosts .rhosts file lacks an entry for the client, the server will request an interactive login, like Telnet.

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.PtyBase
Dart.Telnet.Rlogin

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Members
Dart.Telnet Namespace


Rlogin Class Members

[image]
PowerTCP Telnet for .NET
Rlogin Class Members
See Also Fields Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : Rlogin Class

The following tables list the members exposed by Rlogin.

Public Constructors

 | Name | Description
public Constructor | Rlogin Constructor | Overloaded.
Top

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 513 for Rlogin operations.
Top

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | CRLF | Set to true if the Pty property is used and a CR should be converted to a CRLF for sending. (Inherited from Dart.Telnet.PtyBase)
public Property | DisplayCharacters | Gets or sets a value representing the number of columns and rows sent to the host during login.
public Property | DisplayPixels | Gets or sets the size of the display sent to the remote host during login.
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | LocalEcho | Set to true if the Pty property is used and keystrokes should be displayed in the textbox. (Inherited from Dart.Telnet.PtyBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | Pty | Gets or sets a display control to use for automatic pseudo terminal support. (Inherited from Dart.Telnet.PtyBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
public Property | TerminalTypeSpeed | Gets or sets the terminal type and speed.
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to an Rlogin server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Login | Overloaded. Log into an Rlogin server.
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rlogin Class
Dart.Telnet Namespace


Rlogin Constructor

[image]
PowerTCP Telnet for .NET
Rlogin Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : Rlogin Constructor

Overload List

Overload | Description
Rlogin Constructor() | Initializes a new instance of the Rlogin component.
Rlogin Constructor(IContainer) | Initializes a new instance of the Rlogin component.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


Rlogin Constructor()

[image]
PowerTCP Telnet for .NET
Rlogin Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class > Rlogin Constructor : Rlogin Constructor()

Initializes a new instance of the Rlogin component.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Rlogin()
C#
public Rlogin()
Managed Extensions for C++
public: Rlogin();
C++/CLI
public:
Rlogin();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members
Overload List


Rlogin Constructor(IContainer)

[image]
PowerTCP Telnet for .NET
Rlogin Constructor(IContainer)
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class > Rlogin Constructor : Rlogin Constructor(IContainer)

container
The container to which the Rlogin component is added.
Initializes a new instance of the Rlogin component.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal container As IContainer _
)
Visual Basic (Usage) Copy Code
Dim container As IContainer

Dim instance As New Rlogin(container)
C#
public Rlogin(
   IContainer container
)
Managed Extensions for C++
public: Rlogin(
   IContainer* container
)
C++/CLI
public:
Rlogin(
   IContainer^ container
)

Parameters

container
The container to which the Rlogin component is added.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members
Overload List


Rlogin Class Methods

[image]
PowerTCP Telnet for .NET
Rlogin Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : Rlogin Class

"

For a list of all members of this type, see Rlogin members.

"

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to an Rlogin server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Login | Overloaded. Log into an Rlogin server.
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rlogin Class
Dart.Telnet Namespace


Connect Method

[image]
PowerTCP Telnet for .NET
Connect Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : Connect Method

Connects to an Rlogin server.

Overload List

Overload | Description
Connect(String) | Connects to an Rlogin server.
Connect | Connects to a server using parameters found in the session parameter. (Inherited from Dart.Telnet.TcpBase)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


Connect(String) Method

[image]
PowerTCP Telnet for .NET
Connect(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class > Connect Method : Connect(String) Method

hostNameOrAddress
The remote host name or address to connect to.
Connects to an Rlogin server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Connect( _
   ByVal hostNameOrAddress As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim hostNameOrAddress As String

instance.Connect(hostNameOrAddress)
C#
public void Connect(
   string hostNameOrAddress
)
Managed Extensions for C++
public: void Connect(
   string* hostNameOrAddress
)
C++/CLI
public:
void Connect(
   String^ hostNameOrAddress
)

Parameters

hostNameOrAddress
The remote host name or address to connect to.

Remarks

This method attempts to connect to the remote host at the default port of 513.

Since the rlogin and rsh protocols require a local port between 512 and 1023 (inclusively), this library attempts to bind to an open local port within this range. This feature allows you to use this protocol hundreds of times without running out of local ports.

Use alternative Connect overloads to connect to a port other than 513.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members
Overload List


Login Method

[image]
PowerTCP Telnet for .NET
Login Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : Login Method

Log into an Rlogin server.

Overload List

Overload | Description
Login(String) | Log into an Rlogin server.
Login(String,String) | Log into an Rlogin server.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


Login(String) Method

[image]
PowerTCP Telnet for .NET
Login(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class > Login Method : Login(String) Method

username
The username sent during login.
Log into an Rlogin server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Login( _
   ByVal username As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim username As String

instance.Login(username)
C#
public void Login(
   string username
)
Managed Extensions for C++
public: void Login(
   string* username
)
C++/CLI
public:
void Login(
   String^ username
)

Parameters

username
The username sent during login.

Remarks

This method should be used after the Connect method completes successfully.

The username is the login name of the user as known on the server.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members
Overload List


Login(String,String) Method

[image]
PowerTCP Telnet for .NET
Login(String,String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class > Login Method : Login(String,String) Method

username
The username sent during login.
clientUsername
Login name of the user on the client host.
Log into an Rlogin server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Login( _
   ByVal username As String, _
   ByVal clientUsername As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim username As String
Dim clientUsername As String

instance.Login(username, clientUsername)
C#
public void Login(
   string username,
   string clientUsername
)
Managed Extensions for C++
public: void Login(
   string* username,
   string* clientUsername
)
C++/CLI
public:
void Login(
   String^ username,
   String^ clientUsername
)

Parameters

username
The username sent during login.
clientUsername
Login name of the user on the client host.

Remarks

This method should be used after the Connect method completes successfully.

The username is the login name of the user as known on the server. The clientUsername may be used if the client username differs from the server username.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members
Overload List


Start Method

[image]
PowerTCP Telnet for .NET
Start Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : Start Method

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.
Starts a worker thread on which the specified delegate function executes.

Syntax

Visual Basic (Declaration)
Public Sub Start( _
   ByVal worker As WaitCallback, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim worker As WaitCallback
Dim state As Object

instance.Start(worker, state)
C#
public void Start(
   WaitCallback worker,
   object state
)
Managed Extensions for C++
public: void Start(
   WaitCallback* worker,
   Object* state
)
C++/CLI
public:
void Start(
   WaitCallback^ worker,
   Object^ state
)

Parameters

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method provides an easy means for executing blocking functions on a worker thread. Applications with a UI thread should use this technique to execute processes (like Connect and Read) that can block the UI thread.

The state parameter can be null for cases in which no state information needs to be passed to the worker delegate function.

Unhandled exceptions occurring on the worker thread will be caught and reported in the Error event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


Rlogin Class Properties

[image]
PowerTCP Telnet for .NET
Rlogin Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Rlogin Class

"

For a list of all members of this type, see Rlogin members.

"

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | CRLF | Set to true if the Pty property is used and a CR should be converted to a CRLF for sending. (Inherited from Dart.Telnet.PtyBase)
public Property | DisplayCharacters | Gets or sets a value representing the number of columns and rows sent to the host during login.
public Property | DisplayPixels | Gets or sets the size of the display sent to the remote host during login.
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | LocalEcho | Set to true if the Pty property is used and keystrokes should be displayed in the textbox. (Inherited from Dart.Telnet.PtyBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | Pty | Gets or sets a display control to use for automatic pseudo terminal support. (Inherited from Dart.Telnet.PtyBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
public Property | TerminalTypeSpeed | Gets or sets the terminal type and speed.
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

Rlogin Class
Dart.Telnet Namespace


DisplayCharacters Property

[image]
PowerTCP Telnet for .NET
DisplayCharacters Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : DisplayCharacters Property

Gets or sets a value representing the number of columns and rows sent to the host during login.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Number of columns and rows that will be sent to the host during login.")>
<DefaultValueAttribute()>
<CategoryAttribute("Rlogin")>
Public Property DisplayCharacters As Size
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim value As Size

instance.DisplayCharacters = value

value = instance.DisplayCharacters
C#
[DescriptionAttribute("Number of columns and rows that will be sent to the host during login.")]
[DefaultValueAttribute()]
[CategoryAttribute("Rlogin")]
public Size DisplayCharacters {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Number of columns and rows that will be sent to the host during login.")]
[DefaultValueAttribute()]
[CategoryAttribute("Rlogin")]
public: __property Size get_DisplayCharacters();
public: __property void set_DisplayCharacters(
   Size value
);
C++/CLI
[DescriptionAttribute("Number of columns and rows that will be sent to the host during login.")]
[DefaultValueAttribute()]
[CategoryAttribute("Rlogin")]
public:
property Size DisplayCharacters {
   Size get();
   void set (    Size value);
}

Property Value

A Size object representing character display information. Defaults to (72, 24).

Remarks

When using the Rlogin protocol, the remote host may request window size information. The Rlogin component will reply with the value of this property and the Rlogin.DisplayPixels property.

Height represents the number of character rows (defaults to 24). Width represents the number of characters per row (defaults to 72).

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


DisplayPixels Property

[image]
PowerTCP Telnet for .NET
DisplayPixels Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : DisplayPixels Property

Gets or sets the size of the display sent to the remote host during login.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Pixel size of the display that will be sent to the host during login.")>
<CategoryAttribute("Rlogin")>
Public Property DisplayPixels As Size
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim value As Size

instance.DisplayPixels = value

value = instance.DisplayPixels
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Pixel size of the display that will be sent to the host during login.")]
[CategoryAttribute("Rlogin")]
public Size DisplayPixels {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Pixel size of the display that will be sent to the host during login.")]
[CategoryAttribute("Rlogin")]
public: __property Size get_DisplayPixels();
public: __property void set_DisplayPixels(
   Size value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Pixel size of the display that will be sent to the host during login.")]
[CategoryAttribute("Rlogin")]
public:
property Size DisplayPixels {
   Size get();
   void set (    Size value);
}

Property Value

A Size object representing the pixel size of the display. Defaults to (640, 480).

Remarks

When using the Rlogin protocol, the remote host may request window size information. The Rlogin component will reply with the value of the DisplayCharacters property and this property.

Height represents number of client window pixels in the Y direction (defaults to 640). Width represents number of client window pixels in the X direction (defaults to 480).

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


TerminalTypeSpeed Property

[image]
PowerTCP Telnet for .NET
TerminalTypeSpeed Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : TerminalTypeSpeed Property

Gets or sets the terminal type and speed.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("TerminalType and Speed that will be sent to the host during login.")>
<DefaultValueAttribute()>
<CategoryAttribute("Rlogin")>
Public Property TerminalTypeSpeed As String
Visual Basic (Usage) Copy Code
Dim instance As Rlogin
Dim value As String

instance.TerminalTypeSpeed = value

value = instance.TerminalTypeSpeed
C#
[DescriptionAttribute("TerminalType and Speed that will be sent to the host during login.")]
[DefaultValueAttribute()]
[CategoryAttribute("Rlogin")]
public string TerminalTypeSpeed {get; set;}
Managed Extensions for C++
[DescriptionAttribute("TerminalType and Speed that will be sent to the host during login.")]
[DefaultValueAttribute()]
[CategoryAttribute("Rlogin")]
public: __property string* get_TerminalTypeSpeed();
public: __property void set_TerminalTypeSpeed(
   string* value
);
C++/CLI
[DescriptionAttribute("TerminalType and Speed that will be sent to the host during login.")]
[DefaultValueAttribute()]
[CategoryAttribute("Rlogin")]
public:
property String^ TerminalTypeSpeed {
   String^ get();
   void set (    String^ value);
}

Property Value

A string representing the terminal type and speed. Defaults to "vt320/19200".

Remarks

The Rlogin protocol dictates that client terminal type and terminal speed is sent to the remote host during login. Set this property before logging in.

The format for this string is [terminal type]/[terminal speed]. For example, "vt320/19200".

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


Rlogin Class Fields

[image]
PowerTCP Telnet for .NET
Rlogin Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : Rlogin Class

"

For a list of all members of this type, see Rlogin members.

"

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 513 for Rlogin operations.
Top

See Also

Reference

Rlogin Class
Dart.Telnet Namespace


DefaultPort Field

[image]
PowerTCP Telnet for .NET
DefaultPort Field
See Also Send comments on this topic.
Dart.Telnet Namespace > Rlogin Class : DefaultPort Field

The "well-known" default port 513 for Rlogin operations.

Syntax

Visual Basic (Declaration)
Public Const DefaultPort As Integer
Visual Basic (Usage) Copy Code
Dim value As Integer

value = Rlogin.DefaultPort
C#
public const int DefaultPort
Managed Extensions for C++
public: const int DefaultPort
C++/CLI
public:
const int DefaultPort

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rlogin Class
Rlogin Members


Rsh Class

[image]
PowerTCP Telnet for .NET
Rsh Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Rsh Class

The Rsh component enables use of the remote shell protocol within any .NET application.

Object Model

Rsh ClassTcpSocketOption Class

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("The Rsh Component integrates event handling, Stream support, and a concise object model for on-line communications")>
<ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")>
<LicenseProviderAttribute(System.ComponentModel.LicenseProvider)>
Public Class Rsh
   Inherits TcpBase
Visual Basic (Usage) Copy Code
Dim instance As Rsh
C#
[DescriptionAttribute("The Rsh Component integrates event handling, Stream support, and a concise object model for on-line communications")]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
public class Rsh : TcpBase
Managed Extensions for C++
[DescriptionAttribute("The Rsh Component integrates event handling, Stream support, and a concise object model for on-line communications")]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
public __gc class Rsh : public TcpBase
C++/CLI
[DescriptionAttribute("The Rsh Component integrates event handling, Stream support, and a concise object model for on-line communications")]
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
public ref class Rsh : public TcpBase

Remarks

Use the Rsh component to execute a command on a remote host (typically a UNIX host). To use the Rsh component, call Connect to connect, call one of the Execute methods to execute the command, and then use one of the Read methods to read the results of the command.

Rexec and Rsh perform the same task using different authentication techniques. Rsh requires static information be added to .rhosts and/or hosts.equiv, whereas Rexec simply uses dynamic username/password information for authentication.

Using Rsh requires authorization for the local host running the application. To do this, add the appropriate entries to the hosts.equiv or .rhosts files located on the remote host. These files enable login from other machines and users. The hosts.equiv file is a system file containing names of remote hosts authorized to execute the remote protocol. If not authorized in this file, the remote host looks for the .rhosts file located in the user's account on the remote host. The .rhosts file contains lines of host names and login names paired together. Your local host with login name is authorized if found in this file.

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.Rsh

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Members
Dart.Telnet Namespace


Rsh Class Members

[image]
PowerTCP Telnet for .NET
Rsh Class Members
See Also Fields Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : Rsh Class

The following tables list the members exposed by Rsh.

Public Constructors

 | Name | Description
public Constructor | Rsh Constructor | Overloaded.
Top

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 514 for Rsh operations.
Top

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to an Rsh server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | Execute | Overloaded. Execute a command on the Rsh server.
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rsh Class
Dart.Telnet Namespace


Rsh Constructor

[image]
PowerTCP Telnet for .NET
Rsh Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class : Rsh Constructor

Overload List

Overload | Description
Rsh Constructor() | Initializes a new instance of the Rsh component.
Rsh Constructor(IContainer) | Initializes a new instance of the Rsh component.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members


Rsh Constructor()

[image]
PowerTCP Telnet for .NET
Rsh Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class > Rsh Constructor : Rsh Constructor()

Initializes a new instance of the Rsh component.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Rsh()
C#
public Rsh()
Managed Extensions for C++
public: Rsh();
C++/CLI
public:
Rsh();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members
Overload List


Rsh Constructor(IContainer)

[image]
PowerTCP Telnet for .NET
Rsh Constructor(IContainer)
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class > Rsh Constructor : Rsh Constructor(IContainer)

container
The container to which the Rsh component is added.
Initializes a new instance of the Rsh component.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal container As IContainer _
)
Visual Basic (Usage) Copy Code
Dim container As IContainer

Dim instance As New Rsh(container)
C#
public Rsh(
   IContainer container
)
Managed Extensions for C++
public: Rsh(
   IContainer* container
)
C++/CLI
public:
Rsh(
   IContainer^ container
)

Parameters

container
The container to which the Rsh component is added.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members
Overload List


Rsh Class Methods

[image]
PowerTCP Telnet for .NET
Rsh Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : Rsh Class

"

For a list of all members of this type, see Rsh members.

"

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to an Rsh server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | Execute | Overloaded. Execute a command on the Rsh server.
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rsh Class
Dart.Telnet Namespace


Connect Method

[image]
PowerTCP Telnet for .NET
Connect Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class : Connect Method

Connects to an Rsh server.

Overload List

Overload | Description
Connect(String) | Connects to an Rsh server.
Connect | Connects to a server using parameters found in the session parameter. (Inherited from Dart.Telnet.TcpBase)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members


Connect(String) Method

[image]
PowerTCP Telnet for .NET
Connect(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class > Connect Method : Connect(String) Method

hostNameOrAddress
The remote host name or address to connect to.
Connects to an Rsh server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Connect( _
   ByVal hostNameOrAddress As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rsh
Dim hostNameOrAddress As String

instance.Connect(hostNameOrAddress)
C#
public void Connect(
   string hostNameOrAddress
)
Managed Extensions for C++
public: void Connect(
   string* hostNameOrAddress
)
C++/CLI
public:
void Connect(
   String^ hostNameOrAddress
)

Parameters

hostNameOrAddress
The remote host name or address to connect to.

Remarks

This method attempts to connect to the remote host at the default port of 514.

Since the rlogin and rsh protocols require a local port between 512 and 1023 (inclusively), this library attempts to bind to an open local port within this range. This feature allows you to use this protocol hundreds of times without running out of local ports.

Use alternative Connect overloads to connect to a port other than 514.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members
Overload List


Execute Method

[image]
PowerTCP Telnet for .NET
Execute Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class : Execute Method

Execute a command on the Rsh server.

Overload List

Overload | Description
Execute(String,String) | Execute a command on the Rsh server.
Execute(String,String,String) | Execute a command on the Rsh server.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members


Execute(String,String) Method

[image]
PowerTCP Telnet for .NET
Execute(String,String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class > Execute Method : Execute(String,String) Method

username
The login name of the user account.
command
The command to execute.
Execute a command on the Rsh server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Execute( _
   ByVal username As String, _
   ByVal command As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rsh
Dim username As String
Dim command As String

instance.Execute(username, command)
C#
public void Execute(
   string username,
   string command
)
Managed Extensions for C++
public: void Execute(
   string* username,
   string* command
)
C++/CLI
public:
void Execute(
   String^ username,
   String^ command
)

Parameters

username
The login name of the user account.
command
The command to execute.

Remarks

This method executes the command specified by command. A Read method should be used to get the results.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members
Overload List


Execute(String,String,String) Method

[image]
PowerTCP Telnet for .NET
Execute(String,String,String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class > Execute Method : Execute(String,String,String) Method

username
The login name of the user as known to the server.
command
The command to execute.
clientUsername
Login name of the user on the client host.
Execute a command on the Rsh server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Execute( _
   ByVal username As String, _
   ByVal command As String, _
   ByVal clientUsername As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Rsh
Dim username As String
Dim command As String
Dim clientUsername As String

instance.Execute(username, command, clientUsername)
C#
public void Execute(
   string username,
   string command,
   string clientUsername
)
Managed Extensions for C++
public: void Execute(
   string* username,
   string* command,
   string* clientUsername
)
C++/CLI
public:
void Execute(
   String^ username,
   String^ command,
   String^ clientUsername
)

Parameters

username
The login name of the user as known to the server.
command
The command to execute.
clientUsername
Login name of the user on the client host.

Remarks

This method executes the command specified by command. A Read method should be used to get the results.

The username is the login name of the user as known on the server. The clientUsername may be used if the client username differs from the server username.

Use Connect(TcpSession) to connect to a port other than 514.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members
Overload List


Start Method

[image]
PowerTCP Telnet for .NET
Start Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > Rsh Class : Start Method

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.
Starts a worker thread on which the specified delegate function executes.

Syntax

Visual Basic (Declaration)
Public Sub Start( _
   ByVal worker As WaitCallback, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As Rsh
Dim worker As WaitCallback
Dim state As Object

instance.Start(worker, state)
C#
public void Start(
   WaitCallback worker,
   object state
)
Managed Extensions for C++
public: void Start(
   WaitCallback* worker,
   Object* state
)
C++/CLI
public:
void Start(
   WaitCallback^ worker,
   Object^ state
)

Parameters

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method provides an easy means for executing blocking functions on a worker thread. Applications with a UI thread should use this technique to execute processes (like Connect and Read) that can block the UI thread.

The state parameter can be null for cases in which no state information needs to be passed to the worker delegate function.

Unhandled exceptions occurring on the worker thread will be caught and reported in the Error event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members


Rsh Class Fields

[image]
PowerTCP Telnet for .NET
Rsh Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : Rsh Class

"

For a list of all members of this type, see Rsh members.

"

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 514 for Rsh operations.
Top

See Also

Reference

Rsh Class
Dart.Telnet Namespace


DefaultPort Field

[image]
PowerTCP Telnet for .NET
DefaultPort Field
See Also Send comments on this topic.
Dart.Telnet Namespace > Rsh Class : DefaultPort Field

The "well-known" default port 514 for Rsh operations.

Syntax

Visual Basic (Declaration)
Public Const DefaultPort As Integer
Visual Basic (Usage) Copy Code
Dim value As Integer

value = Rsh.DefaultPort
C#
public const int DefaultPort
Managed Extensions for C++
public: const int DefaultPort
C++/CLI
public:
const int DefaultPort

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Rsh Class
Rsh Members


Security Class

[image]
PowerTCP Telnet for .NET
Security Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Security Class

Base Security class to be passed to authenticate methods.

Object Model

Security Class

Syntax

Visual Basic (Declaration)
<SerializableAttribute()>
Public Class Security
Visual Basic (Usage) Copy Code
Dim instance As Security
C#
[SerializableAttribute()]
public class Security
Managed Extensions for C++
[SerializableAttribute()]
public __gc class Security
C++/CLI
[SerializableAttribute()]
public ref class Security

Inheritance Hierarchy

System.Object
Dart.Telnet.Security
Dart.Telnet.ClientSecurity
Dart.Telnet.ServerSecurity

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Security Members
Dart.Telnet Namespace


Security Class Members

[image]
PowerTCP Telnet for .NET
Security Class Members
See Also Fields Properties Send comments on this topic.
Dart.Telnet Namespace : Security Class

The following tables list the members exposed by Security.

Public Constructors

 | Name | Description
public Constructor | Security Constructor |
Top

Public Fields

 | Name | Description
public Field | ValidationCallback | The delegate that executes after the server provides its certificate to the client.
Top

Public Properties

 | Name | Description
public Property | CheckCertificateRevocation | Indicates whether the certificate revocation list is checked during authentication.
public Property | Protocols | Gets or sets the SSLProtocols available for authentication.
Top

See Also

Reference

Security Class
Dart.Telnet Namespace


Security Constructor

[image]
PowerTCP Telnet for .NET
Security Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Security Class : Security Constructor

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Security()
C#
public Security()
Managed Extensions for C++
public: Security();
C++/CLI
public:
Security();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Security Class
Security Members


Security Class Properties

[image]
PowerTCP Telnet for .NET
Security Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Security Class

"

For a list of all members of this type, see Security members.

"

Public Properties

 | Name | Description
public Property | CheckCertificateRevocation | Indicates whether the certificate revocation list is checked during authentication.
public Property | Protocols | Gets or sets the SSLProtocols available for authentication.
Top

See Also

Reference

Security Class
Dart.Telnet Namespace


CheckCertificateRevocation Property

[image]
PowerTCP Telnet for .NET
CheckCertificateRevocation Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Security Class : CheckCertificateRevocation Property

Indicates whether the certificate revocation list is checked during authentication.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Indicates whether the certificate revocation list is checked during authentication.")>
<DefaultValueAttribute()>
Public Property CheckCertificateRevocation As Boolean
Visual Basic (Usage) Copy Code
Dim instance As Security
Dim value As Boolean

instance.CheckCertificateRevocation = value

value = instance.CheckCertificateRevocation
C#
[DescriptionAttribute("Indicates whether the certificate revocation list is checked during authentication.")]
[DefaultValueAttribute()]
public bool CheckCertificateRevocation {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Indicates whether the certificate revocation list is checked during authentication.")]
[DefaultValueAttribute()]
public: __property bool get_CheckCertificateRevocation();
public: __property void set_CheckCertificateRevocation(
   bool value
);
C++/CLI
[DescriptionAttribute("Indicates whether the certificate revocation list is checked during authentication.")]
[DefaultValueAttribute()]
public:
property bool CheckCertificateRevocation {
   bool get();
   void set (    bool value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Security Class
Security Members


Protocols Property

[image]
PowerTCP Telnet for .NET
Protocols Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Security Class : Protocols Property

Gets or sets the SSLProtocols available for authentication.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Gets or sets the SSLProtocols available for authentication.")>
Public Property Protocols As SslProtocols
Visual Basic (Usage) Copy Code
Dim instance As Security
Dim value As SslProtocols

instance.Protocols = value

value = instance.Protocols
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the SSLProtocols available for authentication.")]
public SslProtocols Protocols {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the SSLProtocols available for authentication.")]
public: __property SslProtocols get_Protocols();
public: __property void set_Protocols(
   SslProtocols value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the SSLProtocols available for authentication.")]
public:
property SslProtocols Protocols {
   SslProtocols get();
   void set (    SslProtocols value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Security Class
Security Members


Security Class Fields

[image]
PowerTCP Telnet for .NET
Security Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : Security Class

"

For a list of all members of this type, see Security members.

"

Public Fields

 | Name | Description
public Field | ValidationCallback | The delegate that executes after the server provides its certificate to the client.
Top

See Also

Reference

Security Class
Dart.Telnet Namespace


ValidationCallback Field

[image]
PowerTCP Telnet for .NET
ValidationCallback Field
See Also Send comments on this topic.
Dart.Telnet Namespace > Security Class : ValidationCallback Field

The delegate that executes after the server provides its certificate to the client.

Syntax

Visual Basic (Declaration)
Public ValidationCallback As RemoteCertificateValidationCallback
Visual Basic (Usage) Copy Code
Dim instance As Security
Dim value As RemoteCertificateValidationCallback

value = instance.ValidationCallback

instance.ValidationCallback = value
C#
public RemoteCertificateValidationCallback ValidationCallback
Managed Extensions for C++
public: RemoteCertificateValidationCallback* ValidationCallback
C++/CLI
public:
RemoteCertificateValidationCallback^ ValidationCallback

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Security Class
Security Members


Segment Class

[image]
PowerTCP Telnet for .NET
Segment Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Segment Class

Class used to encapsulate a byte[] segment.

Object Model

Segment Class

Syntax

Visual Basic (Declaration)
Public Class Segment
Visual Basic (Usage) Copy Code
Dim instance As Segment
C#
public class Segment
Managed Extensions for C++
public __gc class Segment
C++/CLI
public ref class Segment

Inheritance Hierarchy

System.Object
Dart.Telnet.Segment
Dart.Telnet.Data

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Segment Members
Dart.Telnet Namespace


Segment Class Members

[image]
PowerTCP Telnet for .NET
Segment Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : Segment Class

The following tables list the members exposed by Segment.

Public Constructors

 | Name | Description
public Constructor | Segment Constructor | Used to create a Segment object that holds a buffer of data.
Top

Public Properties

 | Name | Description
public Property | Buffer | Gets the buffer that holds data.
public Property | Count | Byte count of data.
public Property | Offset | The offset into the buffer where the data starts.
Top

See Also

Reference

Segment Class
Dart.Telnet Namespace


Segment Constructor

[image]
PowerTCP Telnet for .NET
Segment Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Segment Class : Segment Constructor

buffer
Byte[] containing data.
offset
Offset into the buffer where the data starts.
count
Byte count of data.
Used to create a Segment object that holds a buffer of data.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal buffer() As Byte, _
   ByVal offset As Integer, _
   ByVal count As Integer _
)
Visual Basic (Usage) Copy Code
Dim buffer() As Byte
Dim offset As Integer
Dim count As Integer

Dim instance As New Segment(buffer, offset, count)
C#
public Segment(
   byte[] buffer,
   int offset,
   int count
)
Managed Extensions for C++
public: Segment(
   byte[]* buffer,
   int offset,
   int count
)
C++/CLI
public:
Segment(
   array<byte>^ buffer,
   int offset,
   int count
)

Parameters

buffer
Byte[] containing data.
offset
Offset into the buffer where the data starts.
count
Byte count of data.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Segment Class
Segment Members


Segment Class Properties

[image]
PowerTCP Telnet for .NET
Segment Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Segment Class

"

For a list of all members of this type, see Segment members.

"

Public Properties

 | Name | Description
public Property | Buffer | Gets the buffer that holds data.
public Property | Count | Byte count of data.
public Property | Offset | The offset into the buffer where the data starts.
Top

See Also

Reference

Segment Class
Dart.Telnet Namespace


Buffer Property

[image]
PowerTCP Telnet for .NET
Buffer Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Segment Class : Buffer Property

Gets the buffer that holds data.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Buffer As Byte()
Visual Basic (Usage) Copy Code
Dim instance As Segment
Dim value() As Byte

value = instance.Buffer
C#
public byte[] Buffer {get;}
Managed Extensions for C++
public: __property byte[]* get_Buffer();
C++/CLI
public:
property array<byte>^ Buffer {
   array<byte>^ get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Segment Class
Segment Members


Count Property

[image]
PowerTCP Telnet for .NET
Count Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Segment Class : Count Property

Byte count of data.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Count As Integer
Visual Basic (Usage) Copy Code
Dim instance As Segment
Dim value As Integer

value = instance.Count
C#
public int Count {get;}
Managed Extensions for C++
public: __property int get_Count();
C++/CLI
public:
property int Count {
   int get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Segment Class
Segment Members


Offset Property

[image]
PowerTCP Telnet for .NET
Offset Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Segment Class : Offset Property

The offset into the buffer where the data starts.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Offset As Integer
Visual Basic (Usage) Copy Code
Dim instance As Segment
Dim value As Integer

value = instance.Offset
C#
public int Offset {get;}
Managed Extensions for C++
public: __property int get_Offset();
C++/CLI
public:
property int Offset {
   int get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Segment Class
Segment Members


ServerSecurity Class

[image]
PowerTCP Telnet for .NET
ServerSecurity Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : ServerSecurity Class

Class to be passed to AuthenticateAsServer().

Object Model

ServerSecurity Class

Syntax

Visual Basic (Declaration)
<SerializableAttribute()>
Public Class ServerSecurity
   Inherits Security
Visual Basic (Usage) Copy Code
Dim instance As ServerSecurity
C#
[SerializableAttribute()]
public class ServerSecurity : Security
Managed Extensions for C++
[SerializableAttribute()]
public __gc class ServerSecurity : public Security
C++/CLI
[SerializableAttribute()]
public ref class ServerSecurity : public Security

Inheritance Hierarchy

System.Object
Dart.Telnet.Security
Dart.Telnet.ServerSecurity

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ServerSecurity Members
Dart.Telnet Namespace


ServerSecurity Class Members

[image]
PowerTCP Telnet for .NET
ServerSecurity Class Members
See Also Fields Properties Send comments on this topic.
Dart.Telnet Namespace : ServerSecurity Class

The following tables list the members exposed by ServerSecurity.

Public Constructors

 | Name | Description
public Constructor | ServerSecurity Constructor |
Top

Public Fields

 | Name | Description
public Field | ValidationCallback | The delegate that executes after the server provides its certificate to the client. (Inherited from Dart.Telnet.Security)
Top

Public Properties

 | Name | Description
public Property | Certificate | Gets or sets the server certificate to provide the client.
public Property | CheckCertificateRevocation | Indicates whether the certificate revocation list is checked during authentication. (Inherited from Dart.Telnet.Security)
public Property | Protocols | Gets or sets the SSLProtocols available for authentication. (Inherited from Dart.Telnet.Security)
public Property | RequireClientCertificate | Indicates whether the server requires a client certificate.
Top

See Also

Reference

ServerSecurity Class
Dart.Telnet Namespace


ServerSecurity Constructor

[image]
PowerTCP Telnet for .NET
ServerSecurity Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > ServerSecurity Class : ServerSecurity Constructor

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New ServerSecurity()
C#
public ServerSecurity()
Managed Extensions for C++
public: ServerSecurity();
C++/CLI
public:
ServerSecurity();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ServerSecurity Class
ServerSecurity Members


ServerSecurity Class Properties

[image]
PowerTCP Telnet for .NET
ServerSecurity Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : ServerSecurity Class

"

For a list of all members of this type, see ServerSecurity members.

"

Public Properties

 | Name | Description
public Property | Certificate | Gets or sets the server certificate to provide the client.
public Property | CheckCertificateRevocation | Indicates whether the certificate revocation list is checked during authentication. (Inherited from Dart.Telnet.Security)
public Property | Protocols | Gets or sets the SSLProtocols available for authentication. (Inherited from Dart.Telnet.Security)
public Property | RequireClientCertificate | Indicates whether the server requires a client certificate.
Top

See Also

Reference

ServerSecurity Class
Dart.Telnet Namespace


Certificate Property

[image]
PowerTCP Telnet for .NET
Certificate Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ServerSecurity Class : Certificate Property

Gets or sets the server certificate to provide the client.

Syntax

Visual Basic (Declaration)
Public Property Certificate As X509Certificate
Visual Basic (Usage) Copy Code
Dim instance As ServerSecurity
Dim value As X509Certificate

instance.Certificate = value

value = instance.Certificate
C#
public X509Certificate Certificate {get; set;}
Managed Extensions for C++
public: __property X509Certificate* get_Certificate();
public: __property void set_Certificate(
   X509Certificate* value
);
C++/CLI
public:
property X509Certificate^ Certificate {
   X509Certificate^ get();
   void set (    X509Certificate^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ServerSecurity Class
ServerSecurity Members


RequireClientCertificate Property

[image]
PowerTCP Telnet for .NET
RequireClientCertificate Property
See Also Send comments on this topic.
Dart.Telnet Namespace > ServerSecurity Class : RequireClientCertificate Property

Indicates whether the server requires a client certificate.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Indicates whether the server requires a client certificate.")>
<DefaultValueAttribute()>
Public Property RequireClientCertificate As Boolean
Visual Basic (Usage) Copy Code
Dim instance As ServerSecurity
Dim value As Boolean

instance.RequireClientCertificate = value

value = instance.RequireClientCertificate
C#
[DescriptionAttribute("Indicates whether the server requires a client certificate.")]
[DefaultValueAttribute()]
public bool RequireClientCertificate {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Indicates whether the server requires a client certificate.")]
[DefaultValueAttribute()]
public: __property bool get_RequireClientCertificate();
public: __property void set_RequireClientCertificate(
   bool value
);
C++/CLI
[DescriptionAttribute("Indicates whether the server requires a client certificate.")]
[DefaultValueAttribute()]
public:
property bool RequireClientCertificate {
   bool get();
   void set (    bool value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ServerSecurity Class
ServerSecurity Members


Session Class

[image]
PowerTCP Telnet for .NET
Session Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : Session Class

Provides a holder for parameters used to establish a session.

Object Model

Session ClassIPEndPoint ClassIPEndPoint Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class Session
Visual Basic (Usage) Copy Code
Dim instance As Session
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class Session
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class Session
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class Session

Inheritance Hierarchy

System.Object
Dart.Telnet.Session
Dart.Telnet.TcpSession

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Session Members
Dart.Telnet Namespace


Session Class Members

[image]
PowerTCP Telnet for .NET
Session Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : Session Class

The following tables list the members exposed by Session.

Public Constructors

 | Name | Description
public Constructor | Session Constructor | Overloaded.
Top

Public Properties

 | Name | Description
public Property | LocalEndPoint | EndPoint to bind to locally.
public Property | RemoteEndPoint | EndPoint of the remote host to connect to.
Top

See Also

Reference

Session Class
Dart.Telnet Namespace


Session Constructor

[image]
PowerTCP Telnet for .NET
Session Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Session Class : Session Constructor

Overload List

Overload | Description
Session Constructor() | Default constructor for Session.
Session Constructor(IPEndPoint) | Constructor for Session with a Remote IPEndPoint parameter.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Session Class
Session Members


Session Constructor()

[image]
PowerTCP Telnet for .NET
Session Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Session Class > Session Constructor : Session Constructor()

Default constructor for Session.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Session()
C#
public Session()
Managed Extensions for C++
public: Session();
C++/CLI
public:
Session();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Session Class
Session Members
Overload List


Session Constructor(IPEndPoint)

[image]
PowerTCP Telnet for .NET
Session Constructor(IPEndPoint)
See Also Send comments on this topic.
Dart.Telnet Namespace > Session Class > Session Constructor : Session Constructor(IPEndPoint)

remoteEP
The remote IPEndPoint to connect to.
Constructor for Session with a Remote IPEndPoint parameter.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal remoteEP As IPEndPoint _
)
Visual Basic (Usage) Copy Code
Dim remoteEP As IPEndPoint

Dim instance As New Session(remoteEP)
C#
public Session(
   IPEndPoint remoteEP
)
Managed Extensions for C++
public: Session(
   IPEndPoint* remoteEP
)
C++/CLI
public:
Session(
   IPEndPoint^ remoteEP
)

Parameters

remoteEP
The remote IPEndPoint to connect to.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Session Class
Session Members
Overload List


Session Class Properties

[image]
PowerTCP Telnet for .NET
Session Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Session Class

"

For a list of all members of this type, see Session members.

"

Public Properties

 | Name | Description
public Property | LocalEndPoint | EndPoint to bind to locally.
public Property | RemoteEndPoint | EndPoint of the remote host to connect to.
Top

See Also

Reference

Session Class
Dart.Telnet Namespace


LocalEndPoint Property

[image]
PowerTCP Telnet for .NET
LocalEndPoint Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Session Class : LocalEndPoint Property

EndPoint to bind to locally.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Local IPEndPoint to bind to.")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<DefaultValueAttribute()>
Public Property LocalEndPoint As IPEndPoint
Visual Basic (Usage) Copy Code
Dim instance As Session
Dim value As IPEndPoint

instance.LocalEndPoint = value

value = instance.LocalEndPoint
C#
[DescriptionAttribute("Local IPEndPoint to bind to.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DefaultValueAttribute()]
public IPEndPoint LocalEndPoint {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Local IPEndPoint to bind to.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DefaultValueAttribute()]
public: __property IPEndPoint* get_LocalEndPoint();
public: __property void set_LocalEndPoint(
   IPEndPoint* value
);
C++/CLI
[DescriptionAttribute("Local IPEndPoint to bind to.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DefaultValueAttribute()]
public:
property IPEndPoint^ LocalEndPoint {
   IPEndPoint^ get();
   void set (    IPEndPoint^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Session Class
Session Members


RemoteEndPoint Property

[image]
PowerTCP Telnet for .NET
RemoteEndPoint Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Session Class : RemoteEndPoint Property

EndPoint of the remote host to connect to.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("IPEndPoint of the remote server to connect to.")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
Public Property RemoteEndPoint As IPEndPoint
Visual Basic (Usage) Copy Code
Dim instance As Session
Dim value As IPEndPoint

instance.RemoteEndPoint = value

value = instance.RemoteEndPoint
C#
[DefaultValueAttribute()]
[DescriptionAttribute("IPEndPoint of the remote server to connect to.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public IPEndPoint RemoteEndPoint {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("IPEndPoint of the remote server to connect to.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public: __property IPEndPoint* get_RemoteEndPoint();
public: __property void set_RemoteEndPoint(
   IPEndPoint* value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("IPEndPoint of the remote server to connect to.")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public:
property IPEndPoint^ RemoteEndPoint {
   IPEndPoint^ get();
   void set (    IPEndPoint^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Session Class
Session Members


SocketBase Class

[image]
PowerTCP Telnet for .NET
SocketBase Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : SocketBase Class

Base class for PowerTCP Components.

Object Model

SocketBase Class

Syntax

Visual Basic (Declaration)
Public Class SocketBase
   Inherits ComponentBase
Visual Basic (Usage) Copy Code
Dim instance As SocketBase
C#
public class SocketBase : ComponentBase
Managed Extensions for C++
public __gc class SocketBase : public ComponentBase
C++/CLI
public ref class SocketBase : public ComponentBase

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketBase Members
Dart.Telnet Namespace


SocketBase Class Members

[image]
PowerTCP Telnet for .NET
SocketBase Class Members
See Also Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : SocketBase Class

The following tables list the members exposed by SocketBase.

Public Properties

 | Name | Description
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications.
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals a string and/or object to the UI thread. (Inherited from Dart.Telnet.ComponentBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

SocketBase Class
Dart.Telnet Namespace


SocketBase Class Properties

[image]
PowerTCP Telnet for .NET
SocketBase Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : SocketBase Class

"

For a list of all members of this type, see SocketBase members.

"

Public Properties

 | Name | Description
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications.
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

SocketBase Class
Dart.Telnet Namespace


Socket Property

[image]
PowerTCP Telnet for .NET
Socket Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketBase Class : Socket Property

Gets the socket used by the component for communications.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property Socket As Socket
Visual Basic (Usage) Copy Code
Dim instance As SocketBase
Dim value As Socket

value = instance.Socket
C#
[BrowsableAttribute(false)]
public Socket Socket {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property Socket* get_Socket();
C++/CLI
[BrowsableAttribute(false)]
public:
property Socket^ Socket {
   Socket^ get();
}

Property Value

The Socket used for UDP or TCP communications. Returns null when not in use.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketBase Class
SocketBase Members


SocketOption Class

[image]
PowerTCP Telnet for .NET
SocketOption Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : SocketOption Class

Contains socket options that may be set by TCP and UDP sockets. These options are automatically applied to the connection used.

Object Model

SocketOption Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class SocketOption
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class SocketOption
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class SocketOption
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class SocketOption

Inheritance Hierarchy

System.Object
Dart.Telnet.SocketOption
Dart.Telnet.TcpSocketOption

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Members
Dart.Telnet Namespace


SocketOption Class Members

[image]
PowerTCP Telnet for .NET
SocketOption Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : SocketOption Class

The following tables list the members exposed by SocketOption.

Public Properties

 | Name | Description
public Property | ExclusiveAddressUse | When set to true, forbids multiple socket bindings to the same address. Set this value to true to ensure you have exclusive use of the local endpoint. Socket.ExclusiveAddressUse is set to this value before Socket.Bind is used.
public Property | ReceiveBufferSize | Gets or sets a value that specifies the size of the system receive buffer.
public Property | ReceiveTimeout | Gets or sets a value that specifies the amount of time after which the underlying Socket.Receive call will time out.
public Property | ReuseAddress | When set to true, allows multiple socket bindings to the same address. Set this value to true to allow multiple sockets to bind to the same local address.
public Property | SendBufferSize | Gets or sets a value that specifies the size of the system send buffer.
public Property | SendTimeout | Gets or sets a value that specifies the amount of time after which the underlying Socket Send call will time out.
Top

See Also

Reference

SocketOption Class
Dart.Telnet Namespace


SocketOption Class Properties

[image]
PowerTCP Telnet for .NET
SocketOption Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : SocketOption Class

"

For a list of all members of this type, see SocketOption members.

"

Public Properties

 | Name | Description
public Property | ExclusiveAddressUse | When set to true, forbids multiple socket bindings to the same address. Set this value to true to ensure you have exclusive use of the local endpoint. Socket.ExclusiveAddressUse is set to this value before Socket.Bind is used.
public Property | ReceiveBufferSize | Gets or sets a value that specifies the size of the system receive buffer.
public Property | ReceiveTimeout | Gets or sets a value that specifies the amount of time after which the underlying Socket.Receive call will time out.
public Property | ReuseAddress | When set to true, allows multiple socket bindings to the same address. Set this value to true to allow multiple sockets to bind to the same local address.
public Property | SendBufferSize | Gets or sets a value that specifies the size of the system send buffer.
public Property | SendTimeout | Gets or sets a value that specifies the amount of time after which the underlying Socket Send call will time out.
Top

See Also

Reference

SocketOption Class
Dart.Telnet Namespace


ExclusiveAddressUse Property

[image]
PowerTCP Telnet for .NET
ExclusiveAddressUse Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketOption Class : ExclusiveAddressUse Property

When set to true, forbids multiple socket bindings to the same address. Set this value to true to ensure you have exclusive use of the local endpoint. Socket.ExclusiveAddressUse is set to this value before Socket.Bind is used.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("When set to true, forbids multiple socket bindings to the same address.")>
Public Property ExclusiveAddressUse As Boolean
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
Dim value As Boolean

instance.ExclusiveAddressUse = value

value = instance.ExclusiveAddressUse
C#
[DefaultValueAttribute()]
[DescriptionAttribute("When set to true, forbids multiple socket bindings to the same address.")]
public bool ExclusiveAddressUse {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("When set to true, forbids multiple socket bindings to the same address.")]
public: __property bool get_ExclusiveAddressUse();
public: __property void set_ExclusiveAddressUse(
   bool value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("When set to true, forbids multiple socket bindings to the same address.")]
public:
property bool ExclusiveAddressUse {
   bool get();
   void set (    bool value);
}

Remarks

Set this value to true to ensure you have exclusive use of the local endpoint. Socket.ExclusiveAddressUse is set to this value before Socket.Bind is used.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Class
SocketOption Members


ReceiveBufferSize Property

[image]
PowerTCP Telnet for .NET
ReceiveBufferSize Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketOption Class : ReceiveBufferSize Property

Gets or sets a value that specifies the size of the system receive buffer.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Gets or sets the size of the system receive buffer.")>
<DefaultValueAttribute()>
Public Property ReceiveBufferSize As Integer
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
Dim value As Integer

instance.ReceiveBufferSize = value

value = instance.ReceiveBufferSize
C#
[DescriptionAttribute("Gets or sets the size of the system receive buffer.")]
[DefaultValueAttribute()]
public int ReceiveBufferSize {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Gets or sets the size of the system receive buffer.")]
[DefaultValueAttribute()]
public: __property int get_ReceiveBufferSize();
public: __property void set_ReceiveBufferSize(
   int value
);
C++/CLI
[DescriptionAttribute("Gets or sets the size of the system receive buffer.")]
[DefaultValueAttribute()]
public:
property int ReceiveBufferSize {
   int get();
   void set (    int value);
}

Property Value

An integer with a default value of 32786.

Remarks

Increasing the buffer size may help performance when transferring large amounts of data, or when high bandwidth, high latency connections (such as a satellite broadband provider) are used.

The value cannot be changed on CF devices.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Class
SocketOption Members


ReceiveTimeout Property

[image]
PowerTCP Telnet for .NET
ReceiveTimeout Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketOption Class : ReceiveTimeout Property

Gets or sets a value that specifies the amount of time after which the underlying Socket.Receive call will time out.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")>
Public Overridable Property ReceiveTimeout As Integer
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
Dim value As Integer

instance.ReceiveTimeout = value

value = instance.ReceiveTimeout
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")]
public virtual int ReceiveTimeout {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")]
public: __property virtual int get_ReceiveTimeout();
public: __property virtual void set_ReceiveTimeout(
   int value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")]
public:
virtual property int ReceiveTimeout {
   int get();
   void set (    int value);
}

Property Value

The time-out value in milliseconds. The default value is 0, which indicates an infinite time-out period.

Remarks

A value of 0 or -1 indicates an infinite time-out period.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Class
SocketOption Members


ReuseAddress Property

[image]
PowerTCP Telnet for .NET
ReuseAddress Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketOption Class : ReuseAddress Property

When set to true, allows multiple socket bindings to the same address. Set this value to true to allow multiple sockets to bind to the same local address.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("When set to true, allows multiple socket bindings to the same address.")>
<DefaultValueAttribute()>
Public Property ReuseAddress As Boolean
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
Dim value As Boolean

instance.ReuseAddress = value

value = instance.ReuseAddress
C#
[DescriptionAttribute("When set to true, allows multiple socket bindings to the same address.")]
[DefaultValueAttribute()]
public bool ReuseAddress {get; set;}
Managed Extensions for C++
[DescriptionAttribute("When set to true, allows multiple socket bindings to the same address.")]
[DefaultValueAttribute()]
public: __property bool get_ReuseAddress();
public: __property void set_ReuseAddress(
   bool value
);
C++/CLI
[DescriptionAttribute("When set to true, allows multiple socket bindings to the same address.")]
[DefaultValueAttribute()]
public:
property bool ReuseAddress {
   bool get();
   void set (    bool value);
}

Remarks

Set this value to true to allow multiple sockets to bind to the same local address.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Class
SocketOption Members


SendBufferSize Property

[image]
PowerTCP Telnet for .NET
SendBufferSize Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketOption Class : SendBufferSize Property

Gets or sets a value that specifies the size of the system send buffer.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Gets or sets the size of the system send buffer.")>
Public Property SendBufferSize As Integer
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
Dim value As Integer

instance.SendBufferSize = value

value = instance.SendBufferSize
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the size of the system send buffer.")]
public int SendBufferSize {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the size of the system send buffer.")]
public: __property int get_SendBufferSize();
public: __property void set_SendBufferSize(
   int value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets the size of the system send buffer.")]
public:
property int SendBufferSize {
   int get();
   void set (    int value);
}

Property Value

An integer with a default value of 8192.

Remarks

Increasing the buffer size may help performance when transferring large amounts of data, or when high bandwidth, high latency connections (such as a satellite broadband provider) are used.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Class
SocketOption Members


SendTimeout Property

[image]
PowerTCP Telnet for .NET
SendTimeout Property
See Also Send comments on this topic.
Dart.Telnet Namespace > SocketOption Class : SendTimeout Property

Gets or sets a value that specifies the amount of time after which the underlying Socket Send call will time out.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Gets or sets the number of milli-seconds that a socket Send method will block before throwing a SocketException.")>
<DefaultValueAttribute()>
Public Property SendTimeout As Integer
Visual Basic (Usage) Copy Code
Dim instance As SocketOption
Dim value As Integer

instance.SendTimeout = value

value = instance.SendTimeout
C#
[DescriptionAttribute("Gets or sets the number of milli-seconds that a socket Send method will block before throwing a SocketException.")]
[DefaultValueAttribute()]
public int SendTimeout {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Gets or sets the number of milli-seconds that a socket Send method will block before throwing a SocketException.")]
[DefaultValueAttribute()]
public: __property int get_SendTimeout();
public: __property void set_SendTimeout(
   int value
);
C++/CLI
[DescriptionAttribute("Gets or sets the number of milli-seconds that a socket Send method will block before throwing a SocketException.")]
[DefaultValueAttribute()]
public:
property int SendTimeout {
   int get();
   void set (    int value);
}

Property Value

The time-out value in milliseconds. The default value is 0, which indicates an infinite time-out period.

Remarks

Values between 1 and 499 will be changed to 500, as 500 is the minimum positive value. Values of 0 and -1 indicate an infinite time-out period.

This option has no affect on CF devices (the Write method will not time out).

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

SocketOption Class
SocketOption Members


TcpBase Class

[image]
PowerTCP Telnet for .NET
TcpBase Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : TcpBase Class

Base class for components utilizing protocols built upon the TCP protocol.

Object Model

TcpBase ClassTcpSocketOption Class

Syntax

Visual Basic (Declaration)
Public Class TcpBase
   Inherits SocketBase
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
C#
public class TcpBase : SocketBase
Managed Extensions for C++
public __gc class TcpBase : public SocketBase
C++/CLI
public ref class TcpBase : public SocketBase

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.PtyBase
Dart.Telnet.Rexec
Dart.Telnet.Rsh

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Members
Dart.Telnet Namespace


TcpBase Class Members

[image]
PowerTCP Telnet for .NET
TcpBase Class Members
See Also Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : TcpBase Class

The following tables list the members exposed by TcpBase.

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed.
public Property | ConnectTime | Returns the DateTime the connection was established.
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called.
public Property | RemoteEndPoint | Gets the remote address and port of the connection.
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase.
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called.
public Property | State | Gets the status of the connection.
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection.
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection.
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection.
public Method | Close | Gracefully closes the connection.
public Method | Connect | Connects to a server using parameters found in the session parameter.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream.
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread.
public Method | Read | Overloaded. Receives data from the remote host.
public Method | ReadAsync | Start an asynchronous read on the socket.
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed.
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed.
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown.
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection.
public Method | Write | Overloaded. Sends data to the remote host.
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event.
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event.
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event.
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used.
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written.
public Event | StateChanged | Raised when the value of the State property changes.
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

TcpBase Class
Dart.Telnet Namespace


TcpBase Class Methods

[image]
PowerTCP Telnet for .NET
TcpBase Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : TcpBase Class

"

For a list of all members of this type, see TcpBase members.

"

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection.
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection.
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection.
public Method | Close | Gracefully closes the connection.
public Method | Connect | Connects to a server using parameters found in the session parameter.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream.
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread.
public Method | Read | Overloaded. Receives data from the remote host.
public Method | ReadAsync | Start an asynchronous read on the socket.
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed.
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed.
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown.
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection.
public Method | Write | Overloaded. Sends data to the remote host.
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event.
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event.
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event.
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

TcpBase Class
Dart.Telnet Namespace


Abort Method

[image]
PowerTCP Telnet for .NET
Abort Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Abort Method

Performs a hard close of the connection.

Syntax

Visual Basic (Declaration)
Public Sub Abort()
Visual Basic (Usage) Copy Code
Dim instance As TcpBase

instance.Abort()
C#
public void Abort()
Managed Extensions for C++
public: void Abort();
C++/CLI
public:
void Abort();

Remarks

This method resets the connection and immediately clears the socket state.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


AuthenticateAsClient Method

[image]
PowerTCP Telnet for .NET
AuthenticateAsClient Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : AuthenticateAsClient Method

security
Security parameters used during authentication.
Authenticates the server when establishing a secure connection.

Syntax

Visual Basic (Declaration)
Public Sub AuthenticateAsClient( _
   ByVal security As ClientSecurity _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim security As ClientSecurity

instance.AuthenticateAsClient(security)
C#
public void AuthenticateAsClient(
   ClientSecurity security
)
Managed Extensions for C++
public: void AuthenticateAsClient(
   ClientSecurity* security
)
C++/CLI
public:
void AuthenticateAsClient(
   ClientSecurity^ security
)

Parameters

security
Security parameters used during authentication.

Example

This example demonstrates the AuthenticateAsClient call and the callback that executes when a certificate is received.
C# Copy Code
//using System.Net.Security;
 //using System.Security.Authentication;
 //using System.Security.Cryptography.X509Certificates;

private void doAuthentication(string server, SslProtocols protocol, bool checkRevocation)
{
    //Authenticate server and specify certificate callback functions
    ClientSecurity security = new ClientSecurity();
   security.TargetHost = server;
   security.Protocols = protocol;
   security.CheckCertificateRevocation = checkRevocation;
   security.ValidationCallback = certificateReceived;
   myComponent.AuthenticateAsClient(security);
}

private static bool certificateReceived(object sender, X509Certificate certificate,
    X509Chain chain, SslPolicyErrors sslPolicyErrors)
{
    //Return true if the server certificate is ok
    if (sslPolicyErrors == SslPolicyErrors.None)
        return true;

    bool acceptCertificate = true;
    string msg = "The server could not be validated for the following reason(s):\r\n";

    //The server did not present a certificate
    if ((sslPolicyErrors &
        SslPolicyErrors.RemoteCertificateNotAvailable) == SslPolicyErrors.RemoteCertificateNotAvailable)
    {
        msg = msg + "\r\n    -The server did not present a certificate.\r\n";
        acceptCertificate = false;
    }
    else
    {
        //The certificate does not match the server name
        if ((sslPolicyErrors &
            SslPolicyErrors.RemoteCertificateNameMismatch) == SslPolicyErrors.RemoteCertificateNameMismatch)
        {
            msg = msg + "\r\n    -The certificate name does not match the authenticated name.\r\n";
            acceptCertificate = false;
        }

        //There is some other problem with the certificate
        if ((sslPolicyErrors &
            SslPolicyErrors.RemoteCertificateChainErrors) == SslPolicyErrors.RemoteCertificateChainErrors)
        {
            foreach (X509ChainStatus item in chain.ChainStatus)
            {
                if (item.Status != X509ChainStatusFlags.RevocationStatusUnknown &&
                    item.Status != X509ChainStatusFlags.OfflineRevocation)
                    break;

                if (item.Status != X509ChainStatusFlags.NoError)
                {
                    msg = msg + "\r\n    -" + item.StatusInformation;
                    acceptCertificate = false;
                }
            }
        }
    }

    //If Validation failed, present message box
    if (acceptCertificate == false)
    {
        msg = msg + "\r\nDo you wish to override the security check?";
        if (MessageBox.Show(msg, "Security Alert: Server could not be validated",
            MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation) == DialogResult.Yes)
            acceptCertificate = true;
    }

    return acceptCertificate;
}
Visual Basic Copy Code
'Imports System.Net.Security
 'Imports System.Security.Authentication
 'Imports System.Security.Cryptography.X509Certificates

Private Sub doAuthentication(ByVal server As String, ByVal protocol As SslProtocols, _
    ByVal checkRevocation As Boolean)
       ClientSecurity security = new ClientSecurity()
       security.TargetHost = server
       security.Protocols = protocol
       security.CheckCertificateRevocation = checkRevocation
       security.ValidationCallback = AddressOf certificateReceived
       myComponent.AuthenticateAsClient(security)
End Sub

Private Shared Function certificateReceived(ByVal sender As Object, ByVal certificate As X509Certificate, _
    ByVal chain As X509Chain, ByVal sslPolicyErrors As SslPolicyErrors) As Boolean
    'Return true if the server certificate is ok
    If sslPolicyErrors = SslPolicyErrors.None Then
        Return True
    End If

    Dim acceptCertificate As Boolean = True
    Dim msg As String = "The server could not be validated for the following reason(s):" & Constants.vbCrLf

    'The server did not present a certificate
    If (sslPolicyErrors And _
        SslPolicyErrors.RemoteCertificateNotAvailable) = SslPolicyErrors.RemoteCertificateNotAvailable Then
        msg = msg & Constants.vbCrLf & "    -The server did not present a certificate." & Constants.vbCrLf
        acceptCertificate = False
    Else
        'The certificate does not match the server name
        If ((sslPolicyErrors And _
            SslPolicyErrors.RemoteCertificateNameMismatch) = SslPolicyErrors.RemoteCertificateNameMismatch) Then
            msg = msg & Constants.vbCrLf & _
                "    -The certificate name does not match the authenticated name." & Constants.vbCrLf
                acceptCertificate = False
        End If

        'There is some other problem with the certificate
        If (sslPolicyErrors And _
            SslPolicyErrors.RemoteCertificateChainErrors) = SslPolicyErrors.RemoteCertificateChainErrors Then
            For Each item As X509ChainStatus In chain.ChainStatus
                If item.Status <> X509ChainStatusFlags.RevocationStatusUnknown AndAlso _
                    item.Status <> X509ChainStatusFlags.OfflineRevocation Then
                    Exit For
                End If

                If (item.Status <> X509ChainStatusFlags.NoError) Then
                    msg = msg & Constants.vbCrLf & "    -" & item.StatusInformation
                    acceptCertificate = False
                End If
            Next item
        End If
    End If

    'If Validation failed, present message box
    If acceptCertificate = False Then
        msg = msg & Constants.vbCrLf & "Do you wish to override the security check?"
        If MessageBox.Show(msg, "Security Alert: Server could not be validated", _
            MessageBoxButtons.YesNo, MessageBoxIcon.Exclamation) = System.Windows.Forms.DialogResult.Yes Then
           acceptCertificate = True
        End If
    End If

    Return acceptCertificate
End Function

Remarks

The security.TargetHost must match the server certificate name. If authentication fails, an AuthenticationException will occur.

To accept or reject a certificate "on-the-fly" implement a Security.ValidationCallback function.

To select a client certificate "on-the-fly" implement a ClientSecurity.SelectionCallback function.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


AuthenticateAsServer Method

[image]
PowerTCP Telnet for .NET
AuthenticateAsServer Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : AuthenticateAsServer Method

security
Security parameters used during authentication.
Authenticates a client when establishing a secure connection.

Syntax

Visual Basic (Declaration)
Public Sub AuthenticateAsServer( _
   ByVal security As ServerSecurity _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim security As ServerSecurity

instance.AuthenticateAsServer(security)
C#
public void AuthenticateAsServer(
   ServerSecurity security
)
Managed Extensions for C++
public: void AuthenticateAsServer(
   ServerSecurity* security
)
C++/CLI
public:
void AuthenticateAsServer(
   ServerSecurity^ security
)

Parameters

security
Security parameters used during authentication.

Remarks

To accept or reject a certificate "on-the-fly" implement a Security.ValidationCallback function.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Close() Method

[image]
PowerTCP Telnet for .NET
Close() Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Close() Method

Gracefully closes the connection.

Syntax

Visual Basic (Declaration)
Public Overridable Sub Close()
Visual Basic (Usage) Copy Code
Dim instance As TcpBase

instance.Close()
C#
public virtual void Close()
Managed Extensions for C++
public: virtual void Close();
C++/CLI
public:
virtual void Close();

Remarks

This method enters a normal TIME_WAIT state after the connection is closed.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Connect Method

[image]
PowerTCP Telnet for .NET
Connect Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Connect Method

session
Connects to a server using parameters found in the session parameter.

Syntax

Visual Basic (Declaration)
Public Sub Connect( _
   ByVal session As TcpSession _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim session As TcpSession

instance.Connect(session)
C#
public void Connect(
   TcpSession session
)
Managed Extensions for C++
public: void Connect(
   TcpSession* session
)
C++/CLI
public:
void Connect(
   TcpSession^ session
)

Parameters

session

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


GetStream Method

[image]
PowerTCP Telnet for .NET
GetStream Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : GetStream Method

Provides access to the underlying Stream.

Syntax

Visual Basic (Declaration)
Public Overridable Function GetStream() As Stream
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As Stream

value = instance.GetStream()
C#
public virtual Stream GetStream()
Managed Extensions for C++
public: virtual Stream* GetStream();
C++/CLI
public:
virtual Stream^ GetStream();

Return Value

The underlying Stream object used by the component.

Remarks

Derived classes can override this method to provide a stream that implements an upper-layer protocol.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Marshal Method

[image]
PowerTCP Telnet for .NET
Marshal Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Marshal Method

Marshals data to the UI thread.

Overload List

Overload | Description
Marshal(Data,String,Object) | Marshals data to the UI thread.
Marshal(String,Object) | Marshals a string and/or object to the UI thread. (Inherited from Dart.Telnet.ComponentBase)
Marshal(Exception) | Marshals an exception to the UI thread. (Inherited from Dart.Telnet.ComponentBase)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Marshal(Data,String,Object) Method

[image]
PowerTCP Telnet for .NET
Marshal(Data,String,Object) Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > Marshal Method : Marshal(Data,String,Object) Method

data
TcpBase.Data to be marshaled.
message
Text message to be marshaled.
state
State information to be marshaled.
Marshals data to the UI thread.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Marshal( _
   ByVal data As Data, _
   ByVal message As String, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim data As Data
Dim message As String
Dim state As Object

instance.Marshal(data, message, state)
C#
public void Marshal(
   Data data,
   string message,
   object state
)
Managed Extensions for C++
public: void Marshal(
   Data* data,
   string* message,
   Object* state
)
C++/CLI
public:
void Marshal(
   Data^ data,
   String^ message,
   Object^ state
)

Parameters

data
TcpBase.Data to be marshaled.
message
Text message to be marshaled.
state
State information to be marshaled.

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method is used to marshal data from a worker thread to the UI thread for typical display purposes. It calls the OnData method, which raises the TcpBase.Data event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


OnData Method

[image]
PowerTCP Telnet for .NET
OnData Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : OnData Method

e
A DataEventArgs object that contains the event data.
Raises the TcpBase.Data event.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnData( _
   ByVal e As DataEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim e As DataEventArgs

instance.OnData(e)
C#
protected virtual void OnData(
   DataEventArgs e
)
Managed Extensions for C++
protected: virtual void OnData(
   DataEventArgs* e
)
C++/CLI
protected:
virtual void OnData(
   DataEventArgs^ e
)

Parameters

e
A DataEventArgs object that contains the event data.

Remarks

If the Synchronizing property is set, this method asynchronously invokes the TcpBase.Data event on the UI thread. If the Synchronizing property is null, this method invokes the event on the executing thread.

The OnData method allows derived classes to handle the event without attaching a delegate, but marshaling is not provided. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnData in a derived class, be sure to call the base class OnData method, so that registered delegates receive the event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


OnLog Method

[image]
PowerTCP Telnet for .NET
OnLog Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : OnLog Method

e
A DataEventArgs object containing data to log.
Raises the TcpBase.Log event.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnLog( _
   ByVal e As DataEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim e As DataEventArgs

instance.OnLog(e)
C#
protected virtual void OnLog(
   DataEventArgs e
)
Managed Extensions for C++
protected: virtual void OnLog(
   DataEventArgs* e
)
C++/CLI
protected:
virtual void OnLog(
   DataEventArgs^ e
)

Parameters

e
A DataEventArgs object containing data to log.

Remarks

If the Synchronizing property is set, this method asynchronously invokes the event on the UI thread. If the Synchronizing property is null, this method invokes the event on the executing thread.

The OnLog method allows derived classes to handle the event without attaching a delegate, but marshaling is not provided. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnLog in a derived class, be sure to call the base class OnLog method, so that registered delegates receive the event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


OnStateChanged Method

[image]
PowerTCP Telnet for .NET
OnStateChanged Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : OnStateChanged Method

e
An EventArgs.
Raises the TcpBase.StateChanged event.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnStateChanged( _
   ByVal e As EventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim e As EventArgs

instance.OnStateChanged(e)
C#
protected virtual void OnStateChanged(
   EventArgs e
)
Managed Extensions for C++
protected: virtual void OnStateChanged(
   EventArgs* e
)
C++/CLI
protected:
virtual void OnStateChanged(
   EventArgs^ e
)

Parameters

e
An EventArgs.

Remarks

If the Synchronizing property is set, this method synchronously invokes the event on the UI thread. If the Synchronizing property is null, this method invokes the event on the executing thread.

The OnStateChanged method allows derived classes to handle the event without attaching a delegate, but marshaling is not provided. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnStateChanged in a derived class, be sure to call the base class OnStateChanged method, so that registered delegates receive the event.

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Read Method

[image]
PowerTCP Telnet for .NET
Read Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Read Method

Receives data from the remote host.

Overload List

Overload | Description
Read(Byte[],Int32,Int32) | Receives data from the remote host.
Read(Byte[]) | Receives data from the remote host.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Read(Byte[],Int32,Int32) Method

[image]
PowerTCP Telnet for .NET
Read(Byte[],Int32,Int32) Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > Read Method : Read(Byte[],Int32,Int32) Method

buffer
The byte array used to store the received data.
offset
The position in the buffer to store the data.
count
The maximum number of bytes to receive.
Receives data from the remote host.

Syntax

Visual Basic (Declaration)
Public Overloads Function Read( _
   ByVal buffer() As Byte, _
   ByVal offset As Integer, _
   ByVal count As Integer _
) As Data
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim buffer() As Byte
Dim offset As Integer
Dim count As Integer
Dim value As Data

value = instance.Read(buffer, offset, count)
C#
public Data Read(
   byte[] buffer,
   int offset,
   int count
)
Managed Extensions for C++
public: Data* Read(
   byte[]* buffer,
   int offset,
   int count
)
C++/CLI
public:
Data^ Read(
   array<byte>^ buffer,
   int offset,
   int count
)

Parameters

buffer
The byte array used to store the received data.
offset
The position in the buffer to store the data.
count
The maximum number of bytes to receive.

Return Value

Data object encapsulating the received data (null if the connection is closed).

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method will perform a single socket read, asking for "count" bytes. The socket will block until at least one byte is read, the remote host closes the connection, or an exception is thrown. A SocketException indicating SocketError.Timeout will not result in the socket being closed; other SocketExceptions are fatal and the socket is automatically closed by the class.

The ReceiveTimeout property controls how long this method will block before throwing a SocketError.Timeout exception.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


Read(Byte[]) Method

[image]
PowerTCP Telnet for .NET
Read(Byte[]) Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > Read Method : Read(Byte[]) Method

buffer
The byte array used to store the received data.
Receives data from the remote host.

Syntax

Visual Basic (Declaration)
Public Overloads Function Read( _
   ByVal buffer() As Byte _
) As Data
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim buffer() As Byte
Dim value As Data

value = instance.Read(buffer)
C#
public Data Read(
   byte[] buffer
)
Managed Extensions for C++
public: Data* Read(
   byte[]* buffer
)
C++/CLI
public:
Data^ Read(
   array<byte>^ buffer
)

Parameters

buffer
The byte array used to store the received data.

Return Value

A Data object encapsulating the received data. Returns null if the socket is closed.

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method will read as much data as is available, up to the size of the buffer.

This method will block until data is available or the ReceiveTimeout property has expired.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


ReadAsync Method

[image]
PowerTCP Telnet for .NET
ReadAsync Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : ReadAsync Method

buffer
The byte array used to store the received data.
offset
The position in the buffer to store the data.
count
The number of bytes to receive.
worker
ReadAsyncCompleted delegate to be raised after data is received.
state
Information to pass to the worker delegate function; can be null.
Start an asynchronous read on the socket.

Syntax

Visual Basic (Declaration)
Public Sub ReadAsync( _
   ByVal buffer() As Byte, _
   ByVal offset As Integer, _
   ByVal count As Integer, _
   ByVal worker As ReadAsyncCompleted, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim buffer() As Byte
Dim offset As Integer
Dim count As Integer
Dim worker As ReadAsyncCompleted
Dim state As Object

instance.ReadAsync(buffer, offset, count, worker, state)
C#
public void ReadAsync(
   byte[] buffer,
   int offset,
   int count,
   ReadAsyncCompleted worker,
   object state
)
Managed Extensions for C++
public: void ReadAsync(
   byte[]* buffer,
   int offset,
   int count,
   ReadAsyncCompleted* worker,
   Object* state
)
C++/CLI
public:
void ReadAsync(
   array<byte>^ buffer,
   int offset,
   int count,
   ReadAsyncCompleted^ worker,
   Object^ state
)

Parameters

buffer
The byte array used to store the received data.
offset
The position in the buffer to store the data.
count
The number of bytes to receive.
worker
ReadAsyncCompleted delegate to be raised after data is received.
state
Information to pass to the worker delegate function; can be null.

Remarks

PowerTCP 4.0 is typically used by making blocking calls on a worker (non-UI) thread. This technique greatly simplifies development as it removes the need for saving state information, but requires a dedicated thread for each connection. The use of blocking calls on the streaming interface (GetStream() has greatly improved the implementation of layered protocols (like SSL and Telnet), that makes each protocol almost transparent to the application developer.

If, however, a dedicated worker thread for each socket is not scalable enough, developers can use ReadAsync which uses IO completion threads, and does not dedicate a worker thread to each connection. Instead, IO completion threads raise the delegate provided. This is the best way to create a high-performance server without using dedicated worker threads.

Notes: No WriteAsync method is necessary because only the reading process may cause an indeterminate delay. There is also no need for ConnectAsync as this operation can easily be accomplished on a worker thread without affecting performance.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


ReadToCount Method

[image]
PowerTCP Telnet for .NET
ReadToCount Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : ReadToCount Method

buffer
Destination buffer.
offset
The position in the buffer to store the data.
count
The number of byte to read.
Read until count bytes are read, an exception is thrown, or the connection is closed.

Syntax

Visual Basic (Declaration)
Public Function ReadToCount( _
   ByVal buffer() As Byte, _
   ByVal offset As Integer, _
   ByVal count As Integer _
) As Data
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim buffer() As Byte
Dim offset As Integer
Dim count As Integer
Dim value As Data

value = instance.ReadToCount(buffer, offset, count)
C#
public Data ReadToCount(
   byte[] buffer,
   int offset,
   int count
)
Managed Extensions for C++
public: Data* ReadToCount(
   byte[]* buffer,
   int offset,
   int count
)
C++/CLI
public:
Data^ ReadToCount(
   array<byte>^ buffer,
   int offset,
   int count
)

Parameters

buffer
Destination buffer.
offset
The position in the buffer to store the data.
count
The number of byte to read.

Return Value

Data object indicating count bytes were read.

Exceptions

Exception | Description
Dart.Telnet.DataException | Count bytes could not be read. The property contains any data received before the failure occurred.

Remarks

If a DataException is thrown, the DataException.DataRead property contains any data received prior to the exception.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


ReadToDelimiter Method

[image]
PowerTCP Telnet for .NET
ReadToDelimiter Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : ReadToDelimiter Method

Read until the delimiter is found, an exception is thrown, or the connection is closed.

Overload List

Overload | Description
ReadToDelimiter(String) | Read until the delimiter is found, an exception is thrown, or the connection is closed.
ReadToDelimiter(String[]) | Read until a delimiter is found, an exception is thrown, or the connection is closed.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


ReadToDelimiter(String) Method

[image]
PowerTCP Telnet for .NET
ReadToDelimiter(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > ReadToDelimiter Method : ReadToDelimiter(String) Method

delimiter
A delimiter to search for.
Read until the delimiter is found, an exception is thrown, or the connection is closed.

Syntax

Visual Basic (Declaration)
Public Overloads Function ReadToDelimiter( _
   ByVal delimiter As String _
) As Data
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim delimiter As String
Dim value As Data

value = instance.ReadToDelimiter(delimiter)
C#
public Data ReadToDelimiter(
   string delimiter
)
Managed Extensions for C++
public: Data* ReadToDelimiter(
   string* delimiter
)
C++/CLI
public:
Data^ ReadToDelimiter(
   String^ delimiter
)

Parameters

delimiter
A delimiter to search for.

Return Value

Data object encapsulating the received data.

Exceptions

Exception | Description
Dart.Telnet.DataException | The delimiter was not found. The property contains any data received before the failure occurred.

Remarks

This method blocks until the delimiter is found, an exception is thrown, or the server closes the connection. The value of Data.Delimiter is set to the found delimiter, if any.

If a DataException is thrown, the DataException.DataRead property contains any data received prior to the exception.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


ReadToDelimiter(String[]) Method

[image]
PowerTCP Telnet for .NET
ReadToDelimiter(String[]) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > ReadToDelimiter Method : ReadToDelimiter(String[]) Method

delimiters
An array of delimiters to search for.
Read until a delimiter is found, an exception is thrown, or the connection is closed.

Syntax

Visual Basic (Declaration)
Public Overloads Function ReadToDelimiter( _
   ByVal delimiters() As String _
) As Data
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim delimiters() As String
Dim value As Data

value = instance.ReadToDelimiter(delimiters)
C#
public Data ReadToDelimiter(
   string[] delimiters
)
Managed Extensions for C++
public: Data* ReadToDelimiter(
   string*[]* delimiters
)
C++/CLI
public:
Data^ ReadToDelimiter(
   array<String^>^ delimiters
)

Parameters

delimiters
An array of delimiters to search for.

Return Value

Data object encapsulating the received data.

Exceptions

Exception | Description
Dart.Telnet.DataException | The delimiter was not found. The property contains any data received before the failure occurred.

Remarks

This method blocks until a delimiter is found, an exception is thrown, or the server closes the connection. The value of Data.Delimiter is set to the found delimiter, if any.

If a DataException is thrown, the DataException.DataRead property contains any data received prior to the exception.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


ReadToEnd Method

[image]
PowerTCP Telnet for .NET
ReadToEnd Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : ReadToEnd Method

Read until the connection is closed or an exception is thrown.

Syntax

Visual Basic (Declaration)
Public Function ReadToEnd() As Data
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As Data

value = instance.ReadToEnd()
C#
public Data ReadToEnd()
Managed Extensions for C++
public: Data* ReadToEnd();
C++/CLI
public:
Data^ ReadToEnd();

Return Value

A Data object encapsulating the received data (null if the socket is closed).

Exceptions

Exception | Description
Dart.Telnet.DataException | A failure occurred before the normal end of stream was found. The property contains any data received before the failure occurred.

Remarks

If a DataException is thrown, the DataException.DataRead property contains any data received prior to the exception.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


ShutdownSsl Method

[image]
PowerTCP Telnet for .NET
ShutdownSsl Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : ShutdownSsl Method

Signals the remote host to shutdown the SSL connection.

Syntax

Visual Basic (Declaration)
Public Sub ShutdownSsl()
Visual Basic (Usage) Copy Code
Dim instance As TcpBase

instance.ShutdownSsl()
C#
public void ShutdownSsl()
Managed Extensions for C++
public: void ShutdownSsl();
C++/CLI
public:
void ShutdownSsl();

Remarks

This method provides a means for switching a secure connection to a non-secure connection.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Write Method

[image]
PowerTCP Telnet for .NET
Write Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Write Method

Sends data to the remote host.

Overload List

Overload | Description
Write(Byte[]) | Sends data to the remote host.
Write(String) | Sends data to the remote host.
Write(Byte[],Int32,Int32) | Sends data to the remote host.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Write(Byte[]) Method

[image]
PowerTCP Telnet for .NET
Write(Byte[]) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > Write Method : Write(Byte[]) Method

buffer
Byte array of data to send.
Sends data to the remote host.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Write( _
   ByVal buffer() As Byte _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim buffer() As Byte

instance.Write(buffer)
C#
public void Write(
   byte[] buffer
)
Managed Extensions for C++
public: void Write(
   byte[]* buffer
)
C++/CLI
public:
void Write(
   array<byte>^ buffer
)

Parameters

buffer
Byte array of data to send.

Remarks

This method synchronously sends data to the remote host over an existing connection. It will block until a buffer is available to accept the data or the SocketOption.SendTimeout value has expired.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


Write(String) Method

[image]
PowerTCP Telnet for .NET
Write(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > Write Method : Write(String) Method

data
String of data to send.
Sends data to the remote host.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Write( _
   ByVal data As String _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim data As String

instance.Write(data)
C#
public void Write(
   string data
)
Managed Extensions for C++
public: void Write(
   string* data
)
C++/CLI
public:
void Write(
   String^ data
)

Parameters

data
String of data to send.

Remarks

This method synchronously sends data to the remote host over an existing connection. It will block until a buffer is available to accept the data or the SocketOption.SendTimeout value has expired.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


Write(Byte[],Int32,Int32) Method

[image]
PowerTCP Telnet for .NET
Write(Byte[],Int32,Int32) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class > Write Method : Write(Byte[],Int32,Int32) Method

buffer
Byte array of data to send.
offset
The position in the data buffer at which to begin sending data.
count
The number of bytes to send.
Sends data to the remote host.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Write( _
   ByVal buffer() As Byte, _
   ByVal offset As Integer, _
   ByVal count As Integer _
)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim buffer() As Byte
Dim offset As Integer
Dim count As Integer

instance.Write(buffer, offset, count)
C#
public void Write(
   byte[] buffer,
   int offset,
   int count
)
Managed Extensions for C++
public: void Write(
   byte[]* buffer,
   int offset,
   int count
)
C++/CLI
public:
void Write(
   array<byte>^ buffer,
   int offset,
   int count
)

Parameters

buffer
Byte array of data to send.
offset
The position in the data buffer at which to begin sending data.
count
The number of bytes to send.

Remarks

This method synchronously sends data to the remote host over an existing connection. It will block until a buffer is available to accept the data or the SocketOption.SendTimeout value has expired.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members
Overload List


TcpBase Class Properties

[image]
PowerTCP Telnet for .NET
TcpBase Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : TcpBase Class

"

For a list of all members of this type, see TcpBase members.

"

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed.
public Property | ConnectTime | Returns the DateTime the connection was established.
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called.
public Property | RemoteEndPoint | Gets the remote address and port of the connection.
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase.
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called.
public Property | State | Gets the status of the connection.
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

TcpBase Class
Dart.Telnet Namespace


CloseTime Property

[image]
PowerTCP Telnet for .NET
CloseTime Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : CloseTime Property

Returns the DateTime the connection was closed.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property CloseTime As Date
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As Date

value = instance.CloseTime
C#
[BrowsableAttribute(false)]
public DateTime CloseTime {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property DateTime get_CloseTime();
C++/CLI
[BrowsableAttribute(false)]
public:
property DateTime CloseTime {
   DateTime get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


ConnectTime Property

[image]
PowerTCP Telnet for .NET
ConnectTime Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : ConnectTime Property

Returns the DateTime the connection was established.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property ConnectTime As Date
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As Date

value = instance.ConnectTime
C#
[BrowsableAttribute(false)]
public DateTime ConnectTime {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property DateTime get_ConnectTime();
C++/CLI
[BrowsableAttribute(false)]
public:
property DateTime ConnectTime {
   DateTime get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


NetworkStream Property

[image]
PowerTCP Telnet for .NET
NetworkStream Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : NetworkStream Property

Returns the NetworkStream object created when Connect() is called.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property NetworkStream As NetworkStream
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As NetworkStream

value = instance.NetworkStream
C#
[BrowsableAttribute(false)]
public NetworkStream NetworkStream {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property NetworkStream* get_NetworkStream();
C++/CLI
[BrowsableAttribute(false)]
public:
property NetworkStream^ NetworkStream {
   NetworkStream^ get();
}

Remarks

Returns null when no TCP connection exists.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


RemoteEndPoint Property

[image]
PowerTCP Telnet for .NET
RemoteEndPoint Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : RemoteEndPoint Property

Gets the remote address and port of the connection.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property RemoteEndPoint As IPEndPoint
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As IPEndPoint

value = instance.RemoteEndPoint
C#
[BrowsableAttribute(false)]
public IPEndPoint RemoteEndPoint {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property IPEndPoint* get_RemoteEndPoint();
C++/CLI
[BrowsableAttribute(false)]
public:
property IPEndPoint^ RemoteEndPoint {
   IPEndPoint^ get();
}

Property Value

The Socket.RemoteEndPoint. This value persists after the connection is closed.

Example

This example demonstrates using the component State to update the UI.
C# Copy Code
private void myComponent_StateChanged(object sender, EventArgs e)
{
  //Always raised when connection is established or closed (State property changes)
  switch (myComponent.State)
  {
   case ConnectionState.Connected:
   case ConnectionState.ConnectedAndSecure:
    //Update interface to indicate connection
    textDisplay.ReadOnly = false;
    textDisplay.BackColor = Color.WhiteSmoke;
    Text = (myComponent.State == ConnectionState.Connected)
     ? "[Connected to " + myComponent.RemoteEndPoint.Address.ToString() + ":" +
      myComponent.RemoteEndPoint.Port.ToString() + "]"
     : "[Securely Connected to " + myComponent.RemoteEndPoint.Address.ToString() + ":" +
      myComponent.RemoteEndPoint.Port.ToString() + "]";
    break;

   case ConnectionState.Closed:
    //Update interface to indicate no connection
    textDisplay.ReadOnly = true;
    textDisplay.BackColor = Color.Silver;
    this.Text = "[Not Connected]";
    break;
  }
}
C# Copy Code
Private Sub myComponent_StateChanged(ByVal sender As Object, ByVal e As EventArgs)
  'Always raised when connection is established or closed (State property changes)
  Select Case myComponent.State
      Case ConnectionState.Connected, ConnectionState.ConnectedAndSecure
          'Update interface to indicate connection
          textDisplay.ReadOnly = False
          textDisplay.BackColor = Color.WhiteSmoke
          Text = If((myComponent.State = ConnectionState.Connected), _
         "[Connected to " & myComponent.RemoteEndPoint.Address.ToString() & ":" & _
         myComponent.RemoteEndPoint.Port.ToString() & "]", "[Securely Connected to " & _
         myComponent.RemoteEndPoint.Address.ToString() & ":" & _
         myComponent.RemoteEndPoint.Port.ToString() & "]")

      Case ConnectionState.Closed
          'Update interface to indicate no connection
          textDisplay.ReadOnly = True
          textDisplay.BackColor = Color.Silver
          Me.Text = "[Not Connected]"
  End Select
End Sub

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


SocketOption Property

[image]
PowerTCP Telnet for .NET
SocketOption Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : SocketOption Property

Gets and sets the socket options for classes derived from TcpBase.

Syntax

Visual Basic (Declaration)
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<DescriptionAttribute("Exerts fine control over socket operation.")>
Public Property SocketOption As TcpSocketOption
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As TcpSocketOption

instance.SocketOption = value

value = instance.SocketOption
C#
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Exerts fine control over socket operation.")]
public TcpSocketOption SocketOption {get; set;}
Managed Extensions for C++
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Exerts fine control over socket operation.")]
public: __property TcpSocketOption* get_SocketOption();
public: __property void set_SocketOption(
   TcpSocketOption* value
);
C++/CLI
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Exerts fine control over socket operation.")]
public:
property TcpSocketOption^ SocketOption {
   TcpSocketOption^ get();
   void set (    TcpSocketOption^ value);
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


SslStream Property

[image]
PowerTCP Telnet for .NET
SslStream Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : SslStream Property

Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property SslStream As SslStream
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As SslStream

value = instance.SslStream
C#
[BrowsableAttribute(false)]
public SslStream SslStream {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property SslStream* get_SslStream();
C++/CLI
[BrowsableAttribute(false)]
public:
property SslStream^ SslStream {
   SslStream^ get();
}

Remarks

Returns null when no secure connection exists.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


State Property

[image]
PowerTCP Telnet for .NET
State Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : State Property

Gets the status of the connection.

Syntax

Visual Basic (Declaration)
<BrowsableAttribute(False)>
Public ReadOnly Property State As ConnectionState
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim value As ConnectionState

value = instance.State
C#
[BrowsableAttribute(false)]
public ConnectionState State {get;}
Managed Extensions for C++
[BrowsableAttribute(false)]
public: __property ConnectionState get_State();
C++/CLI
[BrowsableAttribute(false)]
public:
property ConnectionState State {
   ConnectionState get();
}

Example

This example demonstrates using the component State to update the UI.
C# Copy Code
private void myComponent_StateChanged(object sender, EventArgs e)
{
  //Always raised when connection is established or closed (State property changes)
  switch (myComponent.State)
  {
   case ConnectionState.Connected:
   case ConnectionState.ConnectedAndSecure:
    //Update interface to indicate connection
    textDisplay.ReadOnly = false;
    textDisplay.BackColor = Color.WhiteSmoke;
    Text = (myComponent.State == ConnectionState.Connected)
     ? "[Connected to " + myComponent.RemoteEndPoint.Address.ToString() + ":" +
      myComponent.RemoteEndPoint.Port.ToString() + "]"
     : "[Securely Connected to " + myComponent.RemoteEndPoint.Address.ToString() + ":" +
      myComponent.RemoteEndPoint.Port.ToString() + "]";
    break;

   case ConnectionState.Closed:
    //Update interface to indicate no connection
    textDisplay.ReadOnly = true;
    textDisplay.BackColor = Color.Silver;
    this.Text = "[Not Connected]";
    break;
  }
}
C# Copy Code
Private Sub myComponent_StateChanged(ByVal sender As Object, ByVal e As EventArgs)
  'Always raised when connection is established or closed (State property changes)
  Select Case myComponent.State
      Case ConnectionState.Connected, ConnectionState.ConnectedAndSecure
          'Update interface to indicate connection
          textDisplay.ReadOnly = False
          textDisplay.BackColor = Color.WhiteSmoke
          Text = If((myComponent.State = ConnectionState.Connected), _
         "[Connected to " & myComponent.RemoteEndPoint.Address.ToString() & ":" & _
         myComponent.RemoteEndPoint.Port.ToString() & "]", "[Securely Connected to " & _
         myComponent.RemoteEndPoint.Address.ToString() & ":" & _
         myComponent.RemoteEndPoint.Port.ToString() & "]")

      Case ConnectionState.Closed
          'Update interface to indicate no connection
          textDisplay.ReadOnly = True
          textDisplay.BackColor = Color.Silver
          Me.Text = "[Not Connected]"
  End Select
End Sub

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


TcpBase Class Events

[image]
PowerTCP Telnet for .NET
TcpBase Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : TcpBase Class

"

For a list of all members of this type, see TcpBase members.

"

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used.
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written.
public Event | StateChanged | Raised when the value of the State property changes.
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

TcpBase Class
Dart.Telnet Namespace


Data Event

[image]
PowerTCP Telnet for .NET
Data Event
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Data Event

Raised when TcpBase.Marshal is used.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Raised when Marshal(Data, string, object) is used.")>
<CategoryAttribute("Marshaled Data")>
Public Event Data As EventHandler(Of DataEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim handler As EventHandler(Of DataEventArgs)

AddHandler instance.Data, handler
C#
[DescriptionAttribute("Raised when Marshal(Data, string, object) is used.")]
[CategoryAttribute("Marshaled Data")]
public event EventHandler<DataEventArgs> Data
Managed Extensions for C++
[DescriptionAttribute("Raised when Marshal(Data, string, object) is used.")]
[CategoryAttribute("Marshaled Data")]
public: __event EventHandler<DataEventArgs*>* Data
C++/CLI
[DescriptionAttribute("Raised when Marshal(Data, string, object) is used.")]
[CategoryAttribute("Marshaled Data")]
public:
event EventHandler<DataEventArgs^>^ Data

Event Data

The event handler receives an argument of type DataEventArgs containing data related to this event. The following DataEventArgs properties provide information specific to this event.

Property | Description
Data | Gets data provided by Data and Log events.
Message (Inherited from Dart.Telnet.UserStateEventArgs) | Gets the user message provided by the Message event.
UserState (Inherited from Dart.Telnet.UserStateEventArgs) | Gets the user state provided by the UserState event.

Remarks

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Log Event

[image]
PowerTCP Telnet for .NET
Log Event
See Also Example Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Log Event

Raised when data is read or written.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Raised when data is read or written.")>
<CategoryAttribute("Marshaled Data")>
Public Event Log As EventHandler(Of DataEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim handler As EventHandler(Of DataEventArgs)

AddHandler instance.Log, handler
C#
[DescriptionAttribute("Raised when data is read or written.")]
[CategoryAttribute("Marshaled Data")]
public event EventHandler<DataEventArgs> Log
Managed Extensions for C++
[DescriptionAttribute("Raised when data is read or written.")]
[CategoryAttribute("Marshaled Data")]
public: __event EventHandler<DataEventArgs*>* Log
C++/CLI
[DescriptionAttribute("Raised when data is read or written.")]
[CategoryAttribute("Marshaled Data")]
public:
event EventHandler<DataEventArgs^>^ Log

Event Data

The event handler receives an argument of type DataEventArgs containing data related to this event. The following DataEventArgs properties provide information specific to this event.

Property | Description
Data | Gets data provided by Data and Log events.
Message (Inherited from Dart.Telnet.UserStateEventArgs) | Gets the user message provided by the Message event.
UserState (Inherited from Dart.Telnet.UserStateEventArgs) | Gets the user state provided by the UserState event.

Example

This example demonstrates logging sent and received data to a file on disk.
C# Copy Code
private FileStream logFile =
        new FileStream(Application.StartupPath + "\\logFile.txt", FileMode.Append, FileAccess.Write);

private void myComponent_Log(object sender, DataEventArgs e)
{
    string prompt = (e.Data.Direction == DataDirection.In) ? "Recv: " : "Sent: ";
    logFile.Write(System.Text.Encoding.Default.GetBytes(prompt), 0, prompt.Length);
    logFile.Write(e.Data.Buffer, e.Data.Offset, e.Data.Count);
    logFile.Write(System.Text.Encoding.Default.GetBytes("\r\n"), 0, 2);
}
Visual Basic Copy Code
Private logFile As FileStream = New FileStream(Application.StartupPath & "\logFile.txt", FileMode.Append, FileAccess.Write)

Private Sub myComponent_Log(ByVal sender As Object, ByVal e As DataEventArgs)
  Dim prompt As String
  prompt = If((e.Data.Direction = DataDirection.In), "Recv: ", "Sent: ")
  logFile.Write(System.Text.Encoding.Default.GetBytes(prompt), 0, prompt.Length)
  logFile.Write(e.Data.Buffer, e.Data.Offset, e.Data.Count)
  logFile.Write(System.Text.Encoding.Default.GetBytes(Constants.vbCrLf), 0, 2)
End Sub

Remarks

The handler must be added before connecting. See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


StateChanged Event

[image]
PowerTCP Telnet for .NET
StateChanged Event
See Also Example Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : StateChanged Event

Raised when the value of the State property changes.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Raised when the value of the State property changes.")>
<CategoryAttribute("Property Changed")>
Public Event StateChanged As EventHandler
Visual Basic (Usage) Copy Code
Dim instance As TcpBase
Dim handler As EventHandler

AddHandler instance.StateChanged, handler
C#
[DescriptionAttribute("Raised when the value of the State property changes.")]
[CategoryAttribute("Property Changed")]
public event EventHandler StateChanged
Managed Extensions for C++
[DescriptionAttribute("Raised when the value of the State property changes.")]
[CategoryAttribute("Property Changed")]
public: __event EventHandler* StateChanged
C++/CLI
[DescriptionAttribute("Raised when the value of the State property changes.")]
[CategoryAttribute("Property Changed")]
public:
event EventHandler^ StateChanged

Example

This example demonstrates using the component State to update the UI.
C# Copy Code
private void myComponent_StateChanged(object sender, EventArgs e)
{
  //Always raised when connection is established or closed (State property changes)
  switch (myComponent.State)
  {
   case ConnectionState.Connected:
   case ConnectionState.ConnectedAndSecure:
    //Update interface to indicate connection
    textDisplay.ReadOnly = false;
    textDisplay.BackColor = Color.WhiteSmoke;
    Text = (myComponent.State == ConnectionState.Connected)
     ? "[Connected to " + myComponent.RemoteEndPoint.Address.ToString() + ":" +
      myComponent.RemoteEndPoint.Port.ToString() + "]"
     : "[Securely Connected to " + myComponent.RemoteEndPoint.Address.ToString() + ":" +
      myComponent.RemoteEndPoint.Port.ToString() + "]";
    break;

   case ConnectionState.Closed:
    //Update interface to indicate no connection
    textDisplay.ReadOnly = true;
    textDisplay.BackColor = Color.Silver;
    this.Text = "[Not Connected]";
    break;
  }
}
C# Copy Code
Private Sub myComponent_StateChanged(ByVal sender As Object, ByVal e As EventArgs)
  'Always raised when connection is established or closed (State property changes)
  Select Case myComponent.State
      Case ConnectionState.Connected, ConnectionState.ConnectedAndSecure
          'Update interface to indicate connection
          textDisplay.ReadOnly = False
          textDisplay.BackColor = Color.WhiteSmoke
          Text = If((myComponent.State = ConnectionState.Connected), _
         "[Connected to " & myComponent.RemoteEndPoint.Address.ToString() & ":" & _
         myComponent.RemoteEndPoint.Port.ToString() & "]", "[Securely Connected to " & _
         myComponent.RemoteEndPoint.Address.ToString() & ":" & _
         myComponent.RemoteEndPoint.Port.ToString() & "]")

      Case ConnectionState.Closed
          'Update interface to indicate no connection
          textDisplay.ReadOnly = True
          textDisplay.BackColor = Color.Silver
          Me.Text = "[Not Connected]"
  End Select
End Sub

Remarks

See the SynchronizingObject property for information on updating UI controls in your event handler.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


TcpSession Class

[image]
PowerTCP Telnet for .NET
TcpSession Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : TcpSession Class

Provides a holder for parameters used to establish a TCP session.

Object Model

TcpSession ClassIPEndPoint ClassProxy ClassIPEndPoint Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class TcpSession
   Inherits Session
Visual Basic (Usage) Copy Code
Dim instance As TcpSession
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class TcpSession : Session
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class TcpSession : public Session
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class TcpSession : public Session

Inheritance Hierarchy

System.Object
Dart.Telnet.Session
Dart.Telnet.TcpSession

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSession Members
Dart.Telnet Namespace


TcpSession Class Members

[image]
PowerTCP Telnet for .NET
TcpSession Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : TcpSession Class

The following tables list the members exposed by TcpSession.

Public Constructors

 | Name | Description
public Constructor | TcpSession Constructor | Overloaded.
Top

Public Properties

 | Name | Description
public Property | LocalEndPoint | EndPoint to bind to locally. (Inherited from Dart.Telnet.Session)
public Property | Proxy | Defines the optional server proxy configuration.
public Property | RemoteEndPoint | EndPoint of the remote host to connect to. (Inherited from Dart.Telnet.Session)
Top

See Also

Reference

TcpSession Class
Dart.Telnet Namespace


TcpSession Constructor

[image]
PowerTCP Telnet for .NET
TcpSession Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSession Class : TcpSession Constructor

Overload List

Overload | Description
TcpSession Constructor() | Default constructor for TcpSession.
TcpSession Constructor(IPEndPoint) | Constructor for TcpSession with a Remote IPEndPoint parameter.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSession Class
TcpSession Members


TcpSession Constructor()

[image]
PowerTCP Telnet for .NET
TcpSession Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSession Class > TcpSession Constructor : TcpSession Constructor()

Default constructor for TcpSession.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New TcpSession()
C#
public TcpSession()
Managed Extensions for C++
public: TcpSession();
C++/CLI
public:
TcpSession();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSession Class
TcpSession Members
Overload List


TcpSession Constructor(IPEndPoint)

[image]
PowerTCP Telnet for .NET
TcpSession Constructor(IPEndPoint)
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSession Class > TcpSession Constructor : TcpSession Constructor(IPEndPoint)

remoteEP
The remote IPEndPoint to connect to.
Constructor for TcpSession with a Remote IPEndPoint parameter.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal remoteEP As IPEndPoint _
)
Visual Basic (Usage) Copy Code
Dim remoteEP As IPEndPoint

Dim instance As New TcpSession(remoteEP)
C#
public TcpSession(
   IPEndPoint remoteEP
)
Managed Extensions for C++
public: TcpSession(
   IPEndPoint* remoteEP
)
C++/CLI
public:
TcpSession(
   IPEndPoint^ remoteEP
)

Parameters

remoteEP
The remote IPEndPoint to connect to.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSession Class
TcpSession Members
Overload List


TcpSession Class Properties

[image]
PowerTCP Telnet for .NET
TcpSession Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : TcpSession Class

"

For a list of all members of this type, see TcpSession members.

"

Public Properties

 | Name | Description
public Property | LocalEndPoint | EndPoint to bind to locally. (Inherited from Dart.Telnet.Session)
public Property | Proxy | Defines the optional server proxy configuration.
public Property | RemoteEndPoint | EndPoint of the remote host to connect to. (Inherited from Dart.Telnet.Session)
Top

See Also

Reference

TcpSession Class
Dart.Telnet Namespace


Proxy Property

[image]
PowerTCP Telnet for .NET
Proxy Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSession Class : Proxy Property

Defines the optional server proxy configuration.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Design")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<DescriptionAttribute("Defines the optional server proxy configuration.")>
Public Property Proxy As Proxy
Visual Basic (Usage) Copy Code
Dim instance As TcpSession
Dim value As Proxy

instance.Proxy = value

value = instance.Proxy
C#
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Defines the optional server proxy configuration.")]
public Proxy Proxy {get; set;}
Managed Extensions for C++
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Defines the optional server proxy configuration.")]
public: __property Proxy* get_Proxy();
public: __property void set_Proxy(
   Proxy* value
);
C++/CLI
[CategoryAttribute("Design")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Defines the optional server proxy configuration.")]
public:
property Proxy^ Proxy {
   Proxy^ get();
   void set (    Proxy^ value);
}

Remarks

Use this property to define the server proxy configuration.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSession Class
TcpSession Members


TcpSocketOption Class

[image]
PowerTCP Telnet for .NET
TcpSocketOption Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : TcpSocketOption Class

Contains socket options that may be set by TCP sockets.

Object Model

TcpSocketOption Class

Syntax

Visual Basic (Declaration)
<TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")>
<SerializableAttribute()>
Public Class TcpSocketOption
   Inherits SocketOption
Visual Basic (Usage) Copy Code
Dim instance As TcpSocketOption
C#
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public class TcpSocketOption : SocketOption
Managed Extensions for C++
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public __gc class TcpSocketOption : public SocketOption
C++/CLI
[TypeConverterAttribute("System.ComponentModel.ExpandableObjectConverter, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
[SerializableAttribute()]
public ref class TcpSocketOption : public SocketOption

Inheritance Hierarchy

System.Object
Dart.Telnet.SocketOption
Dart.Telnet.TcpSocketOption

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSocketOption Members
Dart.Telnet Namespace


TcpSocketOption Class Members

[image]
PowerTCP Telnet for .NET
TcpSocketOption Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : TcpSocketOption Class

The following tables list the members exposed by TcpSocketOption.

Public Properties

 | Name | Description
public Property | ExclusiveAddressUse | When set to true, forbids multiple socket bindings to the same address. Set this value to true to ensure you have exclusive use of the local endpoint. Socket.ExclusiveAddressUse is set to this value before Socket.Bind is used. (Inherited from Dart.Telnet.SocketOption)
public Property | KeepAliveInterval | The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.
public Property | KeepAliveTime | The connection idle time in milliseconds before TCP will begin sending keepalives.
public Property | NoDelay | Gets or sets a value that disables the use of Nagle's algorithm so that data is sent immediately.
public Property | OutOfBandInline | Gets or sets a value that indicates whether out-of-band (urgent) data is read as normal in-line data.
public Property | ReceiveBufferSize | Gets or sets a value that specifies the size of the system receive buffer. (Inherited from Dart.Telnet.SocketOption)
public Property | ReceiveTimeout | Overridden. Gets or sets a value that specifies the amount of time after which the underlying TCP Socket.Receive call will time out.
public Property | ReuseAddress | When set to true, allows multiple socket bindings to the same address. Set this value to true to allow multiple sockets to bind to the same local address. (Inherited from Dart.Telnet.SocketOption)
public Property | SendBufferSize | Gets or sets a value that specifies the size of the system send buffer. (Inherited from Dart.Telnet.SocketOption)
public Property | SendTimeout | Gets or sets a value that specifies the amount of time after which the underlying Socket Send call will time out. (Inherited from Dart.Telnet.SocketOption)
Top

See Also

Reference

TcpSocketOption Class
Dart.Telnet Namespace


TcpSocketOption Class Properties

[image]
PowerTCP Telnet for .NET
TcpSocketOption Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : TcpSocketOption Class

"

For a list of all members of this type, see TcpSocketOption members.

"

Public Properties

 | Name | Description
public Property | ExclusiveAddressUse | When set to true, forbids multiple socket bindings to the same address. Set this value to true to ensure you have exclusive use of the local endpoint. Socket.ExclusiveAddressUse is set to this value before Socket.Bind is used. (Inherited from Dart.Telnet.SocketOption)
public Property | KeepAliveInterval | The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.
public Property | KeepAliveTime | The connection idle time in milliseconds before TCP will begin sending keepalives.
public Property | NoDelay | Gets or sets a value that disables the use of Nagle's algorithm so that data is sent immediately.
public Property | OutOfBandInline | Gets or sets a value that indicates whether out-of-band (urgent) data is read as normal in-line data.
public Property | ReceiveBufferSize | Gets or sets a value that specifies the size of the system receive buffer. (Inherited from Dart.Telnet.SocketOption)
public Property | ReceiveTimeout | Overridden. Gets or sets a value that specifies the amount of time after which the underlying TCP Socket.Receive call will time out.
public Property | ReuseAddress | When set to true, allows multiple socket bindings to the same address. Set this value to true to allow multiple sockets to bind to the same local address. (Inherited from Dart.Telnet.SocketOption)
public Property | SendBufferSize | Gets or sets a value that specifies the size of the system send buffer. (Inherited from Dart.Telnet.SocketOption)
public Property | SendTimeout | Gets or sets a value that specifies the amount of time after which the underlying Socket Send call will time out. (Inherited from Dart.Telnet.SocketOption)
Top

See Also

Reference

TcpSocketOption Class
Dart.Telnet Namespace


KeepAliveInterval Property

[image]
PowerTCP Telnet for .NET
KeepAliveInterval Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSocketOption Class : KeepAliveInterval Property

The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.")>
<DefaultValueAttribute()>
Public Property KeepAliveInterval As Integer
Visual Basic (Usage) Copy Code
Dim instance As TcpSocketOption
Dim value As Integer

instance.KeepAliveInterval = value

value = instance.KeepAliveInterval
C#
[DescriptionAttribute("The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.")]
[DefaultValueAttribute()]
public int KeepAliveInterval {get; set;}
Managed Extensions for C++
[DescriptionAttribute("The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.")]
[DefaultValueAttribute()]
public: __property int get_KeepAliveInterval();
public: __property void set_KeepAliveInterval(
   int value
);
C++/CLI
[DescriptionAttribute("The time in milliseconds between retransmission of keepalives once the KeepAliveTime has expired.")]
[DefaultValueAttribute()]
public:
property int KeepAliveInterval {
   int get();
   void set (    int value);
}

Remarks

Once KeepAliveTime has expired, keepalives are sent every KeepAliveInterval milliseconds unitl a response is received, up to a maximum of established by MaxDataRetries before the connection is terminated. The default is 1000 (1 sec).

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSocketOption Class
TcpSocketOption Members


KeepAliveTime Property

[image]
PowerTCP Telnet for .NET
KeepAliveTime Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSocketOption Class : KeepAliveTime Property

The connection idle time in milliseconds before TCP will begin sending keepalives.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("The connection idle time in milliseconds before TCP will begin sending keepalives.")>
Public Property KeepAliveTime As Integer
Visual Basic (Usage) Copy Code
Dim instance As TcpSocketOption
Dim value As Integer

instance.KeepAliveTime = value

value = instance.KeepAliveTime
C#
[DefaultValueAttribute()]
[DescriptionAttribute("The connection idle time in milliseconds before TCP will begin sending keepalives.")]
public int KeepAliveTime {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("The connection idle time in milliseconds before TCP will begin sending keepalives.")]
public: __property int get_KeepAliveTime();
public: __property void set_KeepAliveTime(
   int value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("The connection idle time in milliseconds before TCP will begin sending keepalives.")]
public:
property int KeepAliveTime {
   int get();
   void set (    int value);
}

Remarks

Set to 0 to disable keepalives. Defaults to 7,200,000 (2 hours).

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSocketOption Class
TcpSocketOption Members


NoDelay Property

[image]
PowerTCP Telnet for .NET
NoDelay Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSocketOption Class : NoDelay Property

Gets or sets a value that disables the use of Nagle's algorithm so that data is sent immediately.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Gets or sets a value the disables the use of Nagle's algorithm so that data is sent immediately.")>
Public Property NoDelay As Boolean
Visual Basic (Usage) Copy Code
Dim instance As TcpSocketOption
Dim value As Boolean

instance.NoDelay = value

value = instance.NoDelay
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets a value the disables the use of Nagle's algorithm so that data is sent immediately.")]
public bool NoDelay {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets a value the disables the use of Nagle's algorithm so that data is sent immediately.")]
public: __property bool get_NoDelay();
public: __property void set_NoDelay(
   bool value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets a value the disables the use of Nagle's algorithm so that data is sent immediately.")]
public:
property bool NoDelay {
   bool get();
   void set (    bool value);
}

Property Value

False if Nagle's algorithm is used; otherwise true. The default value is false.

Remarks

When small pieces of data (such as single bytes) are send many times consecutively, inefficient packets can be sent with one byte of useful data and 40 bytes of header information. Nagle's algorithm specifies that this type of data should be automatically concatenated and sent in a single packet. When true, Nagle's algorithm is defeated and data is immediately sent in a dedicated packet. When false, Nagle's algorithm is used and consecutive Socket Send calls might send data in a single (more efficient) packet.

Setting this property to true may result in a speed optimization (because packets are sent immediately, without having to wait to see if Send is called again). Setting this property to false results in data being transmitted more efficiently.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSocketOption Class
TcpSocketOption Members


OutOfBandInline Property

[image]
PowerTCP Telnet for .NET
OutOfBandInline Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSocketOption Class : OutOfBandInline Property

Gets or sets a value that indicates whether out-of-band (urgent) data is read as normal in-line data.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Gets or sets a value that indicates whether out-of-band (urgent) data will be read as normal in-line data.")>
Public Property OutOfBandInline As Boolean
Visual Basic (Usage) Copy Code
Dim instance As TcpSocketOption
Dim value As Boolean

instance.OutOfBandInline = value

value = instance.OutOfBandInline
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets a value that indicates whether out-of-band (urgent) data will be read as normal in-line data.")]
public bool OutOfBandInline {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets a value that indicates whether out-of-band (urgent) data will be read as normal in-line data.")]
public: __property bool get_OutOfBandInline();
public: __property void set_OutOfBandInline(
   bool value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Gets or sets a value that indicates whether out-of-band (urgent) data will be read as normal in-line data.")]
public:
property bool OutOfBandInline {
   bool get();
   void set (    bool value);
}

Property Value

True if urgent data is to be read as normal in-line data, otherwise false. The default value is false.

Remarks

When the "urgent" socket flag is set, the packet contains data that should be acted upon before "non-urgent" data. Setting this property to true will cause this urgent data to be read in-line. To minimize interoperability problems, developers are advised not to use out-of-band data unless it is required to interoperate with an existing service.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSocketOption Class
TcpSocketOption Members


ReceiveTimeout Property

[image]
PowerTCP Telnet for .NET
ReceiveTimeout Property
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpSocketOption Class : ReceiveTimeout Property

Gets or sets a value that specifies the amount of time after which the underlying TCP Socket.Receive call will time out.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")>
<DefaultValueAttribute()>
Public Overrides Property ReceiveTimeout As Integer
Visual Basic (Usage) Copy Code
Dim instance As TcpSocketOption
Dim value As Integer

instance.ReceiveTimeout = value

value = instance.ReceiveTimeout
C#
[DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")]
[DefaultValueAttribute()]
public override int ReceiveTimeout {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")]
[DefaultValueAttribute()]
public: __property int get_ReceiveTimeout() override;
public: __property void set_ReceiveTimeout(
   int value
) override;
C++/CLI
[DescriptionAttribute("Gets or sets the number of milliseconds that a socket Receive method will block before throwing a SocketException.")]
[DefaultValueAttribute()]
public:
property int ReceiveTimeout {
   int get() override;
   void set (    int value) override;
}

Property Value

The time-out value in milliseconds. The default value is 0, which indicates an infinite time-out period.

Remarks

A value of 0 or -1 indicates an infinite time-out period.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpSocketOption Class
TcpSocketOption Members


Telnet Class

[image]
PowerTCP Telnet for .NET
Telnet Class
Members Example See Also Send comments on this topic.
Dart.Telnet Namespace : Telnet Class

The Telnet component enables use of the Telnet protocol within any .NET application.

Object Model

Telnet ClassOptionCollection ClassOption ClassOptionCollection ClassOption ClassTcpSocketOption Class

Syntax

Visual Basic (Declaration)
<ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")>
<LicenseProviderAttribute(System.ComponentModel.LicenseProvider)>
<DescriptionAttribute("The Telnet Component performs comprehensive option negotiation.")>
Public Class Telnet
   Inherits PtyBase
Visual Basic (Usage) Copy Code
Dim instance As Telnet
C#
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[DescriptionAttribute("The Telnet Component performs comprehensive option negotiation.")]
public class Telnet : PtyBase
Managed Extensions for C++
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[DescriptionAttribute("The Telnet Component performs comprehensive option negotiation.")]
public __gc class Telnet : public PtyBase
C++/CLI
[ToolboxItemAttribute(ToolboxItemType=System.Drawing.Design.ToolboxItem, ToolboxItemTypeName="System.Drawing.Design.ToolboxItem, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[LicenseProviderAttribute(System.ComponentModel.LicenseProvider)]
[DescriptionAttribute("The Telnet Component performs comprehensive option negotiation.")]
public ref class Telnet : public PtyBase

Example

The following example demonstrates execution of an automated session using the Telnet component.
C# Copy Code
private Telnet telnet1;

private void button1_Click(object sender, EventArgs e)
{
    //Dynamically create an instance of the Telnet component
    //The component can also be dragged onto a form, so that the
    //properties and event handlers can be managed in the designer
    telnet1 = new Telnet();

    //Events should fire on the UI thread
    telnet1.SynchronizingObject = this;

    //Add event handlers
    telnet1.Data += new EventHandler<DataEventArgs>(telnet1_Data);
    telnet1.Error += new EventHandler<ErrorEventArgs>(telnet1_Error);
    telnet1.StateChanged += new EventHandler(telnet1_StateChanged);

    //Start the process on a worker thread
    telnet1.Start(automateSession, null);
}

private void automateSession(object notUsed)
{
    //This function executes on a worker thread, providing multi-threaded, asynchronous operation
    try
    {
        //Connect to the server
        telnet1.Connect("myServer");

        //Login and marshal data to the UI thread
        telnet1.Marshal(telnet1.Login(new Credentials("myUsername", "myPassword", "$")), "", null);

        //Send a list command
        telnet1.Write("ls -la\r");

        //Wait for prompt, marshal data to the UI thread
        telnet1.Marshal(telnet1.ReadToDelimiter("$"), "", null);

        //Send an exit command; server will close the connection
        telnet1.Write("exit\r");

        //Read any remaining data before the shutdown
        telnet1.Marshal(telnet1.ReadToEnd(), "", null);
    }
    catch (Exception ex)
    {
        //Report errors to the UI thread
        telnet1.Marshal(ex);
    }
}

void telnet1_Data(object sender, DataEventArgs e)
{
    //Add data received to the textbox
    textBox1.AppendText(e.Data.ToString());
}

void telnet1_Error(object sender, ErrorEventArgs e)
{
    //Add error messages to the textbox
    textBox1.AppendText(e.GetException().Message);
}

void telnet1_StateChanged(object sender, EventArgs e)
{
    //Change appearance of textbox when connected
    textBox1.BackColor = (telnet1.State == ConnectionState.Closed)
    ? SystemColors.ControlDark
    : SystemColors.ControlLight;
}
Visual Basic Copy Code
Private telnet1 As Telnet

Private Sub button1_Click(ByVal sender As Object, ByVal e As EventArgs)
    'Dynamically create an instance of the Telnet component
    'The component can also be dragged onto a form, so that the
    'properties and event handlers can be managed in the designer
    telnet1 = New Telnet()

    'Events should fire on the UI thread
    telnet1.SynchronizingObject = Me

    'Add event handlers
    AddHandler telnet1.Data, AddressOf telnet1_Data
    AddHandler telnet1.Error, AddressOf telnet1_Error
    AddHandler telnet1.StateChanged, AddressOf telnet1_StateChanged

    'Start the process on a worker thread
    telnet1.Start(AddressOf automateSession, Nothing)
End Sub

Private Sub automateSession(ByVal notUsed As Object)
    'This function executes on a worker thread, providing multi-threaded, asynchronous operation
    Try
        'Connect to the server
        telnet1.Connect("myServer")

        'Login and marshal data to the UI thread
        telnet1.Marshal(telnet1.Login(New Credentials("myUsername", "myPassword", "$")), "", Nothing)

        'Send a list command
        telnet1.Write("ls -la" & Constants.vbCr)

        'Wait for prompt, marshal data to the UI thread
        telnet1.Marshal(telnet1.ReadToDelimiter("$"), "", Nothing)

        'Send an exit command; server will close the connection
        telnet1.Write("exit" & Constants.vbCr)

        'Read any remaining data before the shutdown
        telnet1.Marshal(telnet1.ReadToEnd(), "", Nothing)
    Catch ex As Exception
        'Report errors to the UI thread
        telnet1.Marshal(ex)
    End Try
End Sub

Private Sub telnet1_Data(ByVal sender As Object, ByVal e As DataEventArgs)
    'Add data received to the textbox
    textBox1.AppendText(e.Data.ToString())
End Sub

Private Sub telnet1_Error(ByVal sender As Object, ByVal e As ErrorEventArgs)
    'Add error messages to the textbox
    textBox1.AppendText(e.GetException().Message)
End Sub

Private Sub telnet1_StateChanged(ByVal sender As Object, ByVal e As EventArgs)
    'Change appearance of textbox when connected
    textBox1.BackColor = If((telnet1.State = ConnectionState.Closed), SystemColors.ControlDark, SystemColors.ControlLight)
End Sub

Remarks

The Telnet component establishes and manages Telnet-level streams of data. Methods for establishing connections, handling option negotiation, and sending and receiving data greatly simplify Telnet communications for the user, while still providing many options for advanced customization. Secure SSL connections, asynchronous use, and advanced option negotiation are all fully supported.

The Telnet component can optionally be bound to a display for easy user-interactive development.

Using the Telnet Component

The Telnet component's clean interface provides clear, straight-forward use. All methods calls are blocking calls, making programming an intuitive step-by-step process. Functions can be passed to the Start method, to execute on independent threads, without blocking the user interface. Marshaling data from these threads is very convenient using the Marshal method. See the Asynchronous Operation page for more information on this topic.

  • Connecting: To connect to a host, use the Connect method. Once connected, establish a secure connection using AuthenticateAsClient.

  • Default option negotiation: The Telnet component uses a default option negotiation sequence which occurs automatically after login. To add or remove options to negotiate, modify the ClientOptions and ServerOptions collections appropriately. The ClientOptionChanged and ServerOptionChanged events fire when the state of an option changes.

  • Customized option negotiation: Manual option negotiation is also possible. Use the SendOption call to send option commands, and and the CommandReceived event to examine server responses.

  • Sending Data: Once a connection is established, send data using the Write method, which includes overloads for sending data as byte arrays or as strings.

  • Receiving Data: Receive data using the Read method. This method returns a Data object containing data read off the data stream. Data in this object can easily be converted to a string using its ToString method. The Read method includes overloads for reading until a specified delimiter is found. A set of delimiters can also be specified for situations in which one of several responses may be received. Marshal data to the Data event by calling the Marshal method.

  • Sending commands: Use the SendMethod method to send any non-option control command to the host.

Binding the Telnet Component to a Display

Set the Pty (pseudo terminal) property to bind the Telnet component to a display control derived from TextBoxBase (such as a standard TextBox), and call Connect to establish a connection to the specified host. Once connected, keystrokes will be sent automatically, and data received will appear in the text area.

Inheritance Hierarchy

System.Object
System.MarshalByRefObject
System.ComponentModel.Component
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.PtyBase
Dart.Telnet.Telnet

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Members
Dart.Telnet Namespace


Telnet Class Members

[image]
PowerTCP Telnet for .NET
Telnet Class Members
See Also Fields Properties Methods Events Send comments on this topic.
Dart.Telnet Namespace : Telnet Class

The following tables list the members exposed by Telnet.

Public Constructors

 | Name | Description
public Constructor | Telnet Constructor | Overloaded.
Top

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 23 for Rsh operations.
Top

Public Properties

 | Name | Description
public Property | Binary | Gets or sets the state of the Telnet Transmit-Binary option.
public Property | ClientOptions | Gets a collection of desired client options.
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | CRLF | Set to true if the Pty property is used and a CR should be converted to a CRLF for sending. (Inherited from Dart.Telnet.PtyBase)
public Property | Echo | Gets or sets the state of the Telnet Echo option.
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | LocalEcho | Set to true if the Pty property is used and keystrokes should be displayed in the textbox. (Inherited from Dart.Telnet.PtyBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | Pty | Gets or sets a display control to use for automatic pseudo terminal support. (Inherited from Dart.Telnet.PtyBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | ServerOptions | Gets a collection of desired server options.
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
public Property | TerminalType | Gets or sets the terminal type used for the Telnet TerminalType option.
public Property | WindowSize | Gets or sets the window-size used for the Telnet WindowSize option.
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to a Telnet server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Overridden. Provides access to the underlying Stream.
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Login | Logs into a telnet server using properties found in the settings parameter.
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Refresh | Negotiates Telnet options that have been added to the ClientOptions and ServerOptions collections.
public Method | SendCommand | Sends a Telnet (non-option) command to the server.
public Method | SendOption | Sends a Telnet option to the server.
public Method | SendSubOption | Sends a suboption request or response to the server.
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnClientOptionChanged | Raises the ClientOptionChanged event on the executing thread.
protected Method | OnCommandReceived | Raises the CommandReceived event on the executing thread.
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnServerOptionChanged | Raises the ServerOptionChanged event on the executing thread.
protected Method | OnStateChanged | Overridden. Raises the StateChanged event.
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

Public Events

 | Name | Description
public Event | ClientOptionChanged | Raised when a client Telnet option has changed state (WILL or WONT confirmed).
public Event | CommandReceived | Raised when a Telnet command is received from the server.
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | ServerOptionChanged | Raised when a server Telnet option has changed state (DO or DONT confirmed).
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Telnet Class
Dart.Telnet Namespace


Telnet Constructor

[image]
PowerTCP Telnet for .NET
Telnet Constructor
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Telnet Constructor

Overload List

Overload | Description
Telnet Constructor() | Initializes a new instance of the Telnet component.
Telnet Constructor(IContainer) | Initializes a new instance of the Telnet component.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Telnet Constructor()

[image]
PowerTCP Telnet for .NET
Telnet Constructor()
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class > Telnet Constructor : Telnet Constructor()

Initializes a new instance of the Telnet component.

Syntax

Visual Basic (Declaration)
Public Function New()
Visual Basic (Usage) Copy Code
Dim instance As New Telnet()
C#
public Telnet()
Managed Extensions for C++
public: Telnet();
C++/CLI
public:
Telnet();

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members
Overload List


Telnet Constructor(IContainer)

[image]
PowerTCP Telnet for .NET
Telnet Constructor(IContainer)
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class > Telnet Constructor : Telnet Constructor(IContainer)

container
Initializes a new instance of the Telnet component.

Syntax

Visual Basic (Declaration)
Public Function New( _
   ByVal container As IContainer _
)
Visual Basic (Usage) Copy Code
Dim container As IContainer

Dim instance As New Telnet(container)
C#
public Telnet(
   IContainer container
)
Managed Extensions for C++
public: Telnet(
   IContainer* container
)
C++/CLI
public:
Telnet(
   IContainer^ container
)

Parameters

container

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members
Overload List


Telnet Class Methods

[image]
PowerTCP Telnet for .NET
Telnet Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : Telnet Class

"

For a list of all members of this type, see Telnet members.

"

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Overloaded. Connects to a Telnet server.
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Overridden. Provides access to the underlying Stream.
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Login | Logs into a telnet server using properties found in the settings parameter.
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Refresh | Negotiates Telnet options that have been added to the ClientOptions and ServerOptions collections.
public Method | SendCommand | Sends a Telnet (non-option) command to the server.
public Method | SendOption | Sends a Telnet option to the server.
public Method | SendSubOption | Sends a suboption request or response to the server.
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Start | Starts a worker thread on which the specified delegate function executes.
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnClientOptionChanged | Raises the ClientOptionChanged event on the executing thread.
protected Method | OnCommandReceived | Raises the CommandReceived event on the executing thread.
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnServerOptionChanged | Raises the ServerOptionChanged event on the executing thread.
protected Method | OnStateChanged | Overridden. Raises the StateChanged event.
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Telnet Class
Dart.Telnet Namespace


Connect Method

[image]
PowerTCP Telnet for .NET
Connect Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Connect Method

Connects to a Telnet server.

Overload List

Overload | Description
Connect(String) | Connects to a Telnet server.
Connect | Connects to a server using parameters found in the session parameter. (Inherited from Dart.Telnet.TcpBase)

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Connect(String) Method

[image]
PowerTCP Telnet for .NET
Connect(String) Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class > Connect Method : Connect(String) Method

hostNameOrAddress
The remote host name or address to connect to.
Connects to a Telnet server.

Syntax

Visual Basic (Declaration)
Public Overloads Sub Connect( _
   ByVal hostNameOrAddress As String _
)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim hostNameOrAddress As String

instance.Connect(hostNameOrAddress)
C#
public void Connect(
   string hostNameOrAddress
)
Managed Extensions for C++
public: void Connect(
   string* hostNameOrAddress
)
C++/CLI
public:
void Connect(
   String^ hostNameOrAddress
)

Parameters

hostNameOrAddress
The remote host name or address to connect to.

Remarks

This method attempts to connect to the remote host at the default port of 23.

Use alternative Connect overloads to connect to a port other than 513.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members
Overload List


GetStream Method

[image]
PowerTCP Telnet for .NET
GetStream Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : GetStream Method

Provides access to the underlying Stream.

Syntax

Visual Basic (Declaration)
Public Overrides Function GetStream() As Stream
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As Stream

value = instance.GetStream()
C#
public override Stream GetStream()
Managed Extensions for C++
public: Stream* GetStream(); override
C++/CLI
public:
Stream^ GetStream(); override

Return Value

The underlying Stream object used by the component.

Remarks

If a connection is not established, operations on the stream will result in null reference exceptions.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Login(Credentials) Method

[image]
PowerTCP Telnet for .NET
Login(Credentials) Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Login(Credentials) Method

credentials
Credentials including username, password and command prompt.
Logs into a telnet server using properties found in the settings parameter.

Syntax

Visual Basic (Declaration)
Public Function Login( _
   ByVal credentials As Credentials _
) As Data
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim credentials As Credentials
Dim value As Data

value = instance.Login(credentials)
C#
public Data Login(
   Credentials credentials
)
Managed Extensions for C++
public: Data* Login(
   Credentials* credentials
)
C++/CLI
public:
Data^ Login(
   Credentials^ credentials
)

Parameters

credentials
Credentials including username, password and command prompt.

Return Value

A Data object containing the data received during the login.

Example

The following example demonstrates execution of an automated session using the Telnet component.
C# Copy Code
private Telnet telnet1;

private void button1_Click(object sender, EventArgs e)
{
    //Dynamically create an instance of the Telnet component
    //The component can also be dragged onto a form, so that the
    //properties and event handlers can be managed in the designer
    telnet1 = new Telnet();

    //Events should fire on the UI thread
    telnet1.SynchronizingObject = this;

    //Add event handlers
    telnet1.Data += new EventHandler<DataEventArgs>(telnet1_Data);
    telnet1.Error += new EventHandler<ErrorEventArgs>(telnet1_Error);
    telnet1.StateChanged += new EventHandler(telnet1_StateChanged);

    //Start the process on a worker thread
    telnet1.Start(automateSession, null);
}

private void automateSession(object notUsed)
{
    //This function executes on a worker thread, providing multi-threaded, asynchronous operation
    try
    {
        //Connect to the server
        telnet1.Connect("myServer");

        //Login and marshal data to the UI thread
        telnet1.Marshal(telnet1.Login(new Credentials("myUsername", "myPassword", "$")), "", null);

        //Send a list command
        telnet1.Write("ls -la\r");

        //Wait for prompt, marshal data to the UI thread
        telnet1.Marshal(telnet1.ReadToDelimiter("$"), "", null);

        //Send an exit command; server will close the connection
        telnet1.Write("exit\r");

        //Read any remaining data before the shutdown
        telnet1.Marshal(telnet1.ReadToEnd(), "", null);
    }
    catch (Exception ex)
    {
        //Report errors to the UI thread
        telnet1.Marshal(ex);
    }
}

void telnet1_Data(object sender, DataEventArgs e)
{
    //Add data received to the textbox
    textBox1.AppendText(e.Data.ToString());
}

void telnet1_Error(object sender, ErrorEventArgs e)
{
    //Add error messages to the textbox
    textBox1.AppendText(e.GetException().Message);
}

void telnet1_StateChanged(object sender, EventArgs e)
{
    //Change appearance of textbox when connected
    textBox1.BackColor = (telnet1.State == ConnectionState.Closed)
    ? SystemColors.ControlDark
    : SystemColors.ControlLight;
}
Visual Basic Copy Code
Private telnet1 As Telnet

Private Sub button1_Click(ByVal sender As Object, ByVal e As EventArgs)
    'Dynamically create an instance of the Telnet component
    'The component can also be dragged onto a form, so that the
    'properties and event handlers can be managed in the designer
    telnet1 = New Telnet()

    'Events should fire on the UI thread
    telnet1.SynchronizingObject = Me

    'Add event handlers
    AddHandler telnet1.Data, AddressOf telnet1_Data
    AddHandler telnet1.Error, AddressOf telnet1_Error
    AddHandler telnet1.StateChanged, AddressOf telnet1_StateChanged

    'Start the process on a worker thread
    telnet1.Start(AddressOf automateSession, Nothing)
End Sub

Private Sub automateSession(ByVal notUsed As Object)
    'This function executes on a worker thread, providing multi-threaded, asynchronous operation
    Try
        'Connect to the server
        telnet1.Connect("myServer")

        'Login and marshal data to the UI thread
        telnet1.Marshal(telnet1.Login(New Credentials("myUsername", "myPassword", "$")), "", Nothing)

        'Send a list command
        telnet1.Write("ls -la" & Constants.vbCr)

        'Wait for prompt, marshal data to the UI thread
        telnet1.Marshal(telnet1.ReadToDelimiter("$"), "", Nothing)

        'Send an exit command; server will close the connection
        telnet1.Write("exit" & Constants.vbCr)

        'Read any remaining data before the shutdown
        telnet1.Marshal(telnet1.ReadToEnd(), "", Nothing)
    Catch ex As Exception
        'Report errors to the UI thread
        telnet1.Marshal(ex)
    End Try
End Sub

Private Sub telnet1_Data(ByVal sender As Object, ByVal e As DataEventArgs)
    'Add data received to the textbox
    textBox1.AppendText(e.Data.ToString())
End Sub

Private Sub telnet1_Error(ByVal sender As Object, ByVal e As ErrorEventArgs)
    'Add error messages to the textbox
    textBox1.AppendText(e.GetException().Message)
End Sub

Private Sub telnet1_StateChanged(ByVal sender As Object, ByVal e As EventArgs)
    'Change appearance of textbox when connected
    textBox1.BackColor = If((telnet1.State = ConnectionState.Closed), SystemColors.ControlDark, SystemColors.ControlLight)
End Sub

Remarks

For an established connection, this function will send Credentials.Username and Credentials.Password after receiving login prompts. It will then read the data sent by the remote host up to the Credentials.CommandPrompt.

The return value contains a record of all data received during this process. A return value with no data typically indicates that the server closed the connection.

This method blocks until the login process completes successfully, the server does not respond with an expected prompt within six seconds, or the server closes the connection.

A DataException will be thrown if the password or login prompt is not provided by the server within the timeout period specified, or if any other exception occurs. Examine the DataException.DataRead property for data read up to the exception, and the InnerException for the exception wrapped by DataException. An exception will NOT be thrown if a timeout occurs waiting for the command prompt. Instead, the method will return and the Data.Delimiter will be null. Note that a successful login with an incorrectly specified command prompt will result in the method blocking for the timeout period before returning with the actual prompt, manifesting in a perceived delay. An incorrect password could result in a similar delay.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


OnClientOptionChanged Method

[image]
PowerTCP Telnet for .NET
OnClientOptionChanged Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : OnClientOptionChanged Method

e
An OptionEventArgs.
Raises the ClientOptionChanged event on the executing thread.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnClientOptionChanged( _
   ByVal e As OptionEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim e As OptionEventArgs

instance.OnClientOptionChanged(e)
C#
protected virtual void OnClientOptionChanged(
   OptionEventArgs e
)
Managed Extensions for C++
protected: virtual void OnClientOptionChanged(
   OptionEventArgs* e
)
C++/CLI
protected:
virtual void OnClientOptionChanged(
   OptionEventArgs^ e
)

Parameters

e
An OptionEventArgs.

Remarks

The OnClientOptionChanged method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnClientOptionChanged in a derived class, be sure to call the base class OnClientOptionChanged method, so that registered delegates receive the event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


OnCommandReceived Method

[image]
PowerTCP Telnet for .NET
OnCommandReceived Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : OnCommandReceived Method

e
A CommandEventArgs.
Raises the CommandReceived event on the executing thread.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnCommandReceived( _
   ByVal e As CommandEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim e As CommandEventArgs

instance.OnCommandReceived(e)
C#
protected virtual void OnCommandReceived(
   CommandEventArgs e
)
Managed Extensions for C++
protected: virtual void OnCommandReceived(
   CommandEventArgs* e
)
C++/CLI
protected:
virtual void OnCommandReceived(
   CommandEventArgs^ e
)

Parameters

e
A CommandEventArgs.

Remarks

The OnCommandReceived method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnCommandReceived in a derived class, be sure to call the base class OnCommandReceived method, so that registered delegates receive the event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


OnServerOptionChanged Method

[image]
PowerTCP Telnet for .NET
OnServerOptionChanged Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : OnServerOptionChanged Method

e
An OptionEventArgs.
Raises the ServerOptionChanged event on the executing thread.

Syntax

Visual Basic (Declaration)
Protected Overridable Sub OnServerOptionChanged( _
   ByVal e As OptionEventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim e As OptionEventArgs

instance.OnServerOptionChanged(e)
C#
protected virtual void OnServerOptionChanged(
   OptionEventArgs e
)
Managed Extensions for C++
protected: virtual void OnServerOptionChanged(
   OptionEventArgs* e
)
C++/CLI
protected:
virtual void OnServerOptionChanged(
   OptionEventArgs^ e
)

Parameters

e
An OptionEventArgs.

Remarks

The OnServerOptionChanged method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnServerOptionChanged in a derived class, be sure to call the base class OnServerOptionChanged method, so that registered delegates receive the event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


OnStateChanged Method

[image]
PowerTCP Telnet for .NET
OnStateChanged Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : OnStateChanged Method

e
An EventArgs.
Raises the StateChanged event.

Syntax

Visual Basic (Declaration)
Protected Overrides Sub OnStateChanged( _
   ByVal e As EventArgs _
)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim e As EventArgs

instance.OnStateChanged(e)
C#
protected override void OnStateChanged(
   EventArgs e
)
Managed Extensions for C++
protected: void OnStateChanged(
   EventArgs* e
) override
C++/CLI
protected:
void OnStateChanged(
   EventArgs^ e
) override

Parameters

e
An EventArgs.

Remarks

Raising an event invokes the event handler through a delegate. The Synchronizing property must be set.

The OnStateChanged method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class.

Note to Inheritors: When overriding OnStateChanged in a derived class, be sure to call the base class OnStateChanged method, so that registered delegates receive the event.

See the SynchronizingObject property for important information on updating UI controls from within derived classes and events.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Refresh Method

[image]
PowerTCP Telnet for .NET
Refresh Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Refresh Method

Negotiates Telnet options that have been added to the ClientOptions and ServerOptions collections.

Syntax

Visual Basic (Declaration)
Public Sub Refresh()
Visual Basic (Usage) Copy Code
Dim instance As Telnet

instance.Refresh()
C#
public void Refresh()
Managed Extensions for C++
public: void Refresh();
C++/CLI
public:
void Refresh();

Remarks

This method performs option negotiation for any non-negotiated option. Requests for all options set to OptionState.RequestOff or OptionState.RequestOn are sent to the server. The Telnet component automatically executes this method when performing option negotiation.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


SendCommand Method

[image]
PowerTCP Telnet for .NET
SendCommand Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : SendCommand Method

command
The command to send.
Sends a Telnet (non-option) command to the server.

Syntax

Visual Basic (Declaration)
Public Function SendCommand( _
   ByVal command As Command _
) As Byte()
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim command As Command
Dim value() As Byte

value = instance.SendCommand(command)
C#
public byte[] SendCommand(
   Command command
)
Managed Extensions for C++
public: byte[]* SendCommand(
   Command command
)
C++/CLI
public:
array<byte>^ SendCommand(
   Command command
)

Parameters

command
The command to send.

Return Value

A byte array containing the bytes sent.

Remarks

Telnet control functions are commands which represent functions that are implemented on most servers. For example, most servers provide an "IP" function that permits the user to interrupt or abort a process.

See Command for a list of control functions.

For manual option negotiation, use SendOption.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


SendOption Method

[image]
PowerTCP Telnet for .NET
SendOption Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : SendOption Method

command
The command to send with the option.
code
The option to negotiate.
Sends a Telnet option to the server.

Syntax

Visual Basic (Declaration)
Public Function SendOption( _
   ByVal command As Command, _
   ByVal code As OptionCode _
) As Byte()
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim command As Command
Dim code As OptionCode
Dim value() As Byte

value = instance.SendOption(command, code)
C#
public byte[] SendOption(
   Command command,
   OptionCode code
)
Managed Extensions for C++
public: byte[]* SendOption(
   Command command,
   OptionCode code
)
C++/CLI
public:
array<byte>^ SendOption(
   Command command,
   OptionCode code
)

Parameters

command
The command to send with the option.
code
The option to negotiate.

Remarks

Option negotiation typically occurs automatically by the Telnet component. Using this method will disable the automatic negotiation. Once disabled, all options must be negotiated manually.

To manually negotiate options:

  1. Clear both ClientOptions and ServerOptions.
  2. Use SendOption from within the CommandReceived event in response to commands from the server.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


SendSubOption Method

[image]
PowerTCP Telnet for .NET
SendSubOption Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : SendSubOption Method

code
The option pertaining to the suboption.
subOption
The suboption to negotiate.
Sends a suboption request or response to the server.

Syntax

Visual Basic (Declaration)
Public Function SendSubOption( _
   ByVal code As OptionCode, _
   ByVal subOption() As Byte _
) As Byte()
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim code As OptionCode
Dim subOption() As Byte
Dim value() As Byte

value = instance.SendSubOption(code, subOption)
C#
public byte[] SendSubOption(
   OptionCode code,
   byte[] subOption
)
Managed Extensions for C++
public: byte[]* SendSubOption(
   OptionCode code,
   byte[]* subOption
)
C++/CLI
public:
array<byte>^ SendSubOption(
   OptionCode code,
   array<byte>^ subOption
)

Parameters

code
The option pertaining to the suboption.
subOption
The suboption to negotiate.

Return Value

The bytes sent to the remote host.

Remarks

Option megotiation typically occurs automatically by the Telnet component. Suboption data is sent by the Telnet component when a new option (containing the appropriate suboption data) is added to either ClientOptions or ServerOptions. Only use this method if automatic option negotiation is not used.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Start Method

[image]
PowerTCP Telnet for .NET
Start Method
See Also Example Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Start Method

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.
Starts a worker thread on which the specified delegate function executes.

Syntax

Visual Basic (Declaration)
Public Sub Start( _
   ByVal worker As WaitCallback, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim worker As WaitCallback
Dim state As Object

instance.Start(worker, state)
C#
public void Start(
   WaitCallback worker,
   object state
)
Managed Extensions for C++
public: void Start(
   WaitCallback* worker,
   Object* state
)
C++/CLI
public:
void Start(
   WaitCallback^ worker,
   Object^ state
)

Parameters

worker
WaitCallback delegate specifying the function to execute.
state
Information to pass to the worker delegate function; can be null.

Example

This example demonstrates execution of a looping Read on a worker thread, and marshaling the data to the UI.
C# Copy Code
private void button1_Click(object sender, EventArgs e)
{
    //Receive data on a separate thread
    myComponent.Start(receiveData, null);
}

private void receiveData(object notUsed)
{
    //Receive data when it is sent by the remote host
    byte[] buffer = new byte[1024];
    while (myComponent.State != ConnectionState.Closed)
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", null);
}

private void myComponent_Data(object sender, DataEventArgs e)
{
    //Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString());
}
Visual Basic Copy Code
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    'Receive data on a separate thread
    myComponent.Start(AddressOf receiveData, Nothing)
End Sub

Private Sub receiveData(ByVal notUsed As Object)
    'Receive data when it is sent by the remote host
    Dim buffer() As Byte = New Byte(1023) {}
    Do While myComponent.State <> ConnectionState.Closed
        myComponent.Marshal(myComponent.Read(buffer, 0, 1024), "", Nothing)
    Loop
End Sub

Private Sub myComponent_Data(ByVal sender As Object, ByVal e As DataEventArgs) Handles myComponent.Data
    'Whenever data is received, display it
    textDisplay.AppendText(e.Data.ToString())
End Sub

Remarks

This method provides an easy means for executing blocking functions on a worker thread. Applications with a UI thread should use this technique to execute processes (like Connect and Read) that can block the UI thread.

The state parameter can be null for cases in which no state information needs to be passed to the worker delegate function.

Unhandled exceptions occurring on the worker thread will be caught and reported in the Error event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Telnet Class Properties

[image]
PowerTCP Telnet for .NET
Telnet Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Telnet Class

"

For a list of all members of this type, see Telnet members.

"

Public Properties

 | Name | Description
public Property | Binary | Gets or sets the state of the Telnet Transmit-Binary option.
public Property | ClientOptions | Gets a collection of desired client options.
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | CRLF | Set to true if the Pty property is used and a CR should be converted to a CRLF for sending. (Inherited from Dart.Telnet.PtyBase)
public Property | Echo | Gets or sets the state of the Telnet Echo option.
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | LocalEcho | Set to true if the Pty property is used and keystrokes should be displayed in the textbox. (Inherited from Dart.Telnet.PtyBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | Pty | Gets or sets a display control to use for automatic pseudo terminal support. (Inherited from Dart.Telnet.PtyBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | ServerOptions | Gets a collection of desired server options.
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
public Property | TerminalType | Gets or sets the terminal type used for the Telnet TerminalType option.
public Property | WindowSize | Gets or sets the window-size used for the Telnet WindowSize option.
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

Telnet Class
Dart.Telnet Namespace


Binary Property

[image]
PowerTCP Telnet for .NET
Binary Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Binary Property

Gets or sets the state of the Telnet Transmit-Binary option.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<DescriptionAttribute("Indicates that the 'Transmit-Binary' option should be negotiated for all data sent/received.")>
<CategoryAttribute("Telnet Options")>
Public Property Binary As OptionState
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As OptionState

instance.Binary = value

value = instance.Binary
C#
[DefaultValueAttribute()]
[DescriptionAttribute("Indicates that the 'Transmit-Binary' option should be negotiated for all data sent/received.")]
[CategoryAttribute("Telnet Options")]
public OptionState Binary {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[DescriptionAttribute("Indicates that the 'Transmit-Binary' option should be negotiated for all data sent/received.")]
[CategoryAttribute("Telnet Options")]
public: __property OptionState get_Binary();
public: __property void set_Binary(
   OptionState value
);
C++/CLI
[DefaultValueAttribute()]
[DescriptionAttribute("Indicates that the 'Transmit-Binary' option should be negotiated for all data sent/received.")]
[CategoryAttribute("Telnet Options")]
public:
property OptionState Binary {
   OptionState get();
   void set (    OptionState value);
}

Property Value

An OptionState with a default value of Off.

Remarks

Setting this property adds an option to both ClientOptions and ServerOptions.

To determine negotiation success, check both ClientOptions and ServerOptions. If State is OptionState.On for both, negotiation was successful.

The TRANSMIT-BINARY option is used to send data without padding naked CR characters with NULL. When enabled, naked CR bytes (A CR not followed by a LF) are transmitted without adding a NULL after the CR, and are received without stripping the NULL from CR/NULL sequences found.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


ClientOptions Property

[image]
PowerTCP Telnet for .NET
ClientOptions Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : ClientOptions Property

Gets a collection of desired client options.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Telnet Options")>
<DescriptionAttribute("Returns a collection of desired client options ('WILL' commands are sent).")>
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
Public ReadOnly Property ClientOptions As OptionCollection
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As OptionCollection

value = instance.ClientOptions
C#
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Returns a collection of desired client options ('WILL' commands are sent).")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public OptionCollection ClientOptions {get;}
Managed Extensions for C++
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Returns a collection of desired client options ('WILL' commands are sent).")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public: __property OptionCollection* get_ClientOptions();
C++/CLI
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Returns a collection of desired client options ('WILL' commands are sent).")]
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
public:
property OptionCollection^ ClientOptions {
   OptionCollection^ get();
}

Example

The following example demonstrates how to set options for automatic option negotiation.
C# Copy Code
if (telnet1.RemoteEndPoint.Port == 23)
{
    //Standard telnet port, add standard telnet options
    telnet1.ClientOptions.Add(new Option(OptionCode.SuppressGoAheads, null, OptionState.RequestOn));
    telnet1.ClientOptions.Add(new Option(OptionCode.WindowSize,
        new Byte[] { ((Byte)(0)), ((Byte)(80)), ((Byte)(0)), ((Byte)(24)) }, OptionState.RequestOn));
    telnet1.ClientOptions.Add(new Option(OptionCode.TerminalType,
        new System.Byte[] { ((Byte)(0)), ((Byte)(116)), ((Byte)(116)), ((Byte)(121)) }, OptionState.RequestOn));

    telnet1.ServerOptions.Add(new Option(OptionCode.SuppressGoAheads, null, OptionState.RequestOn));
    telnet1.ServerOptions.Add(new Option(OptionCode.Echo, null, OptionState.RequestOn));
    telnet1.ServerOptions.Add(new Option(OptionCode.OutputPageSize, null, OptionState.RequestOn));
}
else
{
    //Non-standard telnet port, do not send telnet options
    telnet1.ClientOptions.Clear();
    telnet1.ServerOptions.Clear();
}
Visual Basic Copy Code
If telnet1.RemoteEndPoint.Port = 23 Then
    'Standard telnet port, add standart telnet options
    telnet1.ClientOptions.Add(New [Option](OptionCode.SuppressGoAheads, Nothing, OptionState.RequestOn))
    telnet1.ClientOptions.Add(New [Option](OptionCode.WindowSize, _
        New System.Byte() { (CByte(0)), (CByte(80)), (CByte(0)), (CByte(24)) }, OptionState.RequestOn))
    telnet1.ClientOptions.Add(New [Option](OptionCode.TerminalType, _
        New System.Byte() { (CByte(0)), (CByte(116)), (CByte(116)), (CByte(121)) }, OptionState.RequestOn))

    telnet1.ServerOptions.Add(New [Option](OptionCode.SuppressGoAheads, Nothing, OptionState.RequestOn))
    telnet1.ServerOptions.Add(New [Option](OptionCode.Echo, Nothing, OptionState.RequestOn))
    telnet1.ServerOptions.Add(New [Option](OptionCode.OutputPageSize, Nothing, OptionState.RequestOn))
Else
    'Non-standard telnet port, do not send telnet options
    telnet1.ClientOptions.Clear()
    telnet1.ServerOptions.Clear()
End If

Remarks

The client will send a WILL command for the options within the collection.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Echo Property

[image]
PowerTCP Telnet for .NET
Echo Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Echo Property

Gets or sets the state of the Telnet Echo option.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Indicates that the remote host should echo all Telnet data it receives back to the client.")>
<DefaultValueAttribute()>
<CategoryAttribute("Telnet Options")>
Public Property Echo As OptionState
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As OptionState

instance.Echo = value

value = instance.Echo
C#
[DescriptionAttribute("Indicates that the remote host should echo all Telnet data it receives back to the client.")]
[DefaultValueAttribute()]
[CategoryAttribute("Telnet Options")]
public OptionState Echo {get; set;}
Managed Extensions for C++
[DescriptionAttribute("Indicates that the remote host should echo all Telnet data it receives back to the client.")]
[DefaultValueAttribute()]
[CategoryAttribute("Telnet Options")]
public: __property OptionState get_Echo();
public: __property void set_Echo(
   OptionState value
);
C++/CLI
[DescriptionAttribute("Indicates that the remote host should echo all Telnet data it receives back to the client.")]
[DefaultValueAttribute()]
[CategoryAttribute("Telnet Options")]
public:
property OptionState Echo {
   OptionState get();
   void set (    OptionState value);
}

Property Value

An OptionState with a default value of RequestOn.

Remarks

When on, the remote host will echo all Telnet data it receives back to the client.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


ServerOptions Property

[image]
PowerTCP Telnet for .NET
ServerOptions Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : ServerOptions Property

Gets a collection of desired server options.

Syntax

Visual Basic (Declaration)
<DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)>
<DescriptionAttribute("Returns a collection of desired server options ('DO' commands are sent).")>
<CategoryAttribute("Telnet Options")>
Public ReadOnly Property ServerOptions As OptionCollection
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As OptionCollection

value = instance.ServerOptions
C#
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Returns a collection of desired server options ('DO' commands are sent).")]
[CategoryAttribute("Telnet Options")]
public OptionCollection ServerOptions {get;}
Managed Extensions for C++
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Returns a collection of desired server options ('DO' commands are sent).")]
[CategoryAttribute("Telnet Options")]
public: __property OptionCollection* get_ServerOptions();
C++/CLI
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Content)]
[DescriptionAttribute("Returns a collection of desired server options ('DO' commands are sent).")]
[CategoryAttribute("Telnet Options")]
public:
property OptionCollection^ ServerOptions {
   OptionCollection^ get();
}

Example

The following example demonstrates how to set options for automatic option negotiation.
C# Copy Code
if (telnet1.RemoteEndPoint.Port == 23)
{
    //Standard telnet port, add standard telnet options
    telnet1.ClientOptions.Add(new Option(OptionCode.SuppressGoAheads, null, OptionState.RequestOn));
    telnet1.ClientOptions.Add(new Option(OptionCode.WindowSize,
        new Byte[] { ((Byte)(0)), ((Byte)(80)), ((Byte)(0)), ((Byte)(24)) }, OptionState.RequestOn));
    telnet1.ClientOptions.Add(new Option(OptionCode.TerminalType,
        new System.Byte[] { ((Byte)(0)), ((Byte)(116)), ((Byte)(116)), ((Byte)(121)) }, OptionState.RequestOn));

    telnet1.ServerOptions.Add(new Option(OptionCode.SuppressGoAheads, null, OptionState.RequestOn));
    telnet1.ServerOptions.Add(new Option(OptionCode.Echo, null, OptionState.RequestOn));
    telnet1.ServerOptions.Add(new Option(OptionCode.OutputPageSize, null, OptionState.RequestOn));
}
else
{
    //Non-standard telnet port, do not send telnet options
    telnet1.ClientOptions.Clear();
    telnet1.ServerOptions.Clear();
}
Visual Basic Copy Code
If telnet1.RemoteEndPoint.Port = 23 Then
    'Standard telnet port, add standart telnet options
    telnet1.ClientOptions.Add(New [Option](OptionCode.SuppressGoAheads, Nothing, OptionState.RequestOn))
    telnet1.ClientOptions.Add(New [Option](OptionCode.WindowSize, _
        New System.Byte() { (CByte(0)), (CByte(80)), (CByte(0)), (CByte(24)) }, OptionState.RequestOn))
    telnet1.ClientOptions.Add(New [Option](OptionCode.TerminalType, _
        New System.Byte() { (CByte(0)), (CByte(116)), (CByte(116)), (CByte(121)) }, OptionState.RequestOn))

    telnet1.ServerOptions.Add(New [Option](OptionCode.SuppressGoAheads, Nothing, OptionState.RequestOn))
    telnet1.ServerOptions.Add(New [Option](OptionCode.Echo, Nothing, OptionState.RequestOn))
    telnet1.ServerOptions.Add(New [Option](OptionCode.OutputPageSize, Nothing, OptionState.RequestOn))
Else
    'Non-standard telnet port, do not send telnet options
    telnet1.ClientOptions.Clear()
    telnet1.ServerOptions.Clear()
End If

Remarks

The client will send a DO command for the options within the collection.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


TerminalType Property

[image]
PowerTCP Telnet for .NET
TerminalType Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : TerminalType Property

Gets or sets the terminal type used for the Telnet TerminalType option.

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Telnet Options")>
<DescriptionAttribute("Specifies the desired terminal type for server emulation purposes.")>
<DefaultValueAttribute()>
Public Property TerminalType As String
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As String

instance.TerminalType = value

value = instance.TerminalType
C#
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Specifies the desired terminal type for server emulation purposes.")]
[DefaultValueAttribute()]
public string TerminalType {get; set;}
Managed Extensions for C++
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Specifies the desired terminal type for server emulation purposes.")]
[DefaultValueAttribute()]
public: __property string* get_TerminalType();
public: __property void set_TerminalType(
   string* value
);
C++/CLI
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Specifies the desired terminal type for server emulation purposes.")]
[DefaultValueAttribute()]
public:
property String^ TerminalType {
   String^ get();
   void set (    String^ value);
}

Property Value

tty

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


WindowSize Property

[image]
PowerTCP Telnet for .NET
WindowSize Property
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : WindowSize Property

Gets or sets the window-size used for the Telnet WindowSize option.

Syntax

Visual Basic (Declaration)
<DefaultValueAttribute()>
<CategoryAttribute("Telnet Options")>
<DescriptionAttribute("Specifies the desired window-size for the Telnet WindowSize option (normally 80x24).")>
Public Property WindowSize As Size
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim value As Size

instance.WindowSize = value

value = instance.WindowSize
C#
[DefaultValueAttribute()]
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Specifies the desired window-size for the Telnet WindowSize option (normally 80x24).")]
public Size WindowSize {get; set;}
Managed Extensions for C++
[DefaultValueAttribute()]
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Specifies the desired window-size for the Telnet WindowSize option (normally 80x24).")]
public: __property Size get_WindowSize();
public: __property void set_WindowSize(
   Size value
);
C++/CLI
[DefaultValueAttribute()]
[CategoryAttribute("Telnet Options")]
[DescriptionAttribute("Specifies the desired window-size for the Telnet WindowSize option (normally 80x24).")]
public:
property Size WindowSize {
   Size get();
   void set (    Size value);
}

Property Value

A Size object with default Width and Height values of 80 and 24.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Telnet Class Fields

[image]
PowerTCP Telnet for .NET
Telnet Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : Telnet Class

"

For a list of all members of this type, see Telnet members.

"

Public Fields

 | Name | Description
public Field | DefaultPort | The "well-known" default port 23 for Rsh operations.
Top

See Also

Reference

Telnet Class
Dart.Telnet Namespace


DefaultPort Field

[image]
PowerTCP Telnet for .NET
DefaultPort Field
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : DefaultPort Field

The "well-known" default port 23 for Rsh operations.

Syntax

Visual Basic (Declaration)
Public Const DefaultPort As Integer
Visual Basic (Usage) Copy Code
Dim value As Integer

value = Telnet.DefaultPort
C#
public const int DefaultPort
Managed Extensions for C++
public: const int DefaultPort
C++/CLI
public:
const int DefaultPort

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Telnet Class Events

[image]
PowerTCP Telnet for .NET
Telnet Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : Telnet Class

"

For a list of all members of this type, see Telnet members.

"

Public Events

 | Name | Description
public Event | ClientOptionChanged | Raised when a client Telnet option has changed state (WILL or WONT confirmed).
public Event | CommandReceived | Raised when a Telnet command is received from the server.
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | ServerOptionChanged | Raised when a server Telnet option has changed state (DO or DONT confirmed).
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Telnet Class
Dart.Telnet Namespace


ClientOptionChanged Event

[image]
PowerTCP Telnet for .NET
ClientOptionChanged Event
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : ClientOptionChanged Event

Raised when a client Telnet option has changed state (WILL or WONT confirmed).

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Raised when a client Telnet option has changed state (WILL or WONT confirmed).")>
<CategoryAttribute("Telnet")>
Public Event ClientOptionChanged As EventHandler(Of OptionEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim handler As EventHandler(Of OptionEventArgs)

AddHandler instance.ClientOptionChanged, handler
C#
[DescriptionAttribute("Raised when a client Telnet option has changed state (WILL or WONT confirmed).")]
[CategoryAttribute("Telnet")]
public event EventHandler<OptionEventArgs> ClientOptionChanged
Managed Extensions for C++
[DescriptionAttribute("Raised when a client Telnet option has changed state (WILL or WONT confirmed).")]
[CategoryAttribute("Telnet")]
public: __event EventHandler<OptionEventArgs*>* ClientOptionChanged
C++/CLI
[DescriptionAttribute("Raised when a client Telnet option has changed state (WILL or WONT confirmed).")]
[CategoryAttribute("Telnet")]
public:
event EventHandler<OptionEventArgs^>^ ClientOptionChanged

Event Data

The event handler receives an argument of type OptionEventArgs containing data related to this event. The following OptionEventArgs properties provide information specific to this event.

Property | Description
Option | The updated option causing the event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


CommandReceived Event

[image]
PowerTCP Telnet for .NET
CommandReceived Event
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : CommandReceived Event

Raised when a Telnet command is received from the server.

Syntax

Visual Basic (Declaration)
<DescriptionAttribute("Raised when a Telnet command is received.")>
<CategoryAttribute("Telnet")>
Public Event CommandReceived As EventHandler(Of CommandEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim handler As EventHandler(Of CommandEventArgs)

AddHandler instance.CommandReceived, handler
C#
[DescriptionAttribute("Raised when a Telnet command is received.")]
[CategoryAttribute("Telnet")]
public event EventHandler<CommandEventArgs> CommandReceived
Managed Extensions for C++
[DescriptionAttribute("Raised when a Telnet command is received.")]
[CategoryAttribute("Telnet")]
public: __event EventHandler<CommandEventArgs*>* CommandReceived
C++/CLI
[DescriptionAttribute("Raised when a Telnet command is received.")]
[CategoryAttribute("Telnet")]
public:
event EventHandler<CommandEventArgs^>^ CommandReceived

Event Data

The event handler receives an argument of type CommandEventArgs containing data related to this event. The following CommandEventArgs properties provide information specific to this event.

Property | Description
Command | The command sent by the remote host.
OptionCode | The option pertaining to the received command.
SubOption | Suboption pertaining to the received command.

Remarks

A CommandEventArgs object containing information required to handle the command is provided to the event handler. For example, CommandEventArgs.Command contains the Command sent from the server.

If a reply is sent to the server using SendOption from within the event handler, it is assumed option negotiation will be handled by the developer and automatic option negotiation is turned off.

This event is not marshaled to the UI thread, even if the SynchronizingObject is set.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


ServerOptionChanged Event

[image]
PowerTCP Telnet for .NET
ServerOptionChanged Event
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : ServerOptionChanged Event

Raised when a server Telnet option has changed state (DO or DONT confirmed).

Syntax

Visual Basic (Declaration)
<CategoryAttribute("Telnet")>
<DescriptionAttribute("Raised when a server Telnet option has changed state (DO or DONT confirmed).")>
Public Event ServerOptionChanged As EventHandler(Of OptionEventArgs)
Visual Basic (Usage) Copy Code
Dim instance As Telnet
Dim handler As EventHandler(Of OptionEventArgs)

AddHandler instance.ServerOptionChanged, handler
C#
[CategoryAttribute("Telnet")]
[DescriptionAttribute("Raised when a server Telnet option has changed state (DO or DONT confirmed).")]
public event EventHandler<OptionEventArgs> ServerOptionChanged
Managed Extensions for C++
[CategoryAttribute("Telnet")]
[DescriptionAttribute("Raised when a server Telnet option has changed state (DO or DONT confirmed).")]
public: __event EventHandler<OptionEventArgs*>* ServerOptionChanged
C++/CLI
[CategoryAttribute("Telnet")]
[DescriptionAttribute("Raised when a server Telnet option has changed state (DO or DONT confirmed).")]
public:
event EventHandler<OptionEventArgs^>^ ServerOptionChanged

Event Data

The event handler receives an argument of type OptionEventArgs containing data related to this event. The following OptionEventArgs properties provide information specific to this event.

Property | Description
Option | The updated option causing the event.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


UserStateEventArgs Class

[image]
PowerTCP Telnet for .NET
UserStateEventArgs Class
Members See Also Send comments on this topic.
Dart.Telnet Namespace : UserStateEventArgs Class

Base class for EventArgs that have a UserState property.

Object Model

UserStateEventArgs Class

Syntax

Visual Basic (Declaration)
Public Class UserStateEventArgs
   Inherits System.EventArgs
Visual Basic (Usage) Copy Code
Dim instance As UserStateEventArgs
C#
public class UserStateEventArgs : System.EventArgs
Managed Extensions for C++
public __gc class UserStateEventArgs : public System.EventArgs
C++/CLI
public ref class UserStateEventArgs : public System.EventArgs

Inheritance Hierarchy

System.Object
System.EventArgs
Dart.Telnet.UserStateEventArgs
Dart.Telnet.DataEventArgs

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

UserStateEventArgs Members
Dart.Telnet Namespace


UserStateEventArgs Class Members

[image]
PowerTCP Telnet for .NET
UserStateEventArgs Class Members
See Also Properties Send comments on this topic.
Dart.Telnet Namespace : UserStateEventArgs Class

The following tables list the members exposed by UserStateEventArgs.

Public Properties

 | Name | Description
public Property | Message | Gets the user message provided by the Message event.
public Property | UserState | Gets the user state provided by the UserState event.
Top

See Also

Reference

UserStateEventArgs Class
Dart.Telnet Namespace


UserStateEventArgs Class Properties

[image]
PowerTCP Telnet for .NET
UserStateEventArgs Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : UserStateEventArgs Class

"

For a list of all members of this type, see UserStateEventArgs members.

"

Public Properties

 | Name | Description
public Property | Message | Gets the user message provided by the Message event.
public Property | UserState | Gets the user state provided by the UserState event.
Top

See Also

Reference

UserStateEventArgs Class
Dart.Telnet Namespace


Message Property

[image]
PowerTCP Telnet for .NET
Message Property
See Also Send comments on this topic.
Dart.Telnet Namespace > UserStateEventArgs Class : Message Property

Gets the user message provided by the Message event.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property Message As String
Visual Basic (Usage) Copy Code
Dim instance As UserStateEventArgs
Dim value As String

value = instance.Message
C#
public string Message {get;}
Managed Extensions for C++
public: __property string* get_Message();
C++/CLI
public:
property String^ Message {
   String^ get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

UserStateEventArgs Class
UserStateEventArgs Members


UserState Property

[image]
PowerTCP Telnet for .NET
UserState Property
See Also Send comments on this topic.
Dart.Telnet Namespace > UserStateEventArgs Class : UserState Property

Gets the user state provided by the UserState event.

Syntax

Visual Basic (Declaration)
Public ReadOnly Property UserState As Object
Visual Basic (Usage) Copy Code
Dim instance As UserStateEventArgs
Dim value As Object

value = instance.UserState
C#
public object UserState {get;}
Managed Extensions for C++
public: __property Object* get_UserState();
C++/CLI
public:
property Object^ UserState {
   Object^ get();
}

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

UserStateEventArgs Class
UserStateEventArgs Members


Command Enumeration

[image]
PowerTCP Telnet for .NET
Command Enumeration
See Also Send comments on this topic.
Dart.Telnet Namespace : Command Enumeration

Enumerates the TELNET protocol commands that can be sent.

Syntax

Visual Basic (Declaration)
Public Enum Command
   Inherits System.Enum
Visual Basic (Usage) Copy Code
Dim instance As Command
C#
public enum Command : System.Enum
Managed Extensions for C++
__value public enum Command : public System.Enum
C++/CLI
public enum class Command : public System.Enum

Members

Member | Description
AO | 245 Abort output. Invokes a function on the recipient to stop sending output data while continuing the current process.
Ayt | 246 Are you there. Invokes a function on the recipient to provide printable evidence that it is still up and running.
Brk | 243 Break. Indicates the "Break" key on the recipient host was hit.
DM | 242 Data stream portion of a Synch. If the sender is sending Urgent data, this notifies the recipient to resume normal processing.
Do | 253 Used during option negotiation. Indicates the request that the other party perform, or confirmation that you are expecting the other party to perform, the indicated option.
Dont | 254 Used during option negotiation. Indicates the demand that the other party stop performing, or confirmation that you are no longer expecting the other party to perform, the indicated option.
EC | 247 Erase character. Invokes a function on the recipient to "delete" the preceding undeleted character from the incoming stream of data.
EL | 248 Erase line. Invokes a function on the recipient to "delete" the preceding undeleted line from the incoming stream of data.
GA | 249 Go ahead. Typically is suppressed.
Iac | 255 Interpret As Command byte (255). Tells the recipient to interpret the next byte as a command.
IP | 244 Interrupt process. Invokes a function on the recipient to suspend, interrupt, abort, or terminate a user process.
Nop | 241 No operation.
SB | 250 Used during option negotiation to establish/provide data for a suboption. Indicates what follows is subnegotiation of the indicated option.
SE | 240 Marks the end of subnegotiation parameters.
Will | 251 Used during option negotiation. Indicates the desire to begin performing, or confirmation that you are now performing, the indicated option.
Wont | 252 Used during option negotiation. Indicates the refusal to perform, or continue performing, the indicated option.

Remarks

The Telnet protocol uses "in-band" signaling to send commands. A special byte, the Interpret As Command (Iac) byte, is sent to instruct the receiver to interpret the next byte as a command. Telnet commands can fall under several categories. Some commands are used solely during option negotiation (DO, DONT, WILL, WONT) to help establish options that both client and server will use. Other commands represent control functions (Ayt, Brk, Nop, etc) used to emit a particular response from the server.

Inheritance Hierarchy

System.Object
System.ValueType
System.Enum
Dart.Telnet.Command

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Dart.Telnet Namespace


ConnectionState Enumeration

[image]
PowerTCP Telnet for .NET
ConnectionState Enumeration
See Also Send comments on this topic.
Dart.Telnet Namespace : ConnectionState Enumeration

Defines the possible states of the connection.

Syntax

Visual Basic (Declaration)
Public Enum ConnectionState
   Inherits System.Enum
Visual Basic (Usage) Copy Code
Dim instance As ConnectionState
C#
public enum ConnectionState : System.Enum
Managed Extensions for C++
__value public enum ConnectionState : public System.Enum
C++/CLI
public enum class ConnectionState : public System.Enum

Members

Member | Description
Closed | The connection is closed.
Connected | The TCP connection is established but not secure.
ConnectedAndSecure | The connection is connected and secure.

Inheritance Hierarchy

System.Object
System.ValueType
System.Enum
Dart.Telnet.ConnectionState

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Dart.Telnet Namespace


DataDirection Enumeration

[image]
PowerTCP Telnet for .NET
DataDirection Enumeration
See Also Send comments on this topic.
Dart.Telnet Namespace : DataDirection Enumeration

Enumerates the directions data travels.

Syntax

Visual Basic (Declaration)
Public Enum DataDirection
   Inherits System.Enum
Visual Basic (Usage) Copy Code
Dim instance As DataDirection
C#
public enum DataDirection : System.Enum
Managed Extensions for C++
__value public enum DataDirection : public System.Enum
C++/CLI
public enum class DataDirection : public System.Enum

Members

Member | Description
In | Data was received (using the Read method).
Out | Data was sent (using the Write method).

Inheritance Hierarchy

System.Object
System.ValueType
System.Enum
Dart.Telnet.DataDirection

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Dart.Telnet Namespace


OptionCode Enumeration

[image]
PowerTCP Telnet for .NET
OptionCode Enumeration
See Also Send comments on this topic.
Dart.Telnet Namespace : OptionCode Enumeration

Enumerates the supported Telnet options.

Syntax

Visual Basic (Declaration)
Public Enum OptionCode
   Inherits System.Enum
Visual Basic (Usage) Copy Code
Dim instance As OptionCode
C#
public enum OptionCode : System.Enum
Managed Extensions for C++
__value public enum OptionCode : public System.Enum
C++/CLI
public enum class OptionCode : public System.Enum

Members

Member | Description
ApproxMessageSize | 4 Approx Message Size Negotiation option.
Authentication | 37 Authentication option. Used to request or confirm that the host is willing to send authentication information. See RFC 1416, RFC 2941, RFC 2942, RFC 2943, and RFC 2951 for more information.
ByteMacro | 19 Byte-Macro option. Used to request or confirm that macro bytes may be used in place of certain strings. See RFC 735 for more information.
CharacterSet | 42 CHARSET option. Used to request or confirm that character set information can be passed between hosts. See RFC 2066 for more information.
ComPort | 44 Com Port Control option. See RFC 2217 for more information.
DataEntryTerminal | 20 Data Entry Terminal option. Used to request or agree to send or receive commands to control the Data Entry Terminal. See RFC 732 or RFC 1043 for more information.
Echo | 1 ECHO option. Used to request or confirm that characters received are echoed back to the NVT. See RFC 857 for more information.
EncryptionOption | 38 Data Encryption option. Used to request or confirm that the host is willing to send/receive encrypted data. See RFC 2946 for more information.
EndOfRecord | 25 END-OF-RECORD option. Used to request or confirm that the EOR character can be used when sending data to delimit blocks of data or records. See RFC 885 for more information.
Environment | 36 Environment option. Used to request or confirm that environment information can be passed between hosts. See RFC 1408 for more information.
ExtendedAscii | 17 EXTENDED-ASCII option. Used to request or confirm that extended ASCII may be transmitted. See RFC 698 for more information.
ExtendedOptionsList | 255 EXOPL, Extended-Options-List option.
ForwardX | 49 FORWARD_X option.
Kermit | 47 Kermit option. Used to request or confirm the communication can use the Kermit protocol. See RFC 2840 for more information.
LineMode | 34 Linemode option. Used to request or confirm that linemode is used. See RFC 1184 for more information.
Logout | 18 LOGOUT option. Used to request or confirm that the other client is forcibly logged off at the end. See RFC 727 for more information.
NewEnvironment | 39 Environment option. Used to request or confirm that environment information can be passed between hosts. See RFC 1572 for more information.
None | -1 No option specified.
OutputCarriageReturnDisp | 10 Negotiate About Output Carriage-Return Disposition option. See RFC 652 for more information.
OutputFormfeedDisp | 13 Negotiate About Output Formfeed Disposition option. See RFC 655 for more information.
OutputHorizontalTabDisp | 12 Negotiate About Output Horizontal Tab Disposition option. See RFC 654 for more information.
OutputHorizontalTabstops | 11 Negotiate About Output Horizontal Tabstops option. See RFC 653 for more information.
OutputLinefeedDisp | 16 Negotiate About Output Linefeed Disposition option. See RFC 658 for more information.
OutputLineWidth | 8 Output Line Width option.
OutputMarking | 27 Output Marking Telnet option. Designed to allow a Server to send a banner to a User so that this banner would be displayed on the screen independently of the application software running in the Server. See RFC 933 for more information.
OutputPageSize | 9 Output Page Size option.
OutputVerticalTabDisp | 15 Negotiate About Output Vertical Tab Disposition option. See RFC 657 for more information.
OutputVerticalTabstops | 14 Negotiate About Vertical Tabstops option. See RFC 656 for more information.
PragmaHeartbeat | 140 TELOPT PRAGMA HEARTBEAT option.
PragmaLogon | 138 TELOPT PRAGMA LOGON option.
Regime3270 | 29 3270 Regime option. Used to request or confirm that 3270 Regimes be supported. See RFC 1041 for more information.
RemoteControlledTransAndEcho | 7 Remote Controlled Transmission and Echoing Telnet option. See RFC 563 and RFC 726 for more information.
RemoteSerialPort | 43 RSP option. Telnet remote serial port.
SendLocation | 23 SEND-LOCATION option. Used to request or confirm that the user can send their location to the Telnet server. See RFC 779 for more information.
SendUrl | 48 SEND-URL option.
SspiLogon | 139 TELOPT SSPI LOGON option.
StartTls | 46 Start TLS option.
Status | 5 STATUS option. Used to request or confirm the receiver's current option status. See RFC 859 for more information.
SupDup | 21 SUPDUP option. See RFC 734 or RFC 736 for more information.
SupDupOutput | 22 SUPDUP-Output option. See RFC 749 for more information.
SuppressGoAheads | 3 SUPPRESS-GO-AHEAD option. Used to request or confirm that the GO-AHEAD is not sent. See RFC 858 for more information.
SuppressLocalEcho | 45 Suppress local echo option.
TacacsUserIdentification | 26 TACACS User Identification Telnet option. Designed to facilitate double login avoidance for communication between TAC hosts. See RFC 927 for more information.
TerminalLocation | 28 Terminal Location Number option. Used to request or confirm usage of a TTYLOC. See RFC 946 for more information.
TerminalSpeed | 32 Terminal Speed option. Used to request or confirm that terminal speed information can be sent in a suboption. See RFC 1079 for more information.
TerminalType | 24 TERMINAL-TYPE option. Used to request or confirm that terminal-type is sent in a subsequent suboption. See RFC 1091 for more information.
TimingMark | 6 TIMING-MARK option. Used to request or or send a TIMING-MARK echo, used for synchronization. See RFC 860 for more information.
TN3270E | 40 TN3270 option. Used to request or confirm that 3270 device family enhancements can be used. See RFC 2355 for more information.
ToggleFlowControl | 33 Remote Flow Control option. Used to request or confirm that flow control can be used. See RFC 1372 for more information.
TransmitBinary | 0 TRANSMIT-BINARY option. Used to request or confirm that received data is to be interpreted as 8 bits of binary data. See RFC 856 for more information.
WindowSize | 31 Negotiate About Window Size option. Used by a client to request if they can convey window size to a server. See RFC 1073 for more information.
X3Pad | 30 X.3 Pad option. See RFC 1035 for more information.
Xauth | 41 XAUTH option.
XDisplayLocation | 35 X Display Location option. Used to request or confirm that the X display location of the client can be sent to the server. See RFC 1096 for more information.

Remarks

The Telnet protocol defines a framework from which both sides of a Telnet connection can negotiate options, enhancing the NVT. For information on a particular value, please consult the RFC for the option.

Inheritance Hierarchy

System.Object
System.ValueType
System.Enum
Dart.Telnet.OptionCode

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Dart.Telnet Namespace


OptionState Enumeration

[image]
PowerTCP Telnet for .NET
OptionState Enumeration
See Also Send comments on this topic.
Dart.Telnet Namespace : OptionState Enumeration

Enumerates the current state of an Option object.

Syntax

Visual Basic (Declaration)
Public Enum OptionState
   Inherits System.Enum
Visual Basic (Usage) Copy Code
Dim instance As OptionState
C#
public enum OptionState : System.Enum
Managed Extensions for C++
__value public enum OptionState : public System.Enum
C++/CLI
public enum class OptionState : public System.Enum

Members

Member | Description
Allow |
Off |
On |
RequestOff |
RequestOn |
Waiting |

Inheritance Hierarchy

System.Object
System.ValueType
System.Enum
Dart.Telnet.OptionState

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Dart.Telnet Namespace


ProxyType Enumeration

[image]
PowerTCP Telnet for .NET
ProxyType Enumeration
See Also Send comments on this topic.
Dart.Telnet Namespace : ProxyType Enumeration

Enumerates the proxy support provided by this product.

Syntax

Visual Basic (Declaration)
Public Enum ProxyType
   Inherits System.Enum
Visual Basic (Usage) Copy Code
Dim instance As ProxyType
C#
public enum ProxyType : System.Enum
Managed Extensions for C++
__value public enum ProxyType : public System.Enum
C++/CLI
public enum class ProxyType : public System.Enum

Members

Member | Description
Http | An HTTP server proxy is to be used.
None | No server proxy is to be used.
Socks4 | A SOCKS4 server proxy is to be used.
Socks5 | A SOCKS5 server proxy is to be used.

Inheritance Hierarchy

System.Object
System.ValueType
System.Enum
Dart.Telnet.ProxyType

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Dart.Telnet Namespace


ReadAsyncCompleted Delegate

[image]
PowerTCP Telnet for .NET
ReadAsyncCompleted Delegate
See Also Send comments on this topic.
Dart.Telnet Namespace : ReadAsyncCompleted Delegate

tcp
The TcpBase object used to manage the connection.
data
The Data object containing received data.
state
Any additional information provided by the user.
Represents the method that will execute on an IO completion thread after data is asynchronously received.

Syntax

Visual Basic (Declaration)
Public Delegate Sub ReadAsyncCompleted( _
   ByVal tcp As TcpBase, _
   ByVal data As Data, _
   ByVal state As Object _
)
Visual Basic (Usage) Copy Code
Dim instance As New ReadAsyncCompleted(AddressOf HandlerMethod)
C#
public delegate void ReadAsyncCompleted(
   TcpBase tcp,
   Data data,
   object state
)
Managed Extensions for C++
public: __gc __delegate void ReadAsyncCompleted(
   TcpBase* tcp,
   Data* data,
   Object* state
)
C++/CLI
public delegate void ReadAsyncCompleted(
   TcpBase^ tcp,
   Data^ data,
   Object^ state
)

Parameters

tcp
The TcpBase object used to manage the connection.
data
The Data object containing received data.
state
Any additional information provided by the user.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

ReadAsyncCompleted Members
Dart.Telnet Namespace


DartLicenseException Class Methods

[image]
PowerTCP Telnet for .NET
DartLicenseException Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : DartLicenseException Class

"

For a list of all members of this type, see DartLicenseException members.

"

Public Methods

 | Name | Description
public Method | GetBaseException | When overridden in a derived class, returns the System.Exception that is the root cause of one or more subsequent exceptions. (Inherited from System.Exception)
public Method | GetObjectData | When overridden in a derived class, sets the System.Runtime.Serialization.SerializationInfo with information about the exception. (Inherited from System.Exception)
public Method | GetType | Gets the runtime type of the current instance. (Inherited from System.Exception)
Top

See Also

Reference

DartLicenseException Class
Dart.Telnet Namespace


DartLicenseException Class Properties

[image]
PowerTCP Telnet for .NET
DartLicenseException Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : DartLicenseException Class

"

For a list of all members of this type, see DartLicenseException members.

"

Public Properties

 | Name | Description
public Property | Data | Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Inherited from System.Exception)
public Property | HelpLink | Gets or sets a link to the help file associated with this exception. (Inherited from System.Exception)
public Property | InnerException | Gets the System.Exception instance that caused the current exception. (Inherited from System.Exception)
public Property | Message | Gets a message that describes the current exception. (Inherited from System.Exception)
public Property | Source | Gets or sets the name of the application or the object that causes the error. (Inherited from System.Exception)
public Property | StackTrace | Gets a string representation of the frames on the call stack at the time the current exception was thrown. (Inherited from System.Exception)
public Property | TargetSite | Gets the method that throws the current exception. (Inherited from System.Exception)
Top

Protected Properties

 | Name | Description
protected Property | HResult | Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Inherited from System.Exception)
Top

See Also

Reference

DartLicenseException Class
Dart.Telnet Namespace


DataException Class Methods

[image]
PowerTCP Telnet for .NET
DataException Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : DataException Class

"

For a list of all members of this type, see DataException members.

"

Public Methods

 | Name | Description
public Method | GetBaseException | When overridden in a derived class, returns the System.Exception that is the root cause of one or more subsequent exceptions. (Inherited from System.Exception)
public Method | GetObjectData | When overridden in a derived class, sets the System.Runtime.Serialization.SerializationInfo with information about the exception. (Inherited from System.Exception)
public Method | GetType | Gets the runtime type of the current instance. (Inherited from System.Exception)
Top

See Also

Reference

DataException Class
Dart.Telnet Namespace


DataException Class Properties

[image]
PowerTCP Telnet for .NET
DataException Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : DataException Class

"

For a list of all members of this type, see DataException members.

"

Public Properties

 | Name | Description
public Property | Data | Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Inherited from System.Exception)
public Property | HelpLink | Gets or sets a link to the help file associated with this exception. (Inherited from System.Exception)
public Property | InnerException | Gets the System.Exception instance that caused the current exception. (Inherited from System.Exception)
public Property | Message | Gets a message that describes the current exception. (Inherited from System.Exception)
public Property | Source | Gets or sets the name of the application or the object that causes the error. (Inherited from System.Exception)
public Property | StackTrace | Gets a string representation of the frames on the call stack at the time the current exception was thrown. (Inherited from System.Exception)
public Property | TargetSite | Gets the method that throws the current exception. (Inherited from System.Exception)
Top

Protected Properties

 | Name | Description
protected Property | HResult | Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Inherited from System.Exception)
Top

See Also

Reference

DataException Class
Dart.Telnet Namespace


IPEndPoint Class Methods

[image]
PowerTCP Telnet for .NET
IPEndPoint Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : IPEndPoint Class

"

For a list of all members of this type, see IPEndPoint members.

"

Public Methods

 | Name | Description
public Method | Create | Creates an System.Net.EndPoint instance from a System.Net.SocketAddress instance. (Inherited from System.Net.EndPoint)
public Method | Serialize | Serializes endpoint information into a System.Net.SocketAddress instance. (Inherited from System.Net.EndPoint)
Top

See Also

Reference

IPEndPoint Class
Dart.Telnet Namespace


ProtocolException Class Methods

[image]
PowerTCP Telnet for .NET
ProtocolException Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : ProtocolException Class

"

For a list of all members of this type, see ProtocolException members.

"

Public Methods

 | Name | Description
public Method | GetBaseException | When overridden in a derived class, returns the System.Exception that is the root cause of one or more subsequent exceptions. (Inherited from System.Exception)
public Method | GetObjectData | When overridden in a derived class, sets the System.Runtime.Serialization.SerializationInfo with information about the exception. (Inherited from System.Exception)
public Method | GetType | Gets the runtime type of the current instance. (Inherited from System.Exception)
Top

See Also

Reference

ProtocolException Class
Dart.Telnet Namespace


ProtocolException Class Properties

[image]
PowerTCP Telnet for .NET
ProtocolException Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : ProtocolException Class

"

For a list of all members of this type, see ProtocolException members.

"

Public Properties

 | Name | Description
public Property | Data | Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Inherited from System.Exception)
public Property | HelpLink | Gets or sets a link to the help file associated with this exception. (Inherited from System.Exception)
public Property | InnerException | Gets the System.Exception instance that caused the current exception. (Inherited from System.Exception)
public Property | Message | Gets a message that describes the current exception. (Inherited from System.Exception)
public Property | Source | Gets or sets the name of the application or the object that causes the error. (Inherited from System.Exception)
public Property | StackTrace | Gets a string representation of the frames on the call stack at the time the current exception was thrown. (Inherited from System.Exception)
public Property | TargetSite | Gets the method that throws the current exception. (Inherited from System.Exception)
Top

Protected Properties

 | Name | Description
protected Property | HResult | Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Inherited from System.Exception)
Top

See Also

Reference

ProtocolException Class
Dart.Telnet Namespace


PtyBase Class Events

[image]
PowerTCP Telnet for .NET
PtyBase Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : PtyBase Class

"

For a list of all members of this type, see PtyBase members.

"

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

PtyBase Class
Dart.Telnet Namespace


PtyBase Class Methods

[image]
PowerTCP Telnet for .NET
PtyBase Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : PtyBase Class

"

For a list of all members of this type, see PtyBase members.

"

Public Methods

 | Name | Description
public Method | Abort | Performs a hard close of the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsClient | Authenticates the server when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | AuthenticateAsServer | Authenticates a client when establishing a secure connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Close | Gracefully closes the connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Connect | Connects to a server using parameters found in the session parameter. (Inherited from Dart.Telnet.TcpBase)
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | GetStream | Provides access to the underlying Stream. (Inherited from Dart.Telnet.TcpBase)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals data to the UI thread. (Inherited from Dart.Telnet.TcpBase)
public Method | Read | Overloaded. Receives data from the remote host. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadAsync | Start an asynchronous read on the socket. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToCount | Read until count bytes are read, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToDelimiter | Overloaded. Read until the delimiter is found, an exception is thrown, or the connection is closed. (Inherited from Dart.Telnet.TcpBase)
public Method | ReadToEnd | Read until the connection is closed or an exception is thrown. (Inherited from Dart.Telnet.TcpBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
public Method | ShutdownSsl | Signals the remote host to shutdown the SSL connection. (Inherited from Dart.Telnet.TcpBase)
public Method | Write | Overloaded. Sends data to the remote host. (Inherited from Dart.Telnet.TcpBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnData | Raises the TcpBase.Data event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnLog | Raises the TcpBase.Log event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnStateChanged | Raises the TcpBase.StateChanged event. (Inherited from Dart.Telnet.TcpBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

PtyBase Class
Dart.Telnet Namespace


Rexec Class Events

[image]
PowerTCP Telnet for .NET
Rexec Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : Rexec Class

"

For a list of all members of this type, see Rexec members.

"

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rexec Class
Dart.Telnet Namespace


Rexec Class Properties

[image]
PowerTCP Telnet for .NET
Rexec Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Rexec Class

"

For a list of all members of this type, see Rexec members.

"

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

Rexec Class
Dart.Telnet Namespace


Rlogin Class Events

[image]
PowerTCP Telnet for .NET
Rlogin Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : Rlogin Class

"

For a list of all members of this type, see Rlogin members.

"

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rlogin Class
Dart.Telnet Namespace


Rsh Class Events

[image]
PowerTCP Telnet for .NET
Rsh Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : Rsh Class

"

For a list of all members of this type, see Rsh members.

"

Public Events

 | Name | Description
public Event | Data | Raised when TcpBase.Marshal is used. (Inherited from Dart.Telnet.TcpBase)
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | Log | Raised when data is read or written. (Inherited from Dart.Telnet.TcpBase)
public Event | StateChanged | Raised when the value of the State property changes. (Inherited from Dart.Telnet.TcpBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

Rsh Class
Dart.Telnet Namespace


Rsh Class Properties

[image]
PowerTCP Telnet for .NET
Rsh Class Properties
See Also Send comments on this topic.
Dart.Telnet Namespace : Rsh Class

"

For a list of all members of this type, see Rsh members.

"

Public Properties

 | Name | Description
public Property | CloseTime | Returns the DateTime the connection was closed. (Inherited from Dart.Telnet.TcpBase)
public Property | ConnectTime | Returns the DateTime the connection was established. (Inherited from Dart.Telnet.TcpBase)
public Property | Container | Gets the System.ComponentModel.IContainer that contains the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Encoding | Character encoding used by the component. (Inherited from Dart.Telnet.ComponentBase)
public Property | NetworkStream | Returns the NetworkStream object created when Connect() is called. (Inherited from Dart.Telnet.TcpBase)
public Property | RemoteEndPoint | Gets the remote address and port of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | Site | Gets or sets the System.ComponentModel.ISite of the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Property | Socket | Gets the socket used by the component for communications. (Inherited from Dart.Telnet.SocketBase)
public Property | SocketOption | Gets and sets the socket options for classes derived from TcpBase. (Inherited from Dart.Telnet.TcpBase)
public Property | SslStream | Returns the SslStream object created when AuthenticateAsClient() or AuthenticateAsServer() are called. (Inherited from Dart.Telnet.TcpBase)
public Property | State | Gets the status of the connection. (Inherited from Dart.Telnet.TcpBase)
public Property | SynchronizingObject | Gets or sets the object used to marshal data to the UI thread (for raising events). (Inherited from Dart.Telnet.ComponentBase)
public Property | Tag | Gets or sets an object that stores any user data. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Properties

 | Name | Description
protected Property | CanRaiseEvents | Gets a value indicating whether the component can raise an event. (Inherited from System.ComponentModel.Component)
protected Property | DesignMode | Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode. (Inherited from System.ComponentModel.Component)
protected Property | Events | Gets the list of event handlers that are attached to this System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
Top

See Also

Reference

Rsh Class
Dart.Telnet Namespace


ServerSecurity Class Fields

[image]
PowerTCP Telnet for .NET
ServerSecurity Class Fields
See Also Send comments on this topic.
Dart.Telnet Namespace : ServerSecurity Class

"

For a list of all members of this type, see ServerSecurity members.

"

Public Fields

 | Name | Description
public Field | ValidationCallback | The delegate that executes after the server provides its certificate to the client. (Inherited from Dart.Telnet.Security)
Top

See Also

Reference

ServerSecurity Class
Dart.Telnet Namespace


SocketBase Class Events

[image]
PowerTCP Telnet for .NET
SocketBase Class Events
See Also Send comments on this topic.
Dart.Telnet Namespace : SocketBase Class

"

For a list of all members of this type, see SocketBase members.

"

Public Events

 | Name | Description
public Event | Disposed | Occurs when the component is disposed by a call to the System.ComponentModel.Component.Dispose method. (Inherited from System.ComponentModel.Component)
public Event | Error | Raised when Marshal(Exception) is used or an unhandled Exception is thrown in a worker thread created using Start. (Inherited from Dart.Telnet.ComponentBase)
public Event | UserState | Raised when Marshal(String,Object) is used. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

SocketBase Class
Dart.Telnet Namespace


SocketBase Class Methods

[image]
PowerTCP Telnet for .NET
SocketBase Class Methods
See Also Send comments on this topic.
Dart.Telnet Namespace : SocketBase Class

"

For a list of all members of this type, see SocketBase members.

"

Public Methods

 | Name | Description
public Method | CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from System.MarshalByRefObject)
public Method | Deserialize | Deserialize a previously serialized object. (Inherited from Dart.Telnet.ComponentBase)
public Method | Dispose | Overloaded. Releases all resources used by the System.ComponentModel.Component. (Inherited from System.ComponentModel.Component)
public Method | GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from System.MarshalByRefObject)
public Method | Marshal | Overloaded. Marshals a string and/or object to the UI thread. (Inherited from Dart.Telnet.ComponentBase)
public Method | Serialize | Serialize an object to the provided destination stream. (Inherited from Dart.Telnet.ComponentBase)
Top

Protected Methods

 | Name | Description
protected Method | GetService | Returns an object that represents a service provided by the System.ComponentModel.Component or by its System.ComponentModel.Container. (Inherited from System.ComponentModel.Component)
protected Method | MemberwiseClone | Overloaded. Creates a shallow copy of the current System.MarshalByRefObject object. (Inherited from System.MarshalByRefObject)
protected Method | OnError | Raises the Error event. (Inherited from Dart.Telnet.ComponentBase)
protected Method | OnUserState | Raises the UserState event. (Inherited from Dart.Telnet.ComponentBase)
Top

See Also

Reference

SocketBase Class
Dart.Telnet Namespace


Close Method

[image]
PowerTCP Telnet for .NET
Close Method
See Also Send comments on this topic.
Dart.Telnet Namespace > TcpBase Class : Close Method

Gracefully closes the connection.

Overload List

Overload | Description
Close | Gracefully closes the connection.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

TcpBase Class
TcpBase Members


Login Method

[image]
PowerTCP Telnet for .NET
Login Method
See Also Send comments on this topic.
Dart.Telnet Namespace > Telnet Class : Login Method

Logs into a telnet server using properties found in the settings parameter.

Overload List

Overload | Description
Login | Logs into a telnet server using properties found in the settings parameter.

Requirements

Target Platforms: Microsoft .NET Framework 2.0 SP1

See Also

Reference

Telnet Class
Telnet Members


Dart.Telnet Namespace Inheritance Hierarchy

Dart.Telnet Namespace Inheritance Hierarchy
See Also Send comments on this topic.

Inheritance Hierarchy

System.Object
Dart.Telnet.Credentials
Dart.Telnet.Option
Dart.Telnet.Proxy
Dart.Telnet.Security
Dart.Telnet.ClientSecurity
Dart.Telnet.ServerSecurity
Dart.Telnet.Segment
Dart.Telnet.Data
Dart.Telnet.Session
Dart.Telnet.TcpSession
Dart.Telnet.SocketOption
Dart.Telnet.TcpSocketOption
System.ApplicationException
System.Exception
Dart.Telnet.DataException
Dart.Telnet.ProtocolException
System.Collections.Generic.List<T>
Dart.Telnet.OptionCollection
System.ComponentModel.Component
System.MarshalByRefObject
Dart.Telnet.ComponentBase
Dart.Telnet.SocketBase
Dart.Telnet.TcpBase
Dart.Telnet.PtyBase
Dart.Telnet.Rlogin
Dart.Telnet.Telnet
Dart.Telnet.Rexec
Dart.Telnet.Rsh
System.EventArgs
Dart.Telnet.CommandEventArgs
Dart.Telnet.ErrorEventArgs
Dart.Telnet.OptionEventArgs
Dart.Telnet.UserStateEventArgs
Dart.Telnet.DataEventArgs
System.Exception
Dart.Telnet.DartLicenseException
System.Net.IPEndPoint
System.Net.EndPoint
Dart.Telnet.IPEndPoint

See Also

Reference

Dart.Telnet Assembly