EasyByte Software

Welcome to EasyByte Software

Home Buy Online Products Downloads Support
Sections
Index
About
Installation
Properties
Methods
ASP and dotNET
Further Information
  

 

 

PGPEncryptString Method
 
     

Cryptocx v7 User Guide

 

PGPEncryptString Method

This is the method that you use to encrypt a string input. This method is complementary to the PGPDecryptString method.

 

Description

Encrypts some text using the PGP compatible functionality of the control.

     
Syntax

x = object.PGPEncryptString

The syntax of the PGPEncryptString method has these parts:

 
Part Description
object A Cryptocx v7 control.
x A string that becomes the cipher text (encrypted) after the method has run.

       
Remarks If for whatever reason the method fails to complete, the method will return some text stating exactly what has gone wrong. 

You need to specify the PublicKey to use when encrypting the text. The public key has to be an extracted public key, such that you pass it into the control as a string.

If you have public and private keyrings you can use the ExtractKeys method of Cryptocx to extract a specific public key then pass it back to the control via the PublicKey property and then encrypt some text using it.

You need to set the WorkingFolder property of the control to a directory that the process that will call Cryptocx will have full read/write access.

       
Returns

String

     
Example Sample Visual Basic Code to encrypt some text using the PGP compatible facility within Cryptocx.

Where Cryptocx1 is an instance of a Cryptocx Control.

Cryptocx1.WorkingFolder = "C:\"
Cryptocx1.InputText = rtfText2Encrypt.Text
Cryptocx1.PublicKey = txtPubKey.Text

rtfEncryptedText.Text = Cryptocx1.PGPEncryptString

 

 

 

 

Back to Contents Page

 

Click here to set this great site as your home page

Or click here to add it to your Favorites.

  
  
 

Copyright (c) EasyByte Software 1998-2008, info@easybyte.com