473,506 Members | 16,994 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Concatonation and randon number generation

Hi

can someone tell me how i would concatonate two values obtained from 2 different textboxes

i.e what i want to do is. Concatonate the first letter of a persons firstname with the full surname and then concatonate this with a random number

Th2 firstname and surname are obtained from textboxes on my interface
this concatonation will have to be done on the onclick event of a submit button

I will then want to put the contents of this variable into a column of another datatable.

Thats my plan any way :o
Any help on this concatonation would be appreciated

thx
Nov 22 '05 #1
2 1619
Take a look at this code (VB.NET)

Dim r As New Random
Dim rNumber As Integer = r.Next(1, 10)
Dim s As String = TextBox1.Text & TextBox2.Text & rNumber.ToString

If you need more info, please let us know!

--
Greetz

Jan Tielens
________________________________
Read my weblog: http://weblogs.asp.net/jan
"Angelina" <an*******@discussions.microsoft.com> wrote in message
news:70**********************************@microsof t.com...
Hi,

can someone tell me how i would concatonate two values obtained from 2 different textboxes.
i.e what i want to do is. Concatonate the first letter of a persons firstname with the full surname and then concatonate this with a random
number.
Th2 firstname and surname are obtained from textboxes on my interface.
this concatonation will have to be done on the onclick event of a submit button.
I will then want to put the contents of this variable into a column of another datatable.
Thats my plan any way :o)
Any help on this concatonation would be appreciated.

thx

Nov 22 '05 #2
Take a look at this code (VB.NET)

Dim r As New Random
Dim rNumber As Integer = r.Next(1, 10)
Dim s As String = TextBox1.Text & TextBox2.Text & rNumber.ToString

If you need more info, please let us know!

--
Greetz

Jan Tielens
________________________________
Read my weblog: http://weblogs.asp.net/jan
"Angelina" <an*******@discussions.microsoft.com> wrote in message
news:70**********************************@microsof t.com...
Hi,

can someone tell me how i would concatonate two values obtained from 2 different textboxes.
i.e what i want to do is. Concatonate the first letter of a persons firstname with the full surname and then concatonate this with a random
number.
Th2 firstname and surname are obtained from textboxes on my interface.
this concatonation will have to be done on the onclick event of a submit button.
I will then want to put the contents of this variable into a column of another datatable.
Thats my plan any way :o)
Any help on this concatonation would be appreciated.

thx

Nov 22 '05 #3

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

Similar topics

0
2431
by: Rasmus Fogh | last post by:
Someone raised the question of automatic code generation a few weeks back. And yes, we (CCPN) are using automatic Python code generation in a major way. Basically we are making data models in...
2
435
by: Angelina | last post by:
Hi can someone tell me how i would concatonate two values obtained from 2 different textboxes i.e what i want to do is. Concatonate the first letter of a persons firstname with the full surname...
10
741
by: Ioannis Vranos | last post by:
I want to create some random numbers for encryption purposes, and i wonder if the following scheme makes it more hard to guess the underneath number generation pattern, than the plain use of...
4
4090
by: Dimos | last post by:
Hello All, I need some help with random number generation. What I need exactly is: To create a few thousand numbers, decimal and integers, between 5 and 90, and then to export them as a...
22
3403
by: gagan.singh.arora | last post by:
Hi there. I want to generate random numbers with a given probability, say 80% even and 20% odd. Is it possible to implement such an algorithm in C?
2
4482
by: Tukeind | last post by:
Hello, I am receiving the following error: error C2065: 'to_binary' : undeclared identifier while running the code below. If anyone can help I'll appreciate it? Thank you, Tukeind
21
13485
by: chico_yallin | last post by:
I just wana make a random id number based on4 digits-for examples?? Thanks in Advance Ch.Yallin
2
5575
by: argniw | last post by:
I need to assign a different random number to each record in one column in one table in access. How can i do this?
8
7549
by: Anil Gupte | last post by:
I had someone write a random number generator in C# (I am more of a VB programmer) and they came up with the following: public string GetRand(int count) { string number = ""; for (int i=0;...
6
1713
by: Fan924 | last post by:
How do I add random number generation to this background image slide show? Everything I try kills if. TIA _____________________________________ <html> <head> <meta http-equiv="Content-Type"...
0
7218
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7307
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,...
1
7021
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...
0
7478
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...
1
5035
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4701
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3188
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1532
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
755
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.