|
Smartcard reading doesn't use ports.
Maxwell Chen
|
|
|
|
|
See CString::Mid() , if you're using MFC. Use something like boost , if you are on plain C++. AFAIK, you've been trying to "solve" this problem since 4th March 2008[^]. Sadly, you're still on it.
savitri wrote: tell me VC++ reference books
From the déjà vu experience, I can tell that you don't even know C. Please start from C, if you don't want to be a code monkey.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
Rajesh R Subramanian wrote: AFAIK, you've been trying to "solve" this problem since 4th March 2008[^]. Sadly, you're still on it.
Now she's even trying to operate a smartcard reader to access a smartcard!
Maxwell Chen
|
|
|
|
|
in this we use port to connect reader ok. i am not getting the function for finding the middle value.please help me out.
thanku,
savitri
|
|
|
|
|
CString class has a Mid method.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
but that mid function is like this Mid(int,int) ok that y i am asking how can i use to it and wt is the function for conversin please help me out.
|
|
|
|
|
People using TXT SPK on the forums must be taken out to an open ground and whip-splashed severely on their bare bodies with chinese bamboo.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
Rajesh R Subramanian wrote: People using TXT SPK on the forums must be taken out to an open ground and whip-splashed severely on their bare bodies with chinese bamboo
So, I'm the bad guy!
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
Beacuse it is a method of the CString class.
VB6
val(Mid("USB1",4))-1
translates to
CString str = _T("USB1");
_tstoi(str.Mid(3))-1;
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
A 5, for your patience man.
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
: error C2065: '_tstoi' : undeclared identifier
CString str = _T("USB1"); i used this in Dlg.cpp class and that is also the same class only so it is giving error. please reply me.
thanku in advance,
savitri
|
|
|
|
|
why don't u try str.getAt(3);
|
|
|
|
|
Have you included TCHAR.h ?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
Iam a Jr. VC++ Developer. Iam working on Dialog based application(MFC). My application is almost completed. It is typically a Billpayment sort of application. It works Fine for few Transactions but starts Slowing down and finally get hanged if i made several transaction of same flow.I have to restart my application again and so on. I cant find out the exact reasons of this. Iam created all my object statically. Is there any problem regarding statically or Dyanamically object creation. Please Tel me the reason, so that i get rid off soon.
|
|
|
|
|
See here.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
CPallini wrote: See here.
Too bad of you man, did you not see it's urgent?
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
Rajesh R Subramanian wrote: did you not see it's urgent?
I saw it. My answer was very quick indeed.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
1. Do you use threading in your application?
2. Do you properly release the resources allocated?
Maxwell Chen
|
|
|
|
|
No Sir Iam Not using Threading here.
Can u plzz tel me how to release the resource and what type of resource there could be..Iam using Dialog based application..iam using number of dialog here for my purpose..Can dynamically creation of object or smart pointers solve this problem..plzz..
|
|
|
|
|
dheka wrote: Can u plzz tel me how to release the resource and what type of resource there could be..
Such as variables:
CMyConnection* pC = new CMyConnection();
delete pC;
Or Windows API functions:
HANDLE h = CreateEvent(...);
CloseHandle(h);
Maxwell Chen
|
|
|
|
|
No Sir!!! Iam not Creating Objects Dynamically.. and remaining resources iam properly deallocating..
So tell me should i create Dialog Object Dynamically so that i can delete memory explicitly...
iam creating new dialog like this,,
CMyDialog ss;
ss.Domodal();
and further iam not doing any thing for memory deallocation. So how i can deallocate meomory for Statically created objects ..
|
|
|
|
|
Sounds like the other cause ...
Maxwell Chen
|
|
|
|
|
Sir Can i use Smart Pointer for proper releasing of resource like memory..
|
|
|
|
|
dheka wrote: Sir Can i use Smart Pointer for proper releasing of resource like memory..
Yes of course. But remember that smart pointers can also fall into unsmart under some specific conditions.
Your situation may not necessarily be the resource free issue. I suggest you to profile the performance of your code (function level). In other words, to benchmark how long it takes for each major function implementations to execute.
Maxwell Chen
|
|
|
|
|
Ok Sir..Thanks for ur Kind replys..
|
|
|
|