Re: Unicode issue



On Fri, 24 Nov 2006 09:55:14 +0800, "ben" <s06H@xxxxxxxxxx> wrote:

I want to save and read data, and use the function CreateFile(),
WriteFile() and ReadFile(). CreateFile is success, but WriteFile and
ReadFile are fail and the name of the file that i have created is pane. And

I can't follow the details, but I think you have three choices

1) If you are creating these files just for use within your programs,
WriteFile and ReadFile should work fine by themselves. WriteFile will
put all the bytes in the file, and ReadFile will read all the bytes
exactly as written. All the code in your program will treat those
bytes as UNICODE characters, and everything should work

2) You can create and use ASCII files. This requires translating all
the characters to ASCII as they go out, and then back from ASCII as
they come back. Other programs will be able to read these files also.

3) If you really want to create UNICODE files that other programs can
read, you need to preface each file with a BOM (Byte Order Marker).
For more info, use google
(http://groups.google.com/advanced_group_search) to look up
bom
in this newsgroup.


i create the files with the same name could not be covered but two.Now, i
don't know how to solve the issue.


"Ulrich Eckhardt" <eckhardt@xxxxxxxxxxxxxx>
??????:aa8g34-bs9.ln1@xxxxxxxxxxxxxxxxxxxxxxxxx
ben wrote:
USING TOOL: EVC++ 4.0 (SP2)
I want to write a no Unicode programm, and i don't use the Unicode
functions. But i don't know how to set the setting in my tool. Please
tell
me how to develop a no Unicode programm and how to define beforehand the
Unicode in the programm.

Doesn't work, from my experience. Many of the FunctionA versions are not
available in CE. However, other parts that are not TCHAR based work just
as
always. What are your problems?

Uli



-----------------------------------------
To reply to me, remove the underscores (_) from my email address (and please indicate which newsgroup and message).

Robert E. Zaret, eMVP
PenFact, Inc.
20 Park Plaza, Suite 478
Boston, MA 02116
www.penfact.com
.



Relevant Pages

  • Re: Unicode issue
    ... The following code can not get the printable characters. ... WriteFile() and ReadFile. ... ReadFile are fail and the name of the file that i have created is pane. ... If you really want to create UNICODE files that other programs can ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: Unicode issue
    ... My mother language is not English, sorry for my poor English. ... WriteFile() and ReadFile. ... ReadFile are fail and the name of the file that i have created is pane. ... If you really want to create UNICODE files that other programs can ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: Unicode issue
    ... So, I think maybe the Unicode issue, and also ... could you please give me some code about the ReadFile and WriteFile? ... ReadFile are fail and the name of the file that i have created is pane. ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: Processing ASCII Messages through Serial Port
    ... What i'd like to know is how i convert the ASCII message that i receive into a CString format so that i can read the contents? ... directly into a CString with ReadFile. ... To WriteFile from a CString pass string as the buffer to write. ...
    (microsoft.public.vc.mfc)
  • Re: can not delete excutable in Pocket PC [or WinCE]
    ... For serial I/O, as we've discussed in this group previously, you can close ... WriteFile() operation under way on the port to complete with an error. ... when it gets an error back from ReadFile or WriteFile, ...
    (microsoft.public.dotnet.framework.compactframework)

Quantcast