473,396 Members | 1,998 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Decoding a password

Hi all.

I'm using a VB6 function in my .NET application that decodes a digit
sequence and should result in a word. The funcion uses Chr function, and I
finally get an illegible string (square symbols).

How can I convert that to letters, so I can retrieve the original password?

--

Regards,

Diego F.

Jun 6 '07 #1
4 1338
"Diego F." <di********@msn.comwrote in
news:O$**************@TK2MSFTNGP04.phx.gbl:
Hi all.

I'm using a VB6 function in my .NET application that decodes a digit
sequence and should result in a word. The funcion uses Chr function,
and I finally get an illegible string (square symbols).

How can I convert that to letters, so I can retrieve the original
password?
Depends on how you encrypted your password.
Jun 6 '07 #2
I found that the problem is the use of Format function.

In VB6, that: Format("079", "000"), returns "079". But, in VB.NET, it
returns "000".

So, I'm getting different codes and the final conversion is different.

Any idea to solve that?

--

Regards,

Diego F.
"Spam Catcher" <sp**********@rogers.comwrote in message
news:Xn**********************************@127.0.0. 1...
"Diego F." <di********@msn.comwrote in
news:O$**************@TK2MSFTNGP04.phx.gbl:
>Hi all.

I'm using a VB6 function in my .NET application that decodes a digit
sequence and should result in a word. The funcion uses Chr function,
and I finally get an illegible string (square symbols).

How can I convert that to letters, so I can retrieve the original
password?

Depends on how you encrypted your password.

Jun 6 '07 #3
Ok, don't ask me how many format functions there are. I put String.Format,
and now it returns the expceted value :-)

--

Regards,

Diego F.
"Diego F." <di********@msn.comwrote in message
news:%2****************@TK2MSFTNGP05.phx.gbl...
>I found that the problem is the use of Format function.

In VB6, that: Format("079", "000"), returns "079". But, in VB.NET, it
returns "000".

So, I'm getting different codes and the final conversion is different.

Any idea to solve that?

--

Regards,

Diego F.
"Spam Catcher" <sp**********@rogers.comwrote in message
news:Xn**********************************@127.0.0. 1...
>"Diego F." <di********@msn.comwrote in
news:O$**************@TK2MSFTNGP04.phx.gbl:
>>Hi all.

I'm using a VB6 function in my .NET application that decodes a digit
sequence and should result in a word. The funcion uses Chr function,
and I finally get an illegible string (square symbols).

How can I convert that to letters, so I can retrieve the original
password?

Depends on how you encrypted your password.


Jun 6 '07 #4
Diego F. wrote:
In VB6, that: Format("079", "000"), returns "079". But, in VB.NET, it
returns "000".
That's because "0" is not a valid formatting character when working with
a /String/ value (IIRC, "@" is the only one).

You must convert your value to a /numeric/ type before calling Format on
it, as in:

Format( CInt( "079" ), "000" )

HTH,
Phill W.
Jun 7 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: steve | last post by:
Hi, I am opening a stream that is UTF encoded. I use fgetc to read the stream- which is binary safe. I add every character read to a string. But when I look at the stream, I see some...
1
by: Thomas Williams | last post by:
Hello everyone, my name is Tom W. And, I am new to the list, and have been using Python for about a year now. Anyway, I got a question! I am trying to decode MIME (base64) email from a POP3...
2
by: Bjorn Jensen | last post by:
Hello! My resulting image har nearly same size of original (but not exact) and the nu.jpg can be shown, but it is modified so much, that it look totally different.... why? what to do? Greetings...
40
by: Peter Row | last post by:
Hi all, Here is my problem: I have a SQL Server 2000 DB with various NVarChar, NText fields in its tables. For some stupid reason the data was inserted into these fields in UTF8 encoding. ...
0
by: Johann Blake | last post by:
In my need to decode a JPEG 2000 file, I discovered like many that there was no functionality for this in the .NET Framework. Instead of forking out a pile of cash to do this, I came up with the...
5
by: Peter Jansson | last post by:
Hello group, The following code is an attempt to perform URL-decoding of URL-encoded string. Note that std::istringstream is used within the switch, within the loop. Three main issues have been...
9
by: KWSW | last post by:
Having settled the huffman encoding/decoding and channel modeling(thanks to the previous part on bitwise operation), the last part would be hamming encoding/decoding. Did some research as usual on...
5
Markus
by: Markus | last post by:
Another day, another question. :) I'm now onto building a login for my current project - image host. User submits password > password is encoded Like so: ('$username',...
0
by: Michele | last post by:
Hi there, I'm using a python script in conjunction with a JPype, to run java classes. So, here's the code: from jpype import * import os import random import math import sys
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.