Click here to Skip to main content
15,921,371 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Changing languages ! Pin
Konstantin Vasserman28-Dec-01 12:43
Konstantin Vasserman28-Dec-01 12:43 
GeneralSQLSvr2000 and returned FOR XML AUTO _bstr_t Pin
28-Dec-01 7:05
suss28-Dec-01 7:05 
GeneralBreakpoint problem----howto use it in a loop Pin
Charles Liu28-Dec-01 6:58
Charles Liu28-Dec-01 6:58 
GeneralRe: Breakpoint problem----howto use it in a loop Pin
James R. Twine28-Dec-01 7:09
James R. Twine28-Dec-01 7:09 
GeneralRe: Breakpoint problem----howto use it in a loop Pin
Todd Smith28-Dec-01 13:34
Todd Smith28-Dec-01 13:34 
GeneralRe: Breakpoint problem----howto use it in a loop Pin
Nemanja Trifunovic28-Dec-01 7:15
Nemanja Trifunovic28-Dec-01 7:15 
GeneralGetDeviceCaps problems... Pin
Braulio Dez28-Dec-01 6:05
Braulio Dez28-Dec-01 6:05 
GeneralLoading a string from a binary file Pin
James Bird28-Dec-01 5:34
James Bird28-Dec-01 5:34 
I am having troubles loading a string from a binary file. My original problem was that it the string had wierd characters on the end when I was using this code (I am not using MFC):

HANDLE hFile = CreateFile(szFN, GENERIC_READ, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);

DWORD read = 0x00000000;
TCHAR szTest[9];
ReadFile(hFile, &szTest, 9, &read, NULL);

I realised that if I let 'szTest[9] = NULL', there would be no wierd characters at the end and it worked. However, when I do something like,

if (szTest == "BLABLABLA")
{
MessageBox(NULL, "It Worked", "", MB_OK); // Lets me know that it worked!
};

even though "BLABLABLA" is correct it doesn't recognise it. Is it because there is a NULL character now on the end (szTest[9])?

Any help would be greatly appreciated,


James Bird - birdjames@bigfoot.com
GeneralRe: Loading a string from a binary file Pin
Nemanja Trifunovic28-Dec-01 5:44
Nemanja Trifunovic28-Dec-01 5:44 
GeneralRe: Loading a string from a binary file Pin
Daniel Lohmann28-Dec-01 5:53
Daniel Lohmann28-Dec-01 5:53 
GeneralRe: Loading a string from a binary file Pin
James R. Twine28-Dec-01 7:06
James R. Twine28-Dec-01 7:06 
GeneralTrying to get the size of A3... Pin
Braulio Dez28-Dec-01 4:35
Braulio Dez28-Dec-01 4:35 
GeneralRotating shapes Pin
bhat_adarsh28-Dec-01 4:24
bhat_adarsh28-Dec-01 4:24 
GeneralRe: Rotating shapes Pin
567890123430-Dec-01 1:08
567890123430-Dec-01 1:08 
GeneralMigrating from Win9x to Linux - PLEASE HELP! Pin
Sergei Yevseyev28-Dec-01 4:16
Sergei Yevseyev28-Dec-01 4:16 
GeneralRe: Migrating from Win9x to Linux - PLEASE HELP! Pin
Matt Newman28-Dec-01 4:31
Matt Newman28-Dec-01 4:31 
GeneralRe: Migrating from Win9x to Linux - PLEASE HELP! Pin
Nemanja Trifunovic28-Dec-01 5:25
Nemanja Trifunovic28-Dec-01 5:25 
GeneralRe: Migrating from Win9x to Linux - PLEASE HELP! Pin
Fazlul Kabir28-Dec-01 5:30
Fazlul Kabir28-Dec-01 5:30 
GeneralRe: Migrating from Win9x to Linux - PLEASE HELP! Pin
Ravi Bhavnani28-Dec-01 5:31
professionalRavi Bhavnani28-Dec-01 5:31 
GeneralRe: Migrating from Win9x to Linux - PLEASE HELP! Pin
Tomasso7-Jan-02 7:10
Tomasso7-Jan-02 7:10 
Generalaccess CRecordSet from another class Pin
jafrazee28-Dec-01 2:43
jafrazee28-Dec-01 2:43 
GeneralRe: access CRecordSet from another class Pin
Carlos Antollini28-Dec-01 3:05
Carlos Antollini28-Dec-01 3:05 
GeneralRe: access CRecordSet from another class Pin
jafrazee28-Dec-01 3:46
jafrazee28-Dec-01 3:46 
GeneralRe: access CRecordSet from another class Pin
Carlos Antollini28-Dec-01 5:07
Carlos Antollini28-Dec-01 5:07 
Questionhow can i DRAW in CVIEW:OnInitialUpdate() function? Pin
AnonymousBabe@usa.net28-Dec-01 2:08
AnonymousBabe@usa.net28-Dec-01 2:08 

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.