LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Minimize button in CVI 6.0

Wehn my application is running, and you click on the minimize button, not only do you have the button in the task bar, but there is also the minimized "title bar" I guess you would call it with its' minimize, maximize and close buttons in it. This normally sits right above the start button on the task bar if this is the only application you are running.

Is there any way to make it so when you minimize the panel you only have the one button in the task bar, and not the minimized title bar sitting above the start button?
0 Kudos
Message 1 of 22
(6,905 Views)
Make sure that option "Has Taskbar Button" in Edit Panel(UIR) >> other attribute is disable... and try again.
0 Kudos
Message 2 of 22
(6,904 Views)
Yes it is disabled. When you enable that, that just gives you an extra button on the task bar itself. I'm talking about when you minimize the your panel, and you get the minimized title bar right above the task bar with the minimize maximize and close buttons still visible.

I have attached a picture of what I am talking about. I am talking about the minimized title bar directly above the start button that says log in. This is what happens when I minimize my Panel. When I minimize I only want to have the button directly on the task bar.
0 Kudos
Message 3 of 22
(6,906 Views)
OK I didnt understand... I to it like that :

case EVENT_GOT_FOCUS:
SetPanelAttribute (panel, ATTR_TITLE, "MAIN");
break;
case EVENT_LOST_FOCUS:
SetPanelAttribute (panel, ATTR_TITLE, "");
SetSystemAttribute (ATTR_TASKBAR_BUTTON_TEXT, "MAIN");
break;

Hope it helps...
0 Kudos
Message 4 of 22
(6,907 Views)
That just removes the title from the title bar. I'm trying to get the little title bar to disapear. What is wierd is if I click on the taskbar button itself after I minimize, the little title bar over the start menu goes away. I want this to happen the moment I minimize.
0 Kudos
Message 5 of 22
(6,907 Views)
sarge,

Attached is a small sample application that I think does what you want (because I had to test this to make sure it worked!)

When you run a CVI application, the main function (or WinMain) has its own window that shows up in the taskbar (the "application-level" taskbar button), as well as the per-panel taskbar buttons for each UIR/panel. I've found that the best way to handle taskbar button problems like the one you're facing is to just go ahead and hide the application-level taskbar button, and show the taskbar button for the panels instead (turn on the "Has Taskbar Button" checkbox for the panels).

The way to hide the the application-level taskbar button is:

SetSystemAttribute (ATTR_TASKBAR_BUTTON_VISIBLE, 0);


David McClell
and
National Instruments
Message 6 of 22
(6,908 Views)

Message Edited by Nick009 on 05-18-2005 02:50 PM

0 Kudos
Message 7 of 22
(6,855 Views)

Hello, I exactly wanted to have the same behaviour and also to see only one task bar button, that's why I used:

SetSystemAttribute (ATTR_TASKBAR_BUTTON_VISIBLE, 0);

The problem is, that when using this function, my application disappears from the Windows Task Manager application window.

Is there another way to hide the the application-level taskbar without removing the application from the Windows Task Manager  application list?

Please help, the fact that my program is no more recognized from Windows as an application is a big problem for me!!!

Rac

0 Kudos
Message 8 of 22
(6,597 Views)

Hi RAC,

We are looking into this further with the developers of CVI.  You are able to make suggestions directly to R&D. 

As a side note, I would mention that the UIR is available in Processes tab of the Task Manager. 

Also, you can

  1. Disable "Has Taskbar Button" and set the taskbar button to visible.
  2. Do 1. and Disable Minimization from Edit UIR (One can still minimize by clicking the taskbar button).
Cheers,

David Goldberg
National Instruments
Software R&D
0 Kudos
Message 9 of 22
(6,570 Views)

Hello David!

The problem with solution 1 is the weird behavior that Sarge describes. That's why I enabled "Has Taskbar Button" and set the taskbar button visible state to FALSE...

The problem with solution 2 is that I cannot minimise my main window without minimising all the opened windows from the application.

Please inform me as soon as you have a solution...

Best Regards

Rachel Bach

 

0 Kudos
Message 10 of 22
(6,522 Views)