473,406 Members | 2,633 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,406 software developers and data experts.

Clear spaces between tex

Jan
Hallo,

How can i Clear empty spaces between text.
For example:

I've got the name "Justin Name" in a string and want to clear de spaces
between de names so i will get "JustinName".

What can i use to do that?

TIA Jan
Dec 4 '06 #1
3 1173
guy
use the VB 'Replace' function

newString = Replace(myString," ","")

hth

Guy
"Jan" wrote:
Hallo,

How can i Clear empty spaces between text.
For example:

I've got the name "Justin Name" in a string and want to clear de spaces
between de names so i will get "JustinName".

What can i use to do that?

TIA Jan
Dec 4 '06 #2
Try

Replace("Justin Name", " ", "")

Fred
Jan wrote:
Hallo,

How can i Clear empty spaces between text.
For example:

I've got the name "Justin Name" in a string and want to clear de spaces
between de names so i will get "JustinName".

What can i use to do that?

TIA Jan
Dec 4 '06 #3
On Mon, 4 Dec 2006 13:59:48 +0100, Jan wrote:
Hallo,

How can i Clear empty spaces between text.
For example:

I've got the name "Justin Name" in a string and want to clear de spaces
between de names so i will get "JustinName".

What can i use to do that?

TIA Jan
You can also try this:

imports System.Text.RegularExpressions

newString = Regex.Replace(oldString,"\s+","")

This way has the added benefit that it also takes care of tabs

--
Bits.Bytes
http://bytes.thinkersroom.com
Dec 4 '06 #4

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

Similar topics

4
by: Marc Durufle | last post by:
I have a string like that " Vertices " and i want to obtain "Vertices" I would want to know if there is a simple way to put off spaces on a string, thank you -- Marc Durufle Inria...
6
by: ima | last post by:
http://www.kencoffman.com/templates.htm I've been experimenting with float:left and I've been able to clear those floats as far as Opera 8.02 and Firefox 1.0.6 but IE6 is a problem. I've...
10
by: cppdev | last post by:
Hi All! I want to clear the string contents from sensitive information such as passwords, and etc. It's always a case that password will appear as string at some point or another. And i feel...
7
by: Eduardo78 | last post by:
Hello everybody, I heard I could clear (or move spaces) to all controls at ones without having to call each one of them. If someone remembers how to do that, I will apreciate your help. My...
4
by: Dhans | last post by:
Hi there, I am using log4net in my (.net v1.1) application to log the messages. I tried to clear the logfile while application is running. since log4net has the file handle it did not allow me to...
4
by: Brett Romero | last post by:
I fill a DataTable with search results, which take a very long time if I first clear it. The values come from an object and I map them into the corresponding table columns. I may have 65000...
5
by: =?Utf-8?B?UmljaA==?= | last post by:
The output window gets filled with stuff while I am debugging my app. Is there a way to programmatically clear the output window? I have read that there is currently no explicit method to do this...
6
by: Alexander Vasilevsky | last post by:
How to clear the screen in the console application in Microsoft Visual C #. NET 2003. http://www.alvas.net - Audio tools for C# and VB.Net developers + Christmas discount
6
by: Lambda | last post by:
For a std::vector, what's the difference between the clear() function and its destructor? I know their usages are different, but how about their implementations?
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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...
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,...
0
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...

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.