You most certainly do have pointers in C#, you simply have to declare an
unsafe code block to use them.
In C# though you should avoid unsafe code when possible. The string indexer
will return each character in a string, as will a foreach statement:
foreach (char c in myString) {
// do something with c
}
or:
for (int i = 0;i++;i < myString.Length) {
// do something with myString[i]
}
--Bob
"Dave" <be******@netvision.net.il> wrote in message
news:%2***************@TK2MSFTNGP09.phx.gbl...
Hi,
how can i create an ansi string in c#(not unicode)?
How can i convert a string member lets say string str="12345" to char*
s="12345" becuse the unicode "12345" is "1020304050" and i need to cinvert
it to char* in c# but i dont have pointers in c# so what can i do???
Thanks