change the value of string

  • Thread starter Thread starter manoj
  • Start date Start date
M

manoj

hi,

A "String" object is pointing to a certain location
with some value in it. I want to change the value in it
with out changing the location.

thanks for any help
manoj
 
hi,

A "String" object is pointing to a certain location
with some value in it. I want to change the value in it
with out changing the location.

manoj,

The System.String type is immutable. I'm not aware of any way to do
what you're asking. You can, however, use StringBuilder instead of a
string. StringBuilder values can be changed in place.

Hope this helps.

Chris.
 
manoj,
A "String" object is pointing to a certain location
with some value in it. I want to change the value in it
with out changing the location.

You may want to use a character array:


public char[ ] changableString[128];


Then you can change any character at a given location, without changing the
location of the character array.


Regards,

Randy
 
Back
Top