|
ForNow wrote: ...this CAysncSocket type object as a Seprate thread...
See here.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
Thankx
A couple questions is passing a object as a parm dangerous only to C"Async"Socket
objects
but if were to to pass a object if another type it would work say um.... CEvent
Object
BTW
the MainFrame has a similar Concept
After Accetping a connection there is a GiveSocket API to give the socket to the
Subtask or Subthread
|
|
|
|
|
or ??? is any object that has am Attach() method dangerous to pass across thread boundries
|
|
|
|
|
ForNow wrote: ...is any object that has am Attach() method dangerous to pass across thread boundries
See here.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
much thankx
Let me a) repeat to see it if I understand
b) say how I will implement my solution
First
After creating the Object e.g. CAsyncSocket mytcpip;
attach(socket) will actually populate the Object this is typically
a first time thing
::FromHandle will get a pointer to the Object CWnd* etc...
My implementation for my TCP/IP connections
I will create the CAsyncSocket object in the Dialog Class method
Create the socket
then Create a User Interface Cwindthread (with a message pump, no need for a Cdialog class all I need is something that has a message pump)
which will attach(socket)
and do send and receives
And let My Cdialog class know when I receive data
thankx again
|
|
|
|
|
I m referring to a tutorial book of database using ADO.
The problem is i have to get the result displayed in CListCtrlEx for which the tutorial book says i have to copy three files-CtrlExt.cpp, CtrlExt.h,
and CtrlExt.Inl-from the DAOVIEW example into the source code directory for my application.
I serached for these 3 files in the VC98\MFC\SRC\
But i could find the files there...so i even tried to download the files to the above folder and then added them to my project but still i get the
error : CListCtrl undeclared identifier
error : Cannot open the file CtrlExt.h
How do i use this CListCtrlEx class so that i can add columns and data to the client application ?
BackGround : Its a MDI with ListView as Base class .
Kindly tell me stey by step process to get rid of this error and use the CListCtrl class.
I m badly stuck here...Help!!
Appreciate your time.
Thanking in advance.
|
|
|
|
|
You've got several things going on here. Trying to do them all at once might not be your best bet. I would suggest first getting familar with a list control (in 'report' mode) and the related CListCtrl class. When you are able to add columns and items, then start looking at the CListCtrlEx class and the extra features that it offers (you may find it altogether unnecessary). That class can be found here.
There's also the issue with reading records from that database. That is an exercise in itself. You might want to start here.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
I m already through the CListCtrl class .With those classes i simply created a OnCreate Message Hnadler and created a ListView .There i had to add columns using InsertColumns()...Y here for CListCtrlEx do i have to add files to my project and still it is not working.As a matter of fact i do not even have the files mentioned above, in my DAOVIEW example.
Why is it so ?
modified on Wednesday, May 13, 2009 1:37 AM
|
|
|
|
|
I am using VS2008 on XP and I'm having trouble with the debugger fully terminating the process of my application after I am done debugging. Basically, the machine still thinks the exe is running so that I or the compiler cannot delete the file, leaving me unable to recompile. The problem seems to happen at completely random times and I am not able to reliably reproduce it. I have run ProcessExplorer and can see when the devenv starts the process and seems to release it. It does not appear to be running anywhere else.
The program is fairly small (few hundred lines) and deals with writing a few things to the registry and logging events with the NT event log.
I'm recently upgraded to VS2008 (new program though) and have never had this problem before. Any insights or troubleshooting tips would be appreciated.
Thanks,
Dustin
P.S. Rebooting obviously fixes the problem, but I can't afford to do that 10 times a day.
|
|
|
|
|
Are you able to delete the file manually in such situations....?
|
|
|
|
|
No, it was completely locked.
However, I just figured out the problem. Apparently, after you open an event created be the application the event viewer opens the exe to access the message resources in the file. I didn't figure this out before because simply having the event log open doesn't cause the problem, you must open the actual event. The event viewer remains in control of the exe until the whole thing is closed, not just the event. I was sure I tried that before but I guess I didn't.
Thanks anyways,
Dustin
|
|
|
|
|
Coordinate that receive in nmea protocol is doing matching to GoogleMap
Solve error
source
.
|
|
|
|
|
Good luck with that.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
You have to realise that nobody here understands your posts. Learn some English or try a programmers forum in your native language.
Also, nobody is going to download your source code and "solve the error".
|
|
|
|
|
Is it a test of your new Random Word Generator application?
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
[My articles]
|
|
|
|
|
여기 아무도이 문제를 이해하는 것이다. 귀하의 네이티브 언어에 일부 다른 포럼보십시오.파일을 다운로드 후, 아무도 여기를 해결하는 것입니다.
죄송합니다!
Google translate
|
|
|
|
|
Hi all,
I'm trying to import in my MFC project some custom form user control made with c#. Now if I try to import them in a dialog following the msdn tutorial I have no problem. Instead If i try to import them in a cpanedialog I'm not able to initialize the control (if I look at the control value in debug mode it is always NULL). Now my question is:
It is possible to host the control or it is the same situation of the dialogbar in which as MSDN said can not be host form control?
PS To host the control I have included the clr support than I have made these three passage:
1) in header file I have add CWinFormsControl<mbrPropertyGrid::PropertyGrid> m_ctrl;
2)then to the cpp file of the panedialog I have added a DDX control where IDC_CTRL2 is a static tex used as placeholder DDX_ManagedControl(pDX, IDC_CTRL2, m_ctrl);
3) at least in a specific method I use the control
|
|
|
|
|
Excuse me If i redo my question. Please help me, if the problem is that the question is not clear me, tell me that and I will try to explain it better. Thank you in advance
|
|
|
|
|
Do you have the latest "Feature Pack" for Visual Studio 2008 that includes CMFCPropertyGridCtrl and CPaneDialog ?
This signature was proudly tested on animals.
|
|
|
|
|
Yes I have the feature pack installed but the controls provided are too limited...the propertygridcontrol doesn't offer the opportunity to make a tree like control in witch the line with the expansion marquee could locate also another control.
So to overcame this problem I have thought that a solution will be to import a c# control...
|
|
|
|
|
Hi,
I am Vinod. I want to have multiple windows in VC++.These windows should be able to display information receive messages from other PC.
Please reply if any one knows....please//
|
|
|
|
|
vinod shankar k wrote: Please reply if any one knows
Yes, somebody knows.
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
[My articles]
|
|
|
|
|
You could start by using CreateWindow .
Call it as many times as you want.
«_Superman_»
I love work. It gives me something to do between weekends.
|
|
|
|
|
vinod shankar k wrote: These windows should be able to display information receive messages from other PC.
Depending on how many other PCs are involved, you might consider an SDI or MDI application.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
my function f_my() receive identifier
of control, for example
IDC_DATETIMEPICKER1
How do set type of argument?
And how this function to call for execution?
As show - unproperly:
error C2660: 'GetDlgItem' : function does not take 1 arguments
void CADO_MDIApp:: f_my (long identifier)
{
COleDateTime* p1 = (COleDateTime*) GetDlgItem(identifier);
}
|
|
|
|