Click here to Skip to main content
15,900,461 members
Home / Discussions / C#
   

C#

 
QuestionConnecting to HyperTerminal or allowing c# to run a program Pin
keroed_edmond16-Jun-06 6:28
keroed_edmond16-Jun-06 6:28 
AnswerRe: Connecting to HyperTerminal or allowing c# to run a program Pin
moro14516-Jun-06 8:24
moro14516-Jun-06 8:24 
GeneralRe: Connecting to HyperTerminal or allowing c# to run a program Pin
keroed_edmond16-Jun-06 13:41
keroed_edmond16-Jun-06 13:41 
QuestionUserControl Graphics Question Pin
melkor1216-Jun-06 6:11
melkor1216-Jun-06 6:11 
AnswerRe: UserControl Graphics Question Pin
BoneSoft16-Jun-06 10:12
BoneSoft16-Jun-06 10:12 
GeneralRe: UserControl Graphics Question Pin
melkor1217-Jun-06 9:06
melkor1217-Jun-06 9:06 
Questionhow to get/set ASCII code of a character? Pin
largs16-Jun-06 5:59
largs16-Jun-06 5:59 
AnswerRe: how to get/set ASCII code of a character? Pin
Guffa16-Jun-06 7:32
Guffa16-Jun-06 7:32 
Do you really mean ASCII character codes? The Char data type in .NET is a Unicode character, so it doesn't use ASCII characters codes. If you want to use ASCII character codes you would have to encode the string into ASCII, and that leaves you with an array of bytes that you can't use as text unless you decode it again.

Assuming that you mean Unicode character codes, and not ASCII character codes:

The Char data type is a 16 bit value that represeents a Unicode character. You can easily convert between Char and Int32, and manipulate the value in either form:
char c = 'A';
c++; // c contain 'B'
c += '!'; // c contain 'c' (66+33=97)
int i = (int)c; // x contain 97
i++; // x contain 98
char d = (char)i; // d contains 'd'



---
b { font-weight: normal; }

AnswerRe: how to get/set ASCII code of a character? Pin
Le centriste16-Jun-06 7:33
Le centriste16-Jun-06 7:33 
AnswerRe: how to get/set ASCII code of a character? Pin
Rizwan Majeed16-Jun-06 8:37
professionalRizwan Majeed16-Jun-06 8:37 
GeneralRe: how to get/set ASCII code of a character? Pin
largs16-Jun-06 18:54
largs16-Jun-06 18:54 
QuestionHow to tell when socket is disconnected Pin
Glenn E. Lanier II16-Jun-06 5:42
Glenn E. Lanier II16-Jun-06 5:42 
QuestionSetting the default button on a user control Pin
GazzaJ16-Jun-06 5:40
GazzaJ16-Jun-06 5:40 
QuestionMoon phase calculation library? Pin
Radoslav Bielik16-Jun-06 5:38
Radoslav Bielik16-Jun-06 5:38 
AnswerRe: Moon phase calculation library? Pin
Dan Neely16-Jun-06 5:59
Dan Neely16-Jun-06 5:59 
AnswerRe: Moon phase calculation library? Pin
Ravi Bhavnani16-Jun-06 7:08
professionalRavi Bhavnani16-Jun-06 7:08 
GeneralRe: Moon phase calculation library? Pin
Radoslav Bielik16-Jun-06 11:19
Radoslav Bielik16-Jun-06 11:19 
Questioncould i write a program that change keyboard function with C# Pin
largs16-Jun-06 5:35
largs16-Jun-06 5:35 
QuestionBind to a private member variable of my own class. [modified] Pin
User 209307316-Jun-06 5:25
User 209307316-Jun-06 5:25 
QuestionConnectionString Problem of DLL Pin
Chikuu16-Jun-06 5:02
Chikuu16-Jun-06 5:02 
Question******** into the wind? Pin
Malcolm Smart16-Jun-06 4:43
Malcolm Smart16-Jun-06 4:43 
AnswerRe: ******** into the wind? Pin
Josh Smith16-Jun-06 4:48
Josh Smith16-Jun-06 4:48 
AnswerRe: ******** into the wind? Pin
BoneSoft16-Jun-06 10:29
BoneSoft16-Jun-06 10:29 
QuestionPanel_paint method Pin
reshsilk16-Jun-06 4:21
reshsilk16-Jun-06 4:21 
AnswerRe: Panel_paint method Pin
Josh Smith16-Jun-06 4:26
Josh Smith16-Jun-06 4:26 

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.