How to encrypt and decrypt the querystring values in asp.net c#?

Posted by Prabu_Spark under ASP.NET on 1/18/2013 | Points: 10 | Views : 11965 | Status : [Member] | Replies : 1
Hi sir,
Tell me the steps to encrypt and decrypt the querystring values in asp.net C#. Kindly give me the solution for this problem.

With regards,
J.Prabu.
[Email:prbspark@gmail.com]



Responses

Posted by: Nisar87 on: 1/18/2013 [Member] Starter | Points: 25

Up
0
Down
Before passing query string, you need to encrypt the value
String Val = Encrypt (Textbox1.Text);

Response.Redirect("Webform2.aspx?Name=" +Val);


//to decrypt the value to get the original text
this.txtBox1.Text =Decrypt(Request.QueryString["Name"]);


to get the code encrypt and decrypt, please refer following link
http://www.dotnetobject.com/Thread-Simple-encryption-and-decryption-in-c-asp-net

_______________________________________
Nisar Ahmad
http://www.dotnetobject.com/

Prabu_Spark, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response