ToolBar Button State

Hello,
i am working on the TestStand 4.0 User Interface with C#.
Now i have built a ToolBar under the MainMenu. I can invoke the Commands by clicking ToolBar Buttons, and get the actual state (enable/disable) of most buttons, except Cut/Copy/Paste.
I don't think that the TestStand API or UI provides any method to indicate the custom UI Controls state. My last hope is to catch all WM_LBUTTONDOWN and WM_RBUTTONDOWN messages in the Sequence- and Variable-View. If something editbar is selected, set the Cut/Copy/Paste state to enable.
Have somebody better idea? Thanks!
Regards
MY

Hi, James Grey,
thank you for your reply. English is not my mother tongue language
I have used the ToolStrip in Visual Studio 2005.
I have tried setting a timer with interval of 2000 ms, it worked, but i don't think it is a efficient way. You know, the TS 4.0 is using much memory.
I will try your suggestion (b), it is really a clever solution.
Regards
MY

Similar Messages

  • Issue with custom toolbar button in alv and leave screen

    Hi,
    in one subscreen (say screen 100)i have an alv with custom ADD  toolbar button..so in the user_command event handler ,i call a antoher screen(dialogue)..like if i click on ADD button ,it should display dialogue screen(say 200) and after entering input in dialogue screen i click on CONINUE to retrun to screen 100..problem is for the first time i click on ADD button its working fine ,succesffyuly returned to screen 100...but for the second time i click on add button , i have to click on twice the CONTINUE button to retrun to screen 100..when debuggin i found the user_command event routin is executin twice ..any solution..
    Thanks,
    srini

    Apparently handler is set for every new ALV instance. This you get by executing CREATE OBJECT alv... every time PBO is raised. Ensure you are executing this statement only once duirng program lifetime. Then the system will match event handler only with one ALV instance (executing it once).
    if r_alv is not bound.
       CREATE OBJECT r_alv ...
       SET HANDLER ...
    endif.
    Regards
    Marcin

  • Keeping toolbar button pressed when displaying a popupmenu beneath it

    I have written a custom widget - the drop down button. We can find examples of this widget all over the place - for eg. IE back button, Mail button, JBuilder run button etc.
    The problem is this:
    when the arrow button is pressed I display the popupmenu. Now, I need the button to hold its "pressed" state and appear accordingly while the popup menu is visible.
              arrowButton.addMouseListener(new MouseAdapter(){
                   public void mousePressed(MouseEvent e)
                        showPopup();
    Any ideas?

    Here is your SSCE. Feel free to compile and run it. It will bring up a JFrame with toolbar buttons that show what I was talking about.
    Note that the non popup buttons appear pressed when the mouse is kept pressed on them. Not so for the popup ones.
    I cannot use an actionListener instead of mouse listener while displaying the popups because I need the popup to be visible with the first press of the mouse, not the first release (just like a combo-box)
    import java.awt.BorderLayout;
    import java.awt.event.MouseAdapter;
    import java.awt.event.MouseEvent;
    import javax.swing.JButton;
    import javax.swing.JFrame;
    import javax.swing.JMenuItem;
    import javax.swing.JPopupMenu;
    import javax.swing.JToggleButton;
    import javax.swing.JToolBar;
    import javax.swing.UIManager;
    public class Main3 {
         static JFrame frame = new JFrame("Test");
         static JToolBar toolBar = null;
         * @param args
         public static void main(String[] args)
              try
                   UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
                   toolBar = new JToolBar();
                   toolBar.setFloatable(false);
                   toolBar.setRollover(true);
                   initToolBar();
                   frame.getContentPane().add(toolBar, BorderLayout.NORTH);
                   frame.pack();
                   frame.setSize(800,600);
                   frame.setVisible(true);
              catch (Exception ex)
                   ex.printStackTrace();
         private static void initToolBar()
              final JPopupMenu popupMenu = new JPopupMenu();
              popupMenu.add(new JMenuItem("hello"));
              popupMenu.add(new JMenuItem("world"));
              final JButton button = new JButton("Popup JButton");
              button.addMouseListener(new MouseAdapter(){
                   public void mousePressed(MouseEvent e)
                        popupMenu.show(button,0,button.getHeight());
              final JToggleButton toggleButton = new JToggleButton("Popup JToggleButton");
              toggleButton.addMouseListener(new MouseAdapter(){
                   public void mousePressed(MouseEvent e)
                        popupMenu.show(toggleButton,0,toggleButton.getHeight());
              final JButton nonPopupButton = new JButton("No Popup JButton");
              nonPopupButton.addMouseListener(new MouseAdapter(){
                   public void mousePressed(MouseEvent e)
                        System.out.println("Non popup button pressed");
              final JToggleButton nonPopupToggleButton = new JToggleButton("No Popup JToggleButton");
              nonPopupToggleButton.addMouseListener(new MouseAdapter(){
                   public void mousePressed(MouseEvent e)
                        System.out.println("Non popup toggle button pressed");
              toolBar.add(button);
              toolBar.addSeparator();
              toolBar.add(toggleButton);
              toolBar.addSeparator();
              toolBar.add(nonPopupButton);
              toolBar.addSeparator();
              toolBar.add(nonPopupToggleButton);
    }

  • Photoshop CC Toolbar buttons sticking.. getting stuck on single click

    Toolbar buttons get stuck in dropdown menu with single click... it's extremely irritating especially being in photoshop all day. I have to click the intended tool button twice in order to get rid of the drop down menu options. I realize it should do this when I double click or hold down click.. but not when I simply want to select a tool with a single click.  I've tried everything. Please help!

    Try resetting the tools:
    Also try changing the mouse settings such as double click speed..
    Benjamin

  • Sample script to pop-up txt box on mouse-over on skin toolbar button?

    RH9,WebHelp Pro
    I am completely new to scripting. I have customised a toolbar button in the skin and while it is easy enough to place a hyperlink to be activated on click, I would also like to display a text caption when the user rolls over the button before clicking.
    Can anyone provide or point me to an example of the required syntax?
    Thank you.

    Hi,
    You have to modify the title attribute of the link. The browser will show that text when you hover the link. I believe that WebHelp uses the text of the button as the title.
    If that doesn't work for you, you can use the onMouseOver event to show and hide a tooltip. Check out Walter Zorn's tooltip script: http://edwardsmark.com/proofOfConcept/walterZorn/ It has some good examples of how to set up the script.
    Greet,
    Willam

  • DEEPLY upset w/rapid-fire updates 2 FF & TB. ex: michael b unable 2 update toolbar buttons; w/out them FF/TB just other apps. this method incredibly disconcerting, frustrating, etc. PLZ RECONSIDER METHOD; go back 2 version changes. annoyed w/mozilla, LA

    i've been using [& updating] mozilla FF & TB for years...in large part cause i felt they were the best for my needs, allowed the most functionality...and then became the most attractive with personas. but i found a long time ago, as with most computer applications, to wait till the second version of a new product. this was especially true of mozilla to make sure the add-on developers can keep up.
    the add-ons to FF & TB give me so much more functionality....so much better than any other browsers out there. and then there are the changing personas...too match one's changing moods. [all hail MaDonna and her constantly exquisite & innovated art work.]
    but mozilla has now made continuing this functionality an impossibility by its new horrible rapid update methodology. because MANY DEVELOPERS CAN NOT KEEP UP with this pace of significant change, FF & TB have been become FAR LESS FUNCTIONAL...and thus more & more like other, previously lesser, browsers & email programs out there,
    is this perhaps the clue to go take a look at chrome, safari, opera and other browsers?
    using this "update" methodology, will mozilla become like its predecessor, netscape.....OBSOLETE.
    or, as has happened with so many other software companies including netscape, many of its employees or contributors saw that they could, in fact, do a better job and so started their own companies, as in how mozilla was born.
    we can only hope this will be the case with mozilla: that many of its contributors will band together and divert from the mess that the current mozilla exec team has created.
    oh by the way, ff 3.6.19 has suddenly started to crash more often, which i dont understand. and TB has started to freeze. hmmmmm......???????
    if i changed browsers, i'd sorely miss personas & the many add-ons i use to customize FF & T B...making them it a much more functional than i ever could have hoped for. but each updated takes so much time & effort and so many add-ons are lost each time anyway, i would also lose that functionality anyway with mozilla. so what's the difference? NADA.
    for years i have been an ENTHUSIASTIC SUPPORTER of all things mozilla, encouraging friends and coworkers to install and use it....often going out of my way to install FF & TB for many of them myself.
    but as a result of the current "update" methodology by mozilla, i dont think updating FF & TB is worth it anymore so i stopped updating....both personally and professionally.
    not only have i stopped recommending FF & TB, as the computer tech at an elementary school i no longer update FF or TB on the dozens of our existing computers that i previously installed them on and i no longer install it on our new computers. in fact, because the update situation in terms of add-ons has given some of my people such a headache, i have actually UNINSTALLED FF and TB on some computers...and, horror of horrors, they have actually gone back to microsoft internet explorer than risk what they have just gone thru with mozilla.
    many on our staff are not so computer savvy so they depend on me for my computer advise and assistance.
    each our classrooms has 2-4 computers, plus we have many more in our main offices, resource room, library, etc. we just ordered a 30-laptop mobile computer lab: i will make sure FF & TB are NOT installed on them.
    our entire school campus has just had wi-fi installed. this will allow many on our staff to use their own laptops on campus. i will be discouraging them from installing FF or TB too.
    JUST BECAUSE SOMETHING IS POSSIBLE DOESN'T MEAN IT IS THE RIGHT OR BETTER THING TO DO.
    mozilla's exec team has failed to realize this...and for this reason alone i think they should all be sacked!!
    just as some at netscape thought they could do a better job and formed mozilla, I PRAY some mozilla people will see the LACK OF MERIT in the current mozilla methodology and move out, starting a new browser company reinstating the functionality and sensibility that mozilla once had.
    many developers can not keep up with this either....they also have lives, many of them very busy.
    so this update method is unfair to developers and users. THIS ALL SPELLS INCONSIDERATION BY SMARTY-PANTS MOZILLA EXECUTIVE TEAM.
    another problem at mozilla, getting more and more like evil microsoft in terms of DISALLOWING customer response.. i went to make a comment in another area, it would not even let me UNTIL I "UPGRADED" [if that's what it is] till the newest frustrating version. BOO HISS. BAD FORM MOZILLA
    mozilla looks like it is replicating microsoft's outrageous methodology of updating its products AND treatment of consumers. but even ms doesnt do crazy updating too often. frequency of updating is way too much. OOOPPS....mozilla IS making the oft-hated microsoft look good. who could have thunk it.
    or will mozilla end up going the way of netscape.......oblivion.
    my frustration increases daily with mozilla's repetitious notifications to update to TB 6. not a chance until i can have MY michael b toolbar button add-ons.
    as far as i am concerned the mozilla exec team has gone from stable & reliable to chaotic messiness. SHAME SHAME SHAME.

  • Interactive PDF: Rollover button state no longer working properly  ???

    Okay, what's going on with the Interactive PDFs lately?
    Now all my rollover buttons no longer work properly.  If I have a button that's simply a black arrow, and in the rollover state it's red.
    No matter if I'm checking it out in the latest Acrobat Reader or Pro X, the rollover only works for a brief second..then reverts back to black - the original state.
    This, combined with my latest problem with the show/hide button state, is really becoming a frustrating hassle:
    http://forums.adobe.com/message/3933451#3933451
    Any help would be appreciated.
    I'm running 7.5.1.
    Is this an Acrobat issue?  The button function here seems to work in the InDesign preview mode.

    Hhmmm...I'm actually having this problem even with Adobe Acrobat 9 Professional. Does this make sense?
    Again, I'm creating the document in InDesign CS5 and then building the PDF with  Adobe Acrobat 9 Professional, and the rollover effects don't work in Adobe Acrobat 9, Adobe Reader 9, and Adobe Reader 10.
    I'm a bit new to this process of software not providing its basic touted functionality. Is this the kind of thing where support for this functionality will vary from product to product? I had the same issue with PDF Portfolio -- where all its functioanlity was not supported in Adobe Reader X. If so, perhaps I should simply stick with the classic features of PDFs. Or can I trust, reliability, that going forward, this rollover effect will be supported in all Adobe Reader versions? This is quite an important issue for me as I provide all the documentation for my employer, including customer facing documentation -- and I simply don't know. Any recommendations?

  • Radio button state on region load...

    Is there a way to set the radio button state (click event) on a region load? The default value of 0 (read-only) works when clicked, but doesn't when the page initially loads, and it's like the button click event needs to take place at the region load time. The values are 1 and 0 set statically if that matters, and the hidden value does not get changed when the radio button with the value of 1 is selected.
    The button makes the button visible when 'edit' is selected and the button disappears when 'read-only' is selected which is the expected behavior.
    I do have a condition on the 'save' button for the value to not be zero which is based on the value from the radio button.
    My gut says it'll be a region header attribute or Java Script sort of thing and I've not found anything so far, and I'm hoping there's an Apex guru out there that has a recommendation.
    Thanks in advance!
    Matt

    I used some source I found on Denes' web site and added the call, but it didn't yield the result I was hoping for.
    <script type="text/javascript" language="javascript">
    $s('P8_RADIO_BUTTON','0');
    function f_showhideButtonRadio(pThis, pValue)
    {     var show_or_hide = html_RadioValue(pValue);
    if (show_or_hide == 0)
    {html_HideElement(pThis);}
    else
    {html_ShowElement(pThis);}
    function f_showhideButtonSelect(pThis, pValue)
    {     var show_or_hide = $x(pValue).value;
    if (show_or_hide == 0)
    {html_HideElement(pThis);}
    else
    {html_ShowElement(pThis);}
    </script>
    I'm quite new to the Java Script in Apex, so if I hosed this up, please let me know. Also, does that set the click event on or does that just set the value? The reason I ask is with a 0 or 1 it yielded the same result.
    Thanks!
    Matt

  • Create a toolbar/button in Acrobat 8.0

    I am sorry for my rather simple title, but at this stage I do not know what I am looking for.
    I want to give the possibility for someone using Adobe Acrobat 8.0 pro to be able to save a pdf document they currently have open into a database.
    For example in Office this is simple, I created an addin that got the document or email as an object and I sent the object to my MS Access database.  MS Access then saves the file somewhere and I upload the file with the known path.
    But maybe there is a simple way maybe I can create a button that saves the pdf in a special place and then signals either the MS Access database or even a small .dll/exe I have that this button has been clicked and then this .dll/exe can wake up the MSAccess databae and tell it to do some work.
    Any help would be greatl appreciated.

    Ok so spoon feeding is not an option in this forum.
    So could someone humour me with at least the "yes" word or "no" word.
    I can create a toolbar button which will automatically load when Acrobat loads by making a Plug-in?
    If my Target "Acrobat" family member is Acrobat Standard 8.1.5 (note not pro) I need to get the 8.0/8.1 SDK to help me?
    My Plug-in is going to be written in Visual Studio 2005/2008?
    I must learn/use C/C++ for my plugin language?
    I will compile the .dll and then make it an .api file extension?
    To give my .api to someone else I need only put it into the ...\Adobe\Acrobat\plug_ins?
    This .api does not need to be registered (regsvr32) or something like that in the Windows registry?
    I am sure that might lead to further questions but it is a good start so I know what to google to find out how to do it, and then get some sample code.

  • Plug-in toolbar button activation question

    I'm not a plug-in developer and do not foresee becoming one, but I am trying to understand how Acrobat handles custom toolbar buttons that you add via JavaScript.
    Im interested in the cEnable parameter that you can specify when using app.addToolbarButton. With it, you can specify a JavaScript expression that sets the value of event.rc to true or false to control whether the toolbar button is enabled or not. What Im trying to understand is when, exactly, does this expression get evaluated? In my testing, it seems as though it is triggered continuously, but I dont know what particular event(s) triggers it. It is not documented in the Acrobat JavaScript reference.
    I tried reading through the plug-in related documentation in the SDK to see if I could figure out what event a plug-in would be likely to register for if it needed to be able to disable its toolbar button(s), but came up empty. If a plug-in wanted to disable a toolbar button in a similar manner, what event(s) should it be listening to?
    What is Acrobat using to trigger the evaluation of the code specified with the cEnable parameter for app.addToolbar button? Speculations are welcome if not known.
    Thanks,
    George

    > In that case the cEnable code is run when the button loads and each time a document is opened/closed in that view pane.
    It's not just limited to that. Whatever event it is, it seems as though it is continually triggered. For example, if I set the cEnable code to be based on the value of a global variable, the button is affected immediately after I alter the global variable:
    cEnable: "event.rc = global.myVar;"
    Then, in the JavaScript console, if I execute:
    global.myvar = false;
    my button immediately becomes disabled. Something must trigger it, and I'm suspecting it's related to the ECMAscript/Forms plug-in and may not be an event that other plug-ins can be notified of.
    George

  • So how do I REALLY get the toolbar buttons to just show icons (and not text)?

    On my Bookmarks toolbar, my bookmarks "buttons" show icon AND text. I just want to show icon, not text. When I go right-click.....customize, the window "customize toolbars" opens. Down in the bottom left corner the "show" option dropdown is already set to "icons" (and only icons). But it's just not so. The toolbar buttons show icons AND text. If I cycle through that dropdown just for kicks, it doesn't change; I can choose "icons (only)" all day long, but the toolbar buttons still show text.

    Either of the following Add-ons allow you to show icons only and/or to have multiple rows on the Bookmarks Toolbar. Set the options on either after installation.
    *Multirow Bookmarks Toolbar Plus - https://addons.mozilla.org/en-US/firefox/addon/multirow-bookmarks-toolbarplus/
    *Roomy Bookmarks Toolbar - https://addons.mozilla.org/en-US/firefox/addon/roomy-bookmarks-toolbar/
    Other - Check your Plugins and update as needed.
    #Check your Plugins - https://www.mozilla.org/en-US/plugincheck/
    #'''''Adobe Shockwave for Director Netscape plug-in, version 11.6.4.634''''' (this old version has security issues)
    #*http://kb.mozillazine.org/Shockwave
    #*Download, save, close all browsers, run the installer you downloaded - http://get.adobe.com/shockwave/thankyou/

  • How to get "Selected" color for custom toolbar buttons?

    RH 8.0.2.208
    RoboHelp HTML
    WebHelp output
    I'm getting flack from internal QA folks about the custom toolbar buttons not having the same "selected" color as the default buttons (Contents, Index). I've copied the background color info from the <btnselected></btnselected> section for the built-in Contents to the <btnselected></btnselected> section for a custom toolbar button, but RH is ignoring it.
    Any hints?
    Leon

    You could try using the raw converter. Open one file and edit it (File>Open, pick the image and choose Camera Raw as the format before you click Open). Then open the next image and click the little four-lined square on the upper right side of the ACR window and choose Previous Conversion from the flyout menu.

  • Change the position of toolbar buttons in RoboHelp 9 (WebHelp)

    Hi,
    I have been trying to create a custom skin for my webhelp output. I am able to specify the toolbar background image. However, the text in the image is being hidden by the toolbar buttons (Contents, Index, Serach, etc buttons). Is there any way to alter the position of the toolbar buttons (for example, lowering these buttons) so that the text in the image is displayed clearly?
    I would be glad to know of any work-around to this problem.
    Thanks!

    Hello again
    After I replied I noticed you had replied to two other threads. Really old threads. You basically asked the same question twice about how to resize images.
    As you are new here you likely don't understand the "rules of the road" so to speak. So it would be helpful to you to take a few moments and read through the thread I'm linking below. We put it together to help new folks.
    Click here to view
    As for how to change those button images, you do that using another application that manipulates images. SnagIt, PhotoShop, Windows Paint, GIMP,  Paint Shop Pro, Etc.
    Cheers... Rick
    Helpful and Handy Links
    RoboHelp Wish Form/Bug Reporting Form
    Begin learning RoboHelp HTML 7, 8 or 9 within the day!
    Adobe Certified RoboHelp HTML Training
    SorcerStone Blog
    RoboHelp eBooks

  • Toolbar button/hotkey for "show cover page in two page view" in Acrobat X?

    In Acrobat X, how about make a toolbar button/hotkey for "show cover page in two page view"?  I find toggling this option to be useful for changing up the order of adjacent pages in magazines/books in which a two page spread has to match for a full large picture.  Due to frequent toggling, I would like a button/hotkey for this for easier access.

    Hotkeys for existing menu items are not modifiable, but you can add a scripted button which toggles it with the following code:
    if (layout.substr(-5)=="Right") layout = layout.replace("Right","Left");
    else layout = layout.replace("Left","Right");
    For info on how to add a button with a folder-level script, see the Acrobat SDK documentation. Scripted buttons will appear in a new panel on the tools pane in Acrobat X, not on the tool bar.

  • Newbie: Toolbar Button QuickPrint works not in Browser

    Hi all,
    does anybody know a solution for this:
    - wrote a javascript that adds a toolbar button with the following lines:
    app.addToolButton({           
        cName: "atbToolButton1",           
    //    oIcon: oIcon,           
        cExec: "this.print({bUI: false, bSilent: true, bShrinkToFit: true});",           
        cTooltext: "Print without Print Settings dialog",           
        nPos: 0,       
        cLabel:"QuickPrint"
    - the script is in the Javascript directory of the reader with the name config.js
    - it works great but only in the reader
    - when a pdf is opened in the browser my great script doesn't seem to work
    - I know that in the browser this is the activex plug-in
    Is it possible to have this toolbar button in the browser plug-in? And is there another place to copy to the script?
    Please help.
    Thanks for any help in advance.
    PS: I use the reader version 9.1
    Regards
    Andreas

    Hi shilpi,
    thank you for your quick reply. Yes, it is like you wrote. I thought I have read that you can't drag this javascript toolbars to the "normal" other standard toolbars. But this was a mistake. In the menu there is now under Tools - configure Toolbar a new toolbar "additional programs" available and this can switch the quickprint toolbar. This is great. Thank you very much for your help.
    The only problem I have now is that I can switch on my quickprint toolbar but when I close the window and open another pdf in a browser IE seems to have forgotten that he should view the quickprint toolbar. I tried this with FireFox and here is the correct behavior. Firefox remembers that it should switch on the quickprint toolbar. But with Firefox I have another problem. I run Firefox with the Full Fullscreen Add-on. When the pdf is opend in fullscreen there is no way to close the window. So I search for an additional button "close". But there seems to be no function to close the current window where the pdf is viewed. In IE there is the correct behavior that the opend window is not opened in fullscreen mode. Does anybody know a way per javascript toolbar to make a button like "close current window"? Or should I open a new thread for this? Thanks for any help.
    Andreas
    PS: I now use Adobe Reader 9.3.2 and IE 8 or FF 3.6.3

Maybe you are looking for

  • Extremely Slow when Opening a new tab

    I have just bought my new Retina MacBook Pro after my 3 years Macbook Pro 13" is total lost and get the Mountain Lion OSX with latest 10.8.2 version After migrating the MacOSX from Snow Leopard to Mountain Lion, my Mac is everything ok but without Sa

  • Java in Oracle - Urgent pls

    Hii All, I have a java program which runs in Oracle JVM. When I execute my program, it will write a new java file. This was working in NT server but when the same program is executed in a win2000 server (oracle 8.1.7), it is giving the following erro

  • Function Module to calculate age

    Hi Abapers, Kindly suggest some function module which can calculate age of a person by taking date of birth till date. Thanks in advance, Radhika

  • HP Scanjet 1000

    I just bought a new HP Scanjet 1000 and it does not seem to be recognized by anything other than System Profiler. The unit shipped with lots of PC software, but I did find a Mac driver on the CD which I installed. I planned on just using Image captur

  • Import destination greyed out

    I am well up the learning curve on Aperture, but still cannot figure out how to designate import destination. "Destination" in the "Aperture Library" block of "Import Settings" says "New Project" but is greyed out and I cannot type in it to make the