Click here to Skip to main content
15,901,205 members
Home / Discussions / C#
   

C#

 
GeneralRe: C# Wizards? Pin
BLaZiNiX21-Apr-02 18:35
BLaZiNiX21-Apr-02 18:35 
GeneralRe: C# Wizards? Pin
Neil Van Note19-Apr-02 20:53
Neil Van Note19-Apr-02 20:53 
GeneralConnection String Pin
Mazdak19-Apr-02 3:52
Mazdak19-Apr-02 3:52 
GeneralRe: Connection String Pin
Neil Van Note19-Apr-02 7:56
Neil Van Note19-Apr-02 7:56 
GeneralRe: Connection String Pin
Mazdak19-Apr-02 8:20
Mazdak19-Apr-02 8:20 
GeneralRe: Connection String Pin
Neil Van Note19-Apr-02 10:19
Neil Van Note19-Apr-02 10:19 
GeneralRe: Connection String Pin
Mazdak19-Apr-02 10:40
Mazdak19-Apr-02 10:40 
Questiondoes Trim() work?? Pin
Senkwe Chanda19-Apr-02 0:01
Senkwe Chanda19-Apr-02 0:01 
When I run this,

C#
using System;

namespace trim
{
	public class trim
	{
		static void Main()
		{
			string str = "Senkwe    ";
			Console.WriteLine(str.Length);
			str.Trim();
			Console.WriteLine(str.Length);
		}
	}
}

I get an output of 10 each time. Am I using trim improperly? I even tried specifying an array of characters to be reomoved ie char[] myChars = {' '}; and it still didn't work.

Any ideas?

Regards

Senkwe


Just another wannabe code junky
AnswerRe: does Trim() work?? Pin
Rüpel19-Apr-02 1:21
Rüpel19-Apr-02 1:21 
GeneralRe: does Trim() work?? Pin
Senkwe Chanda19-Apr-02 2:19
Senkwe Chanda19-Apr-02 2:19 
GeneralRe: does Trim() work?? Pin
ez219-Apr-02 3:05
ez219-Apr-02 3:05 
GeneralRe: does Trim() work?? Pin
James T. Johnson19-Apr-02 11:46
James T. Johnson19-Apr-02 11:46 
GeneralRe: does Trim() work?? Pin
ColinDavies19-Apr-02 19:22
ColinDavies19-Apr-02 19:22 
GeneralRe: does Trim() work?? Pin
James T. Johnson19-Apr-02 19:56
James T. Johnson19-Apr-02 19:56 
GeneralRe: does Trim() work?? Pin
ColinDavies19-Apr-02 20:12
ColinDavies19-Apr-02 20:12 
Generalkernel32.dll Pin
Mazdak18-Apr-02 21:34
Mazdak18-Apr-02 21:34 
GeneralRe: kernel32.dll Pin
James T. Johnson18-Apr-02 22:10
James T. Johnson18-Apr-02 22:10 
GeneralRe: kernel32.dll Pin
James T. Johnson18-Apr-02 22:16
James T. Johnson18-Apr-02 22:16 
GeneralRe: kernel32.dll Pin
Rüpel18-Apr-02 22:21
Rüpel18-Apr-02 22:21 
GeneralRe: kernel32.dll Pin
Mazdak19-Apr-02 3:58
Mazdak19-Apr-02 3:58 
GeneralRe: kernel32.dll Pin
Rüpel19-Apr-02 4:12
Rüpel19-Apr-02 4:12 
GeneralRe: kernel32.dll Pin
James T. Johnson19-Apr-02 11:53
James T. Johnson19-Apr-02 11:53 
GeneralRe: kernel32.dll Pin
Christian Graus19-Apr-02 12:43
protectorChristian Graus19-Apr-02 12:43 
GeneralRe: kernel32.dll Pin
James T. Johnson19-Apr-02 12:49
James T. Johnson19-Apr-02 12:49 
QuestionAny way to make a 256 color cursor? Pin
Zombies with Coffee, LLC18-Apr-02 8:40
professionalZombies with Coffee, LLC18-Apr-02 8:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.