Difficulties with dynamically created dialogs
-
Hey all, First off i'll try and give you as much background wihtout dragging on too much. I wanted to create a custom I/O control for one of my applications. Basically it looks like an altimeter. It has an analog dial, an led section and a buttons section. Still with me? So i wrote a CPanel Class that allows the end user to either create an input or an output control by using some functions to change its behavior. Now I need six of these bad boys on the screen at once. This control is graphic intensive(lots of bitmaps) and it sucks GDI resources down by a sizeable amount but we are still in the green. Now when i use the Create(..) functions to get 6 of these on the screen, at first it looks like i get them however, just playing with the control elements tells you otherwise. I get 3 of my controls that function normally and then I get 3 "ghost images" of my control. These ghost images are basically like a bitmap of what the control should be but they are not active. They dont respond to any input, they dont show up in the tab order..they are essentially not there. This is driving me nuts...any ideas? All six panels are sharing the same resources.CPanel is comprised of 3 other dialogs. CLedPanel, CDisplay1 and CDisplay2. CDisplay1 and CDisplay2 are switched based on what mode oyu are in. Ony one will be displayed at a time. I know this is a shot in the dark but i had to try thanks for any input you may have :confused: "DWORD my man!"
-
Hey all, First off i'll try and give you as much background wihtout dragging on too much. I wanted to create a custom I/O control for one of my applications. Basically it looks like an altimeter. It has an analog dial, an led section and a buttons section. Still with me? So i wrote a CPanel Class that allows the end user to either create an input or an output control by using some functions to change its behavior. Now I need six of these bad boys on the screen at once. This control is graphic intensive(lots of bitmaps) and it sucks GDI resources down by a sizeable amount but we are still in the green. Now when i use the Create(..) functions to get 6 of these on the screen, at first it looks like i get them however, just playing with the control elements tells you otherwise. I get 3 of my controls that function normally and then I get 3 "ghost images" of my control. These ghost images are basically like a bitmap of what the control should be but they are not active. They dont respond to any input, they dont show up in the tab order..they are essentially not there. This is driving me nuts...any ideas? All six panels are sharing the same resources.CPanel is comprised of 3 other dialogs. CLedPanel, CDisplay1 and CDisplay2. CDisplay1 and CDisplay2 are switched based on what mode oyu are in. Ony one will be displayed at a time. I know this is a shot in the dark but i had to try thanks for any input you may have :confused: "DWORD my man!"
I'd use Spy++ first to look at 'ghost images'. Are they real windows? Style bits set correctly? Do they receive any messages? etc. Tomasz Sowinski -- http://www.shooltz.com.pl
-
I'd use Spy++ first to look at 'ghost images'. Are they real windows? Style bits set correctly? Do they receive any messages? etc. Tomasz Sowinski -- http://www.shooltz.com.pl
Tomasz, I've already tried that but it has led me nowhere. If you use spy++ on it there is nothing there. It recieves no messages, has no window, etc. The creation for each of the six windows is the same except for the coordinates and a different id. I do not understand why it would stop working after the 3rd instance of that CPanel class. I stepped through the Creation of the window and everyhting seems normal.It is a window and has a valid handle. Its just when the windows finally get painted there is nothing there. I am really lost here.....but thank you. Nice screensaver BTW Regards, Eric "DWORD my man!"