Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > Other ASP.NET > ASP.NET 1.x and 2.0 Application Design
|
ASP.NET 1.x and 2.0 Application Design Application design with ASP.NET 1.0, 1.1, and 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.x and 2.0 Application Design section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 23rd, 2006, 03:02 PM
Registered User
 
Join Date: Aug 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Function does not return the correct Character

I use the following function to encrypt/decrypt a string

It works fine in my main computer. However, when I run it in my laptop, the Œ character gets decrypt as an & symbol. The correct result should be the letter “s” lower case.

        Dim i As Integer
        Dim Ecn As String = (ConfigurationSettings.AppSettings("sqlStr"))
        Dim Dcn As String
        For i = 1 To Len(Ecn)
            Dcn = Dcn & Chr(Asc(Mid(Ecn, i, 1)) - 25)
        Next i

You help is appreciated

Thank you
Tom
 
Old August 23rd, 2006, 09:43 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

What are you decoding from? Base64?

"The one language all programmers understand is profanity."
 
Old August 24th, 2006, 11:39 AM
Registered User
 
Join Date: Aug 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I have encoded a text string, and saved the encoded string in the Web.config
This function is decoding the string from the Web.config and should return the same test string as the beginning.

Tom
 
Old August 24th, 2006, 11:56 AM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

But you encoded it how? Base64? Or do you me you encrypted it with RSA, MD5, etc? Is the content encoding the same on both machines? (E.g. UTF-8)

"The one language all programmers understand is profanity."





Similar Threads
Thread Thread Starter Forum Replies Last Post
remove carriage return character in a textbox maricar C# 5 September 15th, 2017 09:38 AM
function return 'Nothing' problem srinuRocks ASP.NET 2.0 Basics 0 March 10th, 2005 10:32 AM
Character replace function? echovue Access 2 December 21st, 2004 01:53 PM
How to return array value from a function nebpro BOOK: Beginning PHP4/PHP 5 ISBN: 978-0-7645-4364-7; v5 ISBN: 978-0-7645-5783-5 1 September 29th, 2004 12:14 PM
Return a UDT from a function alex_read Pro VB 6 1 April 23rd, 2004 05:37 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.