473,396 Members | 1,834 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.

Generate string

I am using Encryption/Decryption in one of my applications.
This process needs a key, which should be stored somewhere.
I don't want to store it in my code, so I come with idea to make a function
which generates the key. It should be 16 characters in length, must contain
digits and letters(small and big caps). And of course it should return the
same string every time it's called.
What I need how to make a function to generate this string of letters and
digits.
And I am lost, can't figure the algoritm.
Any ideas?

Thanks
Nov 21 '05 #1
2 1271
Nikolay,

You are not looking for something as this?
Guid
http://msdn.microsoft.com/library/de...y_pds_guid.asp

Cor

"Nikolay Petrov" <jo**************@mail.bg>
I am using Encryption/Decryption in one of my applications.
This process needs a key, which should be stored somewhere.
I don't want to store it in my code, so I come with idea to make a
function which generates the key. It should be 16 characters in length,
must contain digits and letters(small and big caps). And of course it
should return the same string every time it's called.
What I need how to make a function to generate this string of letters and
digits.
And I am lost, can't figure the algoritm.
Any ideas?

Thanks

Nov 21 '05 #2
I would like to keep it my way.
"Cor Ligthert" <no************@planet.nl> wrote in message
news:eK**************@TK2MSFTNGP09.phx.gbl...
Nikolay,

You are not looking for something as this?
Guid
http://msdn.microsoft.com/library/de...y_pds_guid.asp

Cor

"Nikolay Petrov" <jo**************@mail.bg>
I am using Encryption/Decryption in one of my applications.
This process needs a key, which should be stored somewhere.
I don't want to store it in my code, so I come with idea to make a
function which generates the key. It should be 16 characters in length,
must contain digits and letters(small and big caps). And of course it
should return the same string every time it's called.
What I need how to make a function to generate this string of letters and
digits.
And I am lost, can't figure the algoritm.
Any ideas?

Thanks


Nov 21 '05 #3

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

Similar topics

4
by: Stephen | last post by:
I need to generate input XML for another application by serialising classes defined in an XSD document. The code below will generate the XML I require but I need to generate this in memory rather...
2
by: PeterW | last post by:
I have an xml file from which I want to generate an xsd schema and at a later stage a cs class. The xml file has a mix of defined namespaces and also an empty namespace. These are defined as...
10
by: Mamuninfo | last post by:
Hello, Have any function in the DB2 database that can generate unique id for each string like oracle, mysql,sybase,sqlserver database. In mysql:- select md5(concat_ws("Row name")) from...
4
by: Andrew | last post by:
My VB Application opens an Access Report and has an option to generate the report in PDF once the report is closed. This is accomplished by: - Switching over to the Acrobat Printer (i.e....
2
by: SalimShahzad | last post by:
Dear Gurus, i had written following codes to auto generate the next claim no Private Const strC = "GCT/02/J/" Private Sub Command1_Click() Dim stra, stre As String Dim intb, intd As Integer...
2
by: Henry | last post by:
Hi, How can I generate an eight digit random? Can I use the staff name to generate it? May I ask is there any sample c# code to see? Thanks
4
by: Chris Bower | last post by:
Reposted from aspnet.buildingcontrols: Ok, I've got a bunch of derived controls that all have a property Rights of type Rights (Rights is an Enumerator). I wrote a custom TypeConverter so that I...
1
by: A Traveler | last post by:
Hello, i am having this problem. The exact error message is: "Unable to generate code for a value of type 'System.Web.UI.Page'. This error occurred while trying to generate the property value for...
9
by: Anubhav Jain | last post by:
Hi, I am having few .net source files(.cs or .vb) and I want to dynamically generate the corresponding .net project file(.csproj or .vbproj) for them without using visual studio.So that I could...
15
by: Ashish Khandelwal | last post by:
As MSDN is not giving us guarantee upon uniqueness of Hash Code, so could any one suggest me that how to generate a unique Hash Code for same string always, and generate different-2 Hash Code...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.