Click here to Skip to main content
15,909,530 members
Home / Discussions / C#
   

C#

 
GeneralHelp in editmode on Datalist. Pin
macsgirl9-Oct-04 11:07
macsgirl9-Oct-04 11:07 
GeneralRe: Help in editmode on Datalist. Pin
Heath Stewart10-Oct-04 11:07
protectorHeath Stewart10-Oct-04 11:07 
GeneralWindow Position Pin
dbetting9-Oct-04 10:59
dbetting9-Oct-04 10:59 
GeneralRe: Window Position Pin
Stefan Troschuetz9-Oct-04 22:50
Stefan Troschuetz9-Oct-04 22:50 
GeneralRe: Window Position Pin
dbetting10-Oct-04 3:11
dbetting10-Oct-04 3:11 
GeneralRe: Window Position Pin
Stefan Troschuetz10-Oct-04 7:07
Stefan Troschuetz10-Oct-04 7:07 
GeneralWriting hex values to a file Pin
cgcrute9-Oct-04 6:50
cgcrute9-Oct-04 6:50 
GeneralRe: Writing hex values to a file Pin
Heath Stewart9-Oct-04 8:01
protectorHeath Stewart9-Oct-04 8:01 
Any TextWriter or TextReader uses an Encoding to encode and decode bytes from and to text. More than likely it is the encoding that decided there was a better alternative, though that's just an educated guess.

You might consider using the ASCIIEncoding which is always single-byte characters, so 0xC3 0xBF isn't replaced with a "more suitable" character.

What are you writing binary characters to a file, though? If you are just trying to write the equivalent Unicode characters, you can specify Unicode in C# using \uXXXX.

Otherwise, you could use a Stream to write the entire binary file, and when you need to write text use the Encoding you find appropriate, like ASCIIEncoding or UTF8Encoding (which is nice, since for the ASCII character set (first 128 bits) it looks like an ASCII file but can handle other characters sets like Unicode without using a codepage).

This posting is provided "AS IS" with no warranties, and confers no rights.

Software Design Engineer
Developer Division Sustained Engineering
Microsoft

[My Articles] [My Blog]
GeneralRe: Writing hex values to a file Pin
cgcrute10-Oct-04 7:46
cgcrute10-Oct-04 7:46 
GeneralRe: Writing hex values to a file Pin
Heath Stewart10-Oct-04 11:05
protectorHeath Stewart10-Oct-04 11:05 
GeneralAdd dropdownlist to datalist Pin
macsgirl9-Oct-04 6:14
macsgirl9-Oct-04 6:14 
GeneralRe: Add dropdownlist to datalist Pin
Heath Stewart9-Oct-04 7:50
protectorHeath Stewart9-Oct-04 7:50 
GeneralRe: Add dropdownlist to datalist Pin
macsgirl9-Oct-04 8:04
macsgirl9-Oct-04 8:04 
GeneralRe: Add dropdownlist to datalist Pin
Heath Stewart9-Oct-04 11:43
protectorHeath Stewart9-Oct-04 11:43 
GeneralNDoc 1.2 Problems Pin
Kevin McFarlane9-Oct-04 5:12
Kevin McFarlane9-Oct-04 5:12 
GeneralRe: NDoc 1.2 Problems Pin
Colin Angus Mackay9-Oct-04 5:49
Colin Angus Mackay9-Oct-04 5:49 
GeneralRe: NDoc 1.2 Problems Pin
Kevin McFarlane9-Oct-04 6:43
Kevin McFarlane9-Oct-04 6:43 
GeneralRe: NDoc 1.2 Problems Pin
Heath Stewart9-Oct-04 7:41
protectorHeath Stewart9-Oct-04 7:41 
Generalhide form from close button Pin
Mridang Agarwalla9-Oct-04 3:40
Mridang Agarwalla9-Oct-04 3:40 
GeneralRe: hide form from close button Pin
Colin Angus Mackay9-Oct-04 3:56
Colin Angus Mackay9-Oct-04 3:56 
GeneralRe: hide form from close button Pin
Colin Angus Mackay16-Oct-04 6:11
Colin Angus Mackay16-Oct-04 6:11 
GeneralRe: hide form from close button Pin
Anonymous17-Oct-04 0:13
Anonymous17-Oct-04 0:13 
GeneralRe: hide form from close button Pin
Colin Angus Mackay17-Oct-04 1:20
Colin Angus Mackay17-Oct-04 1:20 
Generalwav managing Pin
jeroni_brunet9-Oct-04 3:32
jeroni_brunet9-Oct-04 3:32 
GeneralRe: wav managing Pin
Colin Angus Mackay9-Oct-04 4:07
Colin Angus Mackay9-Oct-04 4:07 

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.