Encrypting /Decrypting ... 
Author Message
 Encrypting /Decrypting ...

Hello !

I'd be pleased to get some information on two functions : GetText and
SetText. I've been told those are TFields methods. They can be used to
encrypt and decrypt data to a database.

Can anyone give me a practical example ? A few lines of code would help me
clarify the whole thing ...

Thanks in advance !
Bye !
Lina



Wed, 18 Jun 1902 08:00:00 GMT  
 Encrypting /Decrypting ...

In the IDe Double Click the SQL component to get the Fields Editor
Select the field you want.
Select the Events page on the Object Inspector
The install both the OnGetText + OnSetText event handlers

As snippet of code is below for the GetText you should then
be able to write the converse for the SetText

Good luck!

Regards Railton....

--

procedure TFormTransactions.QueryTransactionsInterestAccruedGetText(
  Sender: TField; var Text: String; DisplayText: Boolean);
begin
  if Sender.AsFloat = 0
  then Text := ''
  else Text := FormatFloat('0.00',Sender.AsFloat);
end;

procedure TFormTransactions.QueryTransactionsInterestRateGetText(
  Sender: TField; var Text: String; DisplayText: Boolean);
begin
  if DisplayText then begin
    if Sender.AsFloat = 0
    then Text := ''
    else Text := FormatFloat('0.000000',Sender.AsFloat);
  end;
end;

--

Quote:

> Hello !

> I'd be pleased to get some information on two functions : GetText and
> SetText. I've been told those are TFields methods. They can be used to
> encrypt and decrypt data to a database.

> Can anyone give me a practical example ? A few lines of code would help me
> clarify the whole thing ...

> Thanks in advance !
> Bye !
> Lina



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Encrypting/Decrypting

2. Encrypt\Decrypt help...

3. Encrypt\Decrypt HELP...

4. Encrypt/Decrypt

5. Encrypt/Decrypt Procedure

6. Encrypting and decrypting data

7. wanted: enc/decrypt programme

8. Encrypting text stored in inidividual database records

9. Using ADO with Encrypted/Password Protected Access databases

10. Encrypting TClientDataSet field values

11. using encrypted access database

12. Encrypting Program with PDOX tables

 

 
Powered by phpBB® Forum Software