Click here to Skip to main content
15,891,529 members
Home / Discussions / C#
   

C#

 
GeneralRe: Generic List Remove method delay Pin
Abhijit Jana25-Jan-08 23:27
professionalAbhijit Jana25-Jan-08 23:27 
GeneralRe: Generic List Remove method delay Pin
DaveyM6925-Jan-08 23:31
professionalDaveyM6925-Jan-08 23:31 
GeneralString Reversal plus character replacement Pin
BREdwards25-Jan-08 11:25
BREdwards25-Jan-08 11:25 
GeneralRe: String Reversal plus character replacement Pin
pmarfleet25-Jan-08 11:54
pmarfleet25-Jan-08 11:54 
GeneralRe: String Reversal plus character replacement Pin
BREdwards25-Jan-08 12:16
BREdwards25-Jan-08 12:16 
GeneralRe: String Reversal plus character replacement Pin
pmarfleet25-Jan-08 12:25
pmarfleet25-Jan-08 12:25 
GeneralRe: String Reversal plus character replacement Pin
PIEBALDconsult25-Jan-08 13:21
mvePIEBALDconsult25-Jan-08 13:21 
GeneralRe: String Reversal plus character replacement Pin
BREdwards25-Jan-08 17:31
BREdwards25-Jan-08 17:31 
Thanks so far. The string reversal part is all taken care of, my problem is having to dynamically replace all number with their word equivalents, here's what I have so far:

<br />
		public string Reverse(string x)<br />
		{<br />
			int i;<br />
			char[] charArray = new char[x.Length];<br />
			int len = x.Length - 1;<br />
			for ( i = 0; i <= len; i++)<br />
				if(char.IsNumber(x,i))<br />
				{<br />
					switch(i)<br />
					{<br />
						case'0':<br />
							x.Replace("0","zero");<br />
								break;<br />
					}<br />
				}<br />
				charArray[i] = x[len-i];<br />
			return new string(charArray);<br />
		}<br />


I have something of an idea of what needs to be done, problem is, I can't seem to use that if statement without breaking the program. I keep getting an "index was outside the bounds of the array error" for both letters and numbers. I simply don't understand what I'm doing wrong, never had to do something like this before.
GeneralRe: String Reversal plus character replacement Pin
DaveyM6925-Jan-08 22:00
professionalDaveyM6925-Jan-08 22:00 
GeneralRe: String Reversal plus character replacement Pin
DaveyM6925-Jan-08 22:40
professionalDaveyM6925-Jan-08 22:40 
GeneralRe: String Reversal plus character replacement Pin
BREdwards26-Jan-08 17:42
BREdwards26-Jan-08 17:42 
QuestionOval buttons and using transparency Pin
MikeWeber25-Jan-08 10:55
MikeWeber25-Jan-08 10:55 
GeneralRe: Oval buttons and using transparency Pin
DaveyM6925-Jan-08 12:52
professionalDaveyM6925-Jan-08 12:52 
GeneralRe: Oval buttons and using transparency Pin
mav.northwind25-Jan-08 21:55
mav.northwind25-Jan-08 21:55 
QuestionCan I raise an event for a class rather than an object? Pin
Clive D. Pottinger25-Jan-08 7:42
Clive D. Pottinger25-Jan-08 7:42 
GeneralRe: Can I raise an event for a class rather than an object? Pin
Ed.Poore25-Jan-08 7:45
Ed.Poore25-Jan-08 7:45 
GeneralRe: Can I raise an event for a class rather than an object? Pin
Clive D. Pottinger25-Jan-08 10:19
Clive D. Pottinger25-Jan-08 10:19 
GeneralRe: Can I raise an event for a class rather than an object? Pin
Ed.Poore25-Jan-08 12:18
Ed.Poore25-Jan-08 12:18 
AnswerRe: Can I raise an event for a class rather than an object? Pin
BoneSoft25-Jan-08 8:16
BoneSoft25-Jan-08 8:16 
GeneralRe: Can I raise an event for a class rather than an object? Pin
Clive D. Pottinger25-Jan-08 10:50
Clive D. Pottinger25-Jan-08 10:50 
GeneralRe: Can I raise an event for a class rather than an object? Pin
BoneSoft25-Jan-08 12:12
BoneSoft25-Jan-08 12:12 
GeneralRe: Can I raise an event for a class rather than an object? Pin
Clive D. Pottinger1-Apr-08 11:13
Clive D. Pottinger1-Apr-08 11:13 
GeneralRe: Can I raise an event for a class rather than an object? Pin
BoneSoft1-Apr-08 13:06
BoneSoft1-Apr-08 13:06 
GeneralRe: Can I raise an event for a class rather than an object? Pin
Ennis Ray Lynch, Jr.25-Jan-08 8:20
Ennis Ray Lynch, Jr.25-Jan-08 8:20 
GeneralRe: Can I raise an event for a class rather than an object? Pin
led mike25-Jan-08 8:27
led mike25-Jan-08 8:27 

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.