coderanger
02-12-2007, 04:46 AM
Hi Gang,
This is probably a question for the more experienced C/C++ programmers
here..
There's a game/simulator I play every now and again, and it has files that
can be edited by the end user to accomplish certain things. So, I thought
it would be nice to create a program that could create these files so it
would be faster and easier for me to do what I want to do.
Anyway, so I create my little application in AMS6, everything seems to
work great, except the files I create and import into the game/sim give
me the old file is corrupt error message, then the game/sim shuts down.
Well, it took my brain a little while to kick in, but it finally dawns on me
that the files that we can import and use for this game need to be in
Unicode format, and I think "Well, my little app is not exporting in Unicode."
So, after doing about a weeks worth of searching and research, I have come
to the conclusion that I need to be using the Windows kernel32.dll dynamic
link library to export my files in Unicode format.
The closest I can come to finding any useful information on using the
functions in this file (I think specifically CreateFileW) are from this website:
http://source.winehq.org/WineAPI/CreateFileW.html
http://source.winehq.org/WineAPI/kernel32.html
That's really as far as I can get. I cannot find a website or information for
the really dumb (speaking of myself) to understand how in the world to
implement this into my AMS6 program and export a file in Unicode format.
Is there anyone kind enough to give me a small example of getting this to
work in my app?
Any help would be greatly appreciated.
Patrick
This is probably a question for the more experienced C/C++ programmers
here..
There's a game/simulator I play every now and again, and it has files that
can be edited by the end user to accomplish certain things. So, I thought
it would be nice to create a program that could create these files so it
would be faster and easier for me to do what I want to do.
Anyway, so I create my little application in AMS6, everything seems to
work great, except the files I create and import into the game/sim give
me the old file is corrupt error message, then the game/sim shuts down.
Well, it took my brain a little while to kick in, but it finally dawns on me
that the files that we can import and use for this game need to be in
Unicode format, and I think "Well, my little app is not exporting in Unicode."
So, after doing about a weeks worth of searching and research, I have come
to the conclusion that I need to be using the Windows kernel32.dll dynamic
link library to export my files in Unicode format.
The closest I can come to finding any useful information on using the
functions in this file (I think specifically CreateFileW) are from this website:
http://source.winehq.org/WineAPI/CreateFileW.html
http://source.winehq.org/WineAPI/kernel32.html
That's really as far as I can get. I cannot find a website or information for
the really dumb (speaking of myself) to understand how in the world to
implement this into my AMS6 program and export a file in Unicode format.
Is there anyone kind enough to give me a small example of getting this to
work in my app?
Any help would be greatly appreciated.
Patrick