473,405 Members | 2,282 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

UNICODE variant of fopen or ofstream to be ANSI compliant.

I need to open an file with an unicode name, and i cannot find an
proper way to do this.

Any help is appreciated.

Thank you,
Mihai.

Dec 8 '05 #1
3 4348

mihai wrote:
I need to open an file with an unicode name, and i cannot find an
proper way to do this.


Try passing the return of c_str() from a wstring to open. It is not in
the current standard but may be in future versions and may or may not
be implemented in your environment.

Dec 8 '05 #2

roberts.n...@gmail.com wrote:
mihai wrote:
I need to open an file with an unicode name, and i cannot find an
proper way to do this.


Try passing the return of c_str() from a wstring to open.


fsteam::open that is.

Dec 8 '05 #3
On 8 Dec 2005 08:44:43 -0800, "mihai" <Mi*********@gmail.com> wrote:
I need to open an file with an unicode name, and i cannot find an
proper way to do this.


You probably need to use a platform-specific function (e.g. Windows
_wfopen).

Best wishes,
Roland Pibinger
Dec 8 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Ames Andreas (MPA/DF) | last post by:
Hi all, besides PyUnicode_(From)|(As)WideChar I haven't found specific support for wchar_t in the python api. Is there a default codec that produces wchar_t* (in a platform-neutral way) or...
1
by: Jaime Montes | last post by:
I have found that adding in the start of the file the character '-1' and '-2' I can read the file as a Unicode, and to write any character I have to write pairs of character so for 'a' I write '0'...
100
by: Roose | last post by:
Just to make a tangential point here, in case anyone new to C doesn't understand what all these flame wars are about. Shorthand title: "My boss would fire me if I wrote 100% ANSI C code" We...
12
by: bingfeng | last post by:
Hi, everyone, Is the following code <CODE> void foo(int n) { int a; ..... } </CODE>
18
by: Ger | last post by:
I have not been able to find a simple, straight forward Unicode to ASCII string conversion function in VB.Net. Is that because such a function does not exists or do I overlook it? I found...
5
by: Norman Diamond | last post by:
Here are two complete lines of output from Visual Studio 2005: 1>$B%W%m%8%'%/%H=PNO$K(B Authenticode $B=pL>$7$F$$$^$9(B... 1>Successfully signed: c:\T The first line means roughly: Doing...
2
by: starffly | last post by:
I want to read a xml file in Unicode, UTF-8 or a native encoding into a wchar_t type string, so i write a routine as follows, however, sometimes a Unicode file including Chinese character cannot...
4
by: Tom Fields | last post by:
Hello! I like to use the XmlTextWriter to write some SVG files. But in some cases, I need the '&' as '&' and not as &amp;. Example: <glyph unicode="&#x4c;"/> Some code-snippet:
6
by: msdnuniv | last post by:
Hello everybody, since days i try to convert Unicode-Strings in VB.NET to ANSI which should be processable in VB6 and converted to unicode again. It should be possible with any codepage, e.g....
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.