Using Assembly in ASP.NET – Simplest Example

This example demonstrates the simplest method for using a .NET assembly in an ASP.NET web page. 1) Create a new file “helloWorld.aspx” in your web site’s root directory. Using a text editor, add this: <%@ Page Language=”C#” %> <%@ Import Namespace=”Chilkat” %> <html> <head> <title>ASP.NET Hello World</title> </head> <body bgcolor=”#FFFFFF”> <p> <% Chilkat.Ftp2 ftp = new Chilkat.Ftp2(); Response.Write(ftp.Version); %> </p> […]

C# Blowfish Test Vectors

C# to match the Blowfish test vectors at this URL: http://www.schneier.com/code/vectors.txt // keys string[] key = new string[] { “0000000000000000”, “FFFFFFFFFFFFFFFF”, “3000000000000000”, “1111111111111111”, “0123456789ABCDEF”, “1111111111111111”, “0000000000000000”, “FEDCBA9876543210”, “7CA110454A1A6E57”, “0131D9619DC1376E”, “07A1133E4A0B2686”, “3849674C2602319E”, “04B915BA43FEB5B6”, “0113B970FD34F2CE”, “0170F175468FB5E6”, “43297FAD38E373FE”, “07A7137045DA2A16”, “04689104C2FD3B2F”, “37D06BB516CB7546”, “1F08260D1AC2465E”, “584023641ABA6176”, “025816164629B007”, “49793EBC79B3258F”, “4FB05E1515AB73A7”, “49E95D6D4CA229BF”, “018310DC409B26D6”, “1C587F1C13924FEF”, “0101010101010101”, “1F1F1F1F0E0E0E0E”, “E0FEE0FEF1FEF1FE”, “0000000000000000”, “FFFFFFFFFFFFFFFF”, “0123456789ABCDEF”, “FEDCBA9876543210” }; string[] plainText = new string[] { […]

osErrorInfo: Access is denied.

If you find the error “osErrorInfo: Access is denied.” in LastErrorText, it means that the file could not be opened because of file permissions problems. The “Access is denied” message originates from the Windows operating system. Check the file and directory permissions to make sure the calling process has permission to open the file for read and/or write access. Check […]

Matching DES Encryption in Java and VBScript

This page shows both Java JCE DES encryption examples, as well as examples using the Chilkat Encryption component in both Java and VBScript. Each of these examples produces identical output: The string: ABC123 encrypts to 6DA02B6AE1EA32D8 (as a hexidecimalized string) Java bytes-to-hex Encoding Utility Function public static String toHex (byte buf[]) { StringBuffer strbuf = new StringBuffer(buf.length * 2); int […]

Quoted-Printable Encoding Definition

Quoted-printable, or QP encoding, is an encoding using printable characters (i.e. alphanumeric and the equals sign “=”) to transmit 8-bit data over a 7-bit data path. It is defined as a MIME content transfer encoding for use in Internet e-mail. The basic Internet e-mail transmission protocol, SMTP, supports only ASCII characters (see also 8BITMIME). MIME defines mechanisms for sending other […]

HTTP ActiveX to Automatically Detect Settings

Question: How can I use your HTTP ActiveX library in VB to download a file with my connection settings “automatically detect settings” instead of proxy settings? Answer: Set the HTTP object’s UseIeProxy property = 1. This will cause the proxy host/port used by Internet Explorer (if set) to be used by the Chilkat HTTP component.

SMTP 550 No such user here

This was just discovered with one SMTP server: the error message: RCPT TO: <somebody@somewhere.com> 550 <somebody@somewhere.com> No such user here Was caused by forgetting to authenticate with the SMTP server.  The SMTP server requires authentication in order to relay email to another domain (in other words, it’s protected against being an open-relay).  The error message from this particular SMTP server […]

Convert MIME to Plain-Text?

Question: Is it possible to convert MIME to plain-text? Answer: The Chilkat MIME and/or Email API’s may be used to extract the plain-text body (or bodies) and/or HTML bodies from a MIME message. If a MIME-part is already plain-text, no conversion is necessary. It’s simply a matter of using the Chilkat MIME or Email API to extract the part’s contents. […]