Click here to Skip to main content
15,891,513 members

Comments by Doc Lobster (Top 29 by date)

Doc Lobster 18-Oct-16 14:49pm View    
Reason for my vote of 3 \n To Hell with scopes I say. Any real programmer will gladly remember the glorious days of goto. Needless to say, I would have a talk with anyone within my scope that would dare to use a goto. Once, not twice.
Doc Lobster 19-Nov-12 13:01pm View    
Yes, I'm aware of COleDispatchException*. It is derived from CException, so catching CException will do the job.
Doc Lobster 19-Nov-12 6:21am View    
Hi, thanks for your answer. LogString takes const CString& as parameter and the string is concatenated properly. Anyway, I found the solution, I'm calling Delete twice ...
Doc Lobster 3-Nov-12 5:37am View    
Hello Pete, thank you for your answer. I tried replacing the standard tab control with the one from the Cinch v2 demo, however the exception stays the same.

I also tried to reproduce the problem with a simple (no tab header and content templates) code-behind demo project, which didn't show the exception. The idea that the view is destroyed on a tab change sounded a bit strange to me, so I added two non-bound radioboxes in a tab of that demo project. Their values are kept after tab switching away an back.

As I already spent quite some time on this, I'm now ready to avoid this by switching to another UI design. :(
Doc Lobster 9-Feb-12 9:04am View    
Deleted
I see the point now. You want to do the comparison through the base class only (BaseClass::equals) which would bring you in a typical double dispatcher situation. However, thats not possible to implement since the child class is a template and you cant have virtual method templates. In that case I would do mostly the same as in your solution with the only difference of using typeid/type_info.