|
1. I'm looking for guidelines for creating a COM+ application using VC++ 5.0. I have knowledge of idl, ATL, VC, & COM.
Not sure on how to build this knowledge into a COM+ Application in Windows2000.
Is there any good documentation available.
2. Is MFC Dead, is it still supported?
Gerry.
|
|
|
|
|
I forget how to get the language info in Windows. :-P Thanks for any help.
|
|
|
|
|
Use MSDN.
MSDN LIbrary
Platform SDK
Base Services
Internation Features
National Language Support
National Language Support Functions
Its all described here
Its not MFC, but you don't need MFC to do this.
Stephen Kellett
|
|
|
|
|
I have a cformview w/ a control that I'd like to have respond to the enter key. I understand you can use getdlgcode for dialogs, but would I need it for this situation? How would I go about doing this? I searched around but didn't come up with much in my situation. Any leads would be appreciated.
Thanks in advance.
|
|
|
|
|
I need to solve real-time second order differencial equations. Do you know some library I can get to work it out?
Giorgetti Stefano
|
|
|
|
|
Check out http://www.maplesoft.com/
Maple is a symbolic math engine that will do what you need. I don't know if they sell the library to end-users or not. ( i know that they sell it with MATLAB...)
|
|
|
|
|
Hi
I have a function in my document class that returns a reference to a Ctypedptrlist.
I wan't to access this list(function)in my own class derived from Cobject.
I have tried to use a Getdocument function but it won't work.(how to do this?)
I can't include the document header file in my class.
If i can't access the function in my document class, then I need to make a static CList. I have tried
but I can't seem to get it working.(how to do this?)
as you probably can see (by my problems) I'm quite new to c++ and MFC, and I'm working on my
first program.
Svein Ravndal
|
|
|
|
|
Hi again,
let me tell you the information again. I have a touchscreen, touchscreen driver, and a MFC program for touchscreen. This MFC program gets data from touchscreen through driver. And driver gets info. from touchscreen through COM port (translate the hex number from COM to something else). Make sense?
Now, MFC programming is talking about events or messages. If there is no message, MFC can do nothing, right? I have to get the notification of ERROR TOUCH. However, then ERROR TOUCH happened, no message sends from Driver to message queue , and MFC keeps silent.
My question is: is there any way to get this data directly from COM port, or do you have any suggestion so that i can get the ERROR TOUCH?
Thanks.
|
|
|
|
|
Well, yes.. you can get the data directly from the COM port, but you'll have to know the format this data uses, and you'll have to disable the driver, since it will own the COM port exclusively.
COM ports act just like files, you open them as files and read from them like files. There are a few functions used to manipulate COM ports that do not apply to files though, these functions are SetCommState and SetCommTimeouts and they take the same file handle used in reading and writing to a file.
|
|
|
|
|
Do you have some sort of interface to the driver/lib that you can call at the user level that takes a window handle identifying the window to receive the messages?
You could probably pass AfxGetApp()->m_pMainWnd->m_hWnd as the handle.
Just a thought... not quite sure I understand the setup.
|
|
|
|
|
Hmmm - maybe I misunderstood - you are wondering how to trap a windows message that MFC does not recognize in the class wizard etc - i.e. not a standard windows message.
You can use the message map macros - there are several, like ON_MESSAGE, ON_COMMAND, etc. They presuppose functions with particular signatures, so read the docs on these.
For example, I have a class that changes state - and it is separate from a dialog that needs to be updated when the state changes. Instead of making the class 'know' about the dialog, I define a new message that the class can send, and handle it in the dialog by adding a handler and a message map macro.
I use the ON_MESSAGE macro here:
BEGIN_MESSAGE_MAP(COPCSim1Dlg, CDialog)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_MESSAGE(WM_STATUSCHANGE, OnStatusChange)
END_MESSAGE_MAP()
Then define your handler according to what the macro expects - in this case:
afx_msg LRESULT OnStatusChange(WPARAM, LPARAM);
When something changes, I let the dialog know with PostMessage:
PostMessage(theApp.m_pMainWnd->m_hWnd, WM_STATUSCHANGE, 0, SESSION_CLOSED);
In your case, you'll need to read the docs I guess to figure out what macro you can use. I'm assuming that the driver puts the message in the systems raw input thread and it gets to your window without you having to subscribe to it - and it may even be a standard message with the ERROR TOUCH as one of the parameters by the time it gets to your app - again, you'll need to read the docs. But thought this might help.
For testing, you can add code to PretranslateMessage or DefWindowProc to see if the message is getting through. The macros are a bit more MFC like, and you don't need Class Wizard to use them.
|
|
|
|
|
I have a single CListCtrl object on 5 property pages (5 objects). When I minimize my app and then restore it the objects are re-displayed and refreshed as expected. Here is the problem, if I click on any single entry within the CListCtrl object (any one of the objects on any one of the propery pages) and then minimize the app, when the app is restored the CListCtrl object is not displayed. If I click on another property page and back the CListCtrl object is displayed as I expect. I am stumped.
Dedication to the job at hand.
|
|
|
|
|
Hi, i want to add a button next to the buttons at the right top corner (nex to close, minimize, maximize) and use it as "minimize to tray", like in getright.
thanks a lot!
|
|
|
|
|
subclass the mainframe window and add a function to process the button click as well as adding the button in the draw mode
---
"every year we invent better idiot proof systems and every year they invent better idiots"
|
|
|
|
|
Hi,
1. gethostbyname() retrives the host information from host database.what is host database? Is it some file stored on local mechine? How it is giving the information? Or It will query DNS server?
If so, what is the funda behind this?
2. what is DNS server? where can i get more info?
Thanks in advance,
Koteswara Rao, Perumalla
theearth1947@yahoo.com
|
|
|
|
|
Host information can be obtained by several ways:
1) The HOSTS file on the local machine.
2) DNS server response
3) WINS server response
4) DHCP server response
The DNS WINS and DHCP servers are all configured in your local network properties.
|
|
|
|
|
How to get the nearest NameServer programatocally. I tried to broadcase a message on port 53 using 255.255.255.255 as IP. No response . Why ?
Anita Eugene
|
|
|
|
|
I tried to have a common variable which would be modified by more than one function of an interface in COM.
But I found that any modification on the variable by one function was not reflected in the other function.
Why is it so?
Is there any way of having a common variable?
Thank You.
Yamuna.E.
Yamuna.E.
|
|
|
|
|
I tried to have a common variable which would be modified by more than one function of an interface in COM.
But I found that any modification on the variable by one function was not reflected in the other function.
Why is it so?
Is there any way of having a common variable?
Thank You.
Yamuna.E.
Yamuna.E.
|
|
|
|
|
I tried to have a common variable which would be modified by more than one function of an interface in COM.
But I found that any modification on the variable by one function was not reflected in the other function.
Why is it so?
Is there any way of having a common variable?
Thank You.
Yamuna.E.
Yamuna.E.
|
|
|
|
|
Are you trying to use the COM interfaces from multiple programs? If so, the problem is that each COM object is created seperately for each program (usually). If you're talking about the same program, then it could be Thread Local Storage issue.
A single object will generally share it's data between the interface functions.
|
|
|
|
|
Hi,
I am trying to use the COM interface from multiple programs as you said.Is there any way in this case to have a common variable?
THANK YOU.
Yamuna.E.
|
|
|
|
|
Hi,
I am trying to use the COM interface from multiple programs as you said.Is there any way in this case to have a common variable?
THANK YOU.
Yamuna.E.
|
|
|
|
|
We have developed an Acive X in VC++ and the graphical interface in VB.
We would like to debug both applications at the same time to see how they interact with each other. How can we do it?
There is no problem to debug 2 VC++ applications but not 2 apps from different developing environments.
Thanks in advance
|
|
|
|
|