|
I use NcAPI & Netcard2280 to programm for USB device. How determine a packet is NULL packet when Netcard get packet form host PC
-----------------
conglt
|
|
|
|
|
I've written an application which will use virtual COM port (USB-to-Serial) to communicate with my device. I am using CreateFile/ReadFile/WriteFile functions. It is running fine until one issue found.
With the application open, when (somehow) the USB driver reload, my application fail to perform read/write. Even after I close the application and reopen it, it fails to get the handle.
Why is it happen? Are there anything that my application need to do when the USB driver is re-loaded?
Thanks.
TC
|
|
|
|
|
hi all,
How can i run C++ code in BREW application because brew has it's own function and i want to generate my own function in BREW and pass the string.
and that string i pass another string after click in emulator.can you help me out for that.
Thanks...........
Nitin Dalal.
nitin
|
|
|
|
|
:(CString FilePath;
FilePath = writeFilePath+ DMID + "." + test;
// then FilePath = c:/temp/1234.jpg
objEWFFile.Open(FilePath, CFile::modeCreate | CFile::modeWrite, NULL);
It doesn't work...
How can FilePath change to LPCTSTR ??
|
|
|
|
|
mimimimilaw wrote: It doesn't work...
In what way? What errors do you get? When do you get them, compile time or runtime?
Did you debug your source code?
|
|
|
|
|
You can do this as
CString str="abcd";
const char* data_char = (LPCTSTR) str;
//However you shouldn't be having any errors with opening the file using a CString type filename
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
-- modified at 2:24 Tuesday 20th June, 2006
|
|
|
|
|
CString has a LPCTSTR cast operator, which means you can safely do
LPCTSTR lpStr = (LPCTSTR)oMyCStringObj;
|
|
|
|
|
mimimimilaw wrote: It doesn't work...
How can FilePath change to LPCTSTR ??
What is the type of objEWFFile ??
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
|
Are you sure the // FilePath = c:/temp/1234.jpg path is correct?
check it and try following for opening file.
objEWFFile.Open((LPCTSTR)FilePath.GetBuffer(0), CFile::modeCreate | CFile::modeWrite, NULL);<br />
FilePath.ReleaseBuffer();
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
can you explain for me whats wrong in this code
<br />
CString FilePath;<br />
CString writeFilePath;<br />
writeFilePath=_T("e:\\");<br />
CString DMID;<br />
DMID=_T("123");<br />
CString test;<br />
test=_T("jpg");<br />
CFile objEWFFile;<br />
FilePath = writeFilePath+ DMID + _T(".") + test;<br />
objEWFFile.Open(FilePath, CFile::modeCreate | CFile::modeWrite, NULL);<br />
whitesky
|
|
|
|
|
here i have a problem to access the portnumbers of different applications running in my project
#sankar#
|
|
|
|
|
|
Hi,
Iam writing a ComPort related program. Iam setting the state of the com port using SetCommState(). Iam considering stop bits also. When I use 1 or 2 stop bits , SetCommState is working fine. But when I use 1.5 (ONE5STOPBITS), SetCommState() is not working, i.e its returning 0.
Why is it not working?What changes should I make?
Thank you.
Ayesha
|
|
|
|
|
Hi All,
Once I have seen a plugin in codeproject which helps visual studio 6 to load MSDN on "F1" button press. I just forgot its name. Could you help me to find it out?
SaRath.
"Do Next Thing..."
Understanding State Pattern in C++
|
|
|
|
|
hi,
can anbody tell me which header file i include in C++ when i work on BREW application.I develop Brew set-up and make helloworld project and under that project name i want to build C++ code.I write the code but the error will come and tell me Fatal error with header file.i include "iostream" file but it doesn't work.so which i include in header file.please help me out for that.
Thanks...
Nitin Dalal
nitin
|
|
|
|
|
hi all,
how to restrict the alphabets and numbers in edit box
i cant use the PreTranslateMessage since i need to enable a listbox when i press the key .it will block it .how can it be done .can it be done by subclassing
need help
"Men never do evil so completely and cheerfully as when they do it from religious conviction"
-Pascal
|
|
|
|
|
|
chethu665 wrote: how to restrict the alphabets and numbers in edit box
i cant use the PreTranslateMessage since i need to enable a listbox when i press the key .it will block it .how can it be done .can it be done by subclassing
Check EN_CHANGE and EN_UPDATE Notification messages
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
|
Derive it from (subclass)CMyEdit and override the WM_CHAR.
Regards,
FarPointer
Blog:http://farpointer.blogspot.com/
|
|
|
|
|
CString type = "abcdefghijklmnopqrstuvwxyz";
I only need "defg" in this CString...
How Can I copy it into another CString??
|
|
|
|
|
mimimimilaw wrote: I only need "defg" in this CString...
How Can I copy it into another CString??
Use Find and Mid methods of the CString
Knock out 't' from can't,
You can if you think you can
|
|
|
|
|
THX
|
|
|
|
|
CString ::Right(), CString::Left() may help
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|