How you can display a dialog box when opening a program?

Hello

Does anyone know how to do to have a dialog with a custom message pop up every time that a specific program is open?  The computer is running Windows XP Professional 2002 with Service Pack 3.  The program is used to operate a scientific instrument that keeps the damage by lab users who disregard the instructions printed around it.  Ideally, I could have a pop up dialog that requires users to click on the 'OK' button before the program opens.  I have spent some time surfing the web for ideas, but have so far come back empty-handed.  The program is generally open from a shortcut on the desktop.

Thank you very much

Jeremy

You can create a small shell script which displays a message first, then open the program once you click OK.  Delete your shortcut on the desktop and put a shortcut to this script instead.  You can even customize the icon of the shortcut to the script so that we don't see even a difference.

How to run a program from a script:

http://msdn.Microsoft.com/en-us/library/d5fk67ky (v = vs. 84) .aspx

Here is the final code (with the exception of this in Notepad as a type of "vbs" file). It displays the message, and then running the executable program specified in the last line quotes (currently set to run write.exe outside directory windows.

startupMessage = MsgBox ("responsible use of this program.", 0, "Woah there!")

Set WshShell = WScript.CreateObject ("WScript.Shell")
WshShell.Run "%windir%\write.exe".

Tags: Windows

Similar Questions

  • Displaying a dialog box when you open an application

    Hello

    I need to know is possible for me to show a dialog when the user opens my request?

    There will be an error when you put the code in the dialog box in the constructor.

    Does anyone of you have examples of code for this?

    Thanks in advance.

    I believe that by extracting the appropriate bits of the following three items, you should have enough information to be able to do it by yourself.

    How - to display a graphical interface to the BlackBerry device to start
    Article number: DB-00539

    http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800620/How_To _...

    It speaks of a GUI display to start the system, but the concepts are the same for the start of the application

    How - to create a splash screen
    Article number: DB-00119

    http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800505/800256/...

    You shouldn't do this if you want to display a dialog box.

    How - to detect the availability of the system at boot
    Article number: DB-00642

    http://www.BlackBerry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800901/How_to_-_Detec...

    It strengthens the arguments made in the other articles in the KB.

  • How you can display the details-the folder name, the date, labels, size, type when displaying folders as large icons?

    Windows 7
    How you can view the records/document details-name, date, tags, size, good guy that watching a records/documents too large, medium or small icons?
    I have to be able to sort the records/documents while in the large, medium or small icon view I have in Vista. I can't settle unless I'm in the Details view. I work with graphics mostly, so I need to see while I sort.

    Even if the headers are not visible, you can sort/filter/group by those details by right-clicking on an empty spot in the folder and choose the fate/group that made a right click menu.

    Your preference of sort/group will remember your next visit this folder.  For more information on how to apply your preferences of sorting/grouping of all records at once, try my tip at http://skeene.net/tech/apply-folder-styles-to-all-subfolders/
  • Display the dialog box when you open a report

    Hi all

    Currently, in one of the dashboard, for a particular report, I selected the link display in a separate window (properties-> display options - > link in a separate window). Since then, all the print, download links are displayed at the bottom of the report, users are Dungeon forget these links. I tried to post the links at the top of the report and tried the solution that I found on the forum. but, no luck.

    Instead, I want to display a warning message when they click on any part of the report in the newly opened window (since then, I've selected display options - > link in a separate window). If I create an alert by using narrative view box, the alert box will be open, if I click on that particular place.

    But, my requirement is, should the popup box are displayed by saying: "Please scroll to the bottom of the page to download/print the report" when users click on any where, on the report.

    Is this possible at all? I appreciate your help in this regard.

    Thanks in advance.

    -Is it possible to have the following views
    View 1: static text + pivot table1
    See 2: narrative view + pivot table2?

    In other words, is it possible to have fixed views as a point of view? Please notify.

    Thanks in advance.

    Yes, you can.

    (1) create all your individual points of view.

    (2) put the static text and Pivot Table in the Layout of the compound.

    (3) duplicate available composed to get Compound page layout: 2

    (4) while Compound layout: 2 delete and add narrative view and Pivot Table views: 2.

    (5) duplicate Mateur mode once more for the compounds page layout: 3

    (6) create the view selector with implantation and setting compound in page: 2 compound as the two points of view. Name them appropriately.

    (7) in the Layout composed: 3, delete all notices and add selector display.

    Now, users can switch between the two sets of views.

    Edited by: David_T on October 5, 2010 14:48

  • How dio I remove the unwanted of dialog boxes when opening files in FM9

    Everytime I open the fm files in FM9 I am bombarded by a plethora of dialog boxes such as the ADD/EDIT VARIABLE, DITA CROSS_REFERENCE didn't intend to use. During the day, it must lead to probably over 100 clicks to get rid of these while being very annoying. Often, the work area is completely hidden by these dialog boxes. Is there a way to permanently delete these things and only open when we really want to do something like modifying a variable? Thank you very much.

    1roach,

    The feature you're looking for in FM9 is called "Workspaces." Your workspace is selected by using the dropdown in the top right of the window of FM, left minimize/maximize/close buttons. Simply set up the workspace exactly how you like it by opening the dialog boxes (or "pods") you use regularly, close the pods, you have not, fusion as the pods together as you wish, and moving everything exactly where you want. At this time, click this menu workspace and select "Save the workspace." The name that you want, and the next time that you open a document in FM, it should initiate this workspace automatically (assuming that it was the last workspace you had open... He memorizes the last workspace you used).

    For example, I put in spaces of work different for when I'm in the office or work at home (I have larger monitors at work, so I can use the space differently), but also of different workspaces for different phases of the drafting process. For example, I have a workspace for 'creation' which includes the pods for the Structure, elements, Variables, markers and cross reference. I then have a different workspace for working with graphics which has more pods based graphics, and another for the creation of index that has the pods that I use the most when indexing.

    Do a quick search in the help files of FM for "workspace." You will find a ton of info here. Indeed, if your help system is "online" mode and you select "include the results of the community" when searching, the first entry should be a blog entry titled "Workspaces in FrameMaker 9" on May 26, 2009... and the opening of the line is "Tired of loading dialog boxes, modeless, every time that you start your FrameMaker? Sounds familiar...

    Good luck!

    Mykimus

  • Can not enter wildcard (*) in the file selection dialog box when opening a file

    It's something I've not seen before. I posted this question in the forum Autodesk AutoCad LT five days ago, but I got no answer at all. Because I'm not sure whether it is a Windows or a problem with Autocad, I thought I'll try to post here, too.

    On one of our AutoCad workstations, when you open a drawing, we cannot enter a wildcard character (*) in the file selection dialog box to help unravel the drawings.

    In other words, say there are 10 versions of a drawing with the number 5008. I should be able to enter the 5008 * and just see these ten designs. On this computer, when I try to type an asterisk (*), I get this error message: invalid character. The following characters are not allowed in file names: \ /: *? "<>

    Now, I know that they are not allowed... but I don't mean to create a file name. I'm just trying to classify them. On our other RTE Autocad workstations, the wildcard character works fine.  What's up with this one? Y at - it a setting or a variable that controls this?

    Thanks - Kevin

    Hello

    ·         The problem occurs with any other application?

    It may be some setting in Auto CAD, which raises the question, and its best you seek help from experts in DAO automatic.

    Diana
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

    If this post can help solve your problem, please click the 'Mark as answer' or 'Useful' at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • How do you force a macro dialog box to open all the other open windows on top?

    I have a macro that was created in the SolidWorks program. The macro works as expected, except during the macro, there is a dialog box that is supposed to appear on the top of the page to wait for user input. This opened on top in Windows XP but not in Windows 7. In Windows 7, I have to place the window in the front. It is not a show-stopper, but more pain. Is there a way to fix this?

    Thanks in advance.

    Hello

    The question you posted would be best suited to:

    http://social.msdn.Microsoft.com/forums/en-us/categories

  • How you can uncheck "digitally sign messages" when you add a new account? I don't want to use it.

    When I try to add a new account (or even to modify an existing account) "Digitally sign messages" is checked by default and it is not accessible to uncheck

    I check through all my accounts and they have no tick signatures. you were previously signed emails to get the value in the first place?

    Now, I assume that you have no e-mail account that you want to digitally sign messages.
    Go to the menu (alt + T) tools > Options > advanced > general and type in the search box

    sign
    

    You will get a list of entries below, including the .sign_mail of mail.identity.id# where # is a number

    Each account has a number, but are you not signing mail then put all on false is not a problem.

    find one that is set to true, right click and select toggle.
    Close the configuration editor once your done and restart Thunderbird.

    If you sign mail on an account, you will have to go back to the latter for account settings and turn path on any that you have bad out here in the configuration editor.

  • How you can limit the number of characters in a string attribute?

    I'm trying to fix a limit on the amount of characters that can be introduced to a string attribute.

    I saw that you can do when the user changes the web using regex mode, but how you can specify a maximum length when the user is in the form view that this currently replace the regex used in the tag on the inside: edit

    Thanks in advance,

    Andrew

    Hi André,.

    You can use the output of the editor boxes TEXTFIELD attribute.

    Just create a new attribute with the following configuration editor in the XLM:

    You can manage the size-> XSIZE and maximum number of characters-> MAXCHARS.

    I hope it helps.

    Kind regards

    Enrique

  • How can I do to block the main thread when to display a dialog box

    I have a problem to block the user interface main thread when to display a dialog box (the dialog was created by the main Application), and when the dialog box is closed, the main Application can go to the next step.
    Here is my code:

    SerializableAttribute public class TitledPaneExample extends Application {}
    instance of TitledPaneExample private;
    StackPane mainModalDimmer;

    /*
    * (non-Javadoc)
    *
    * @see javafx.application.Application #start (javafx.stage.Stage)
    */
    @Override
    public void start (point primaryStage) bird Exception {}
    instance = this;
    primaryStage.setTitle (this.getClass () m:System.NET.SocketAddress.ToString ());

    final StackPane layerPane = new StackPane();
    layerPane.setDepthTest (DepthTest.DISABLE);
    layerPane.setStyle ("background - fx - color: BLACK ;"); ")

    Vb VBox = new VBox();
    vb.setStyle ("background - fx - color: BLUE ;"); ")
    vb.getChildren () .add new (Label ("1"));
    vb.getChildren () .add (Label ("2")) new;
    vb.getChildren () .add new (Label ("3"));
    vb.getChildren () .add (Label ("4")) new;

    Bt1 button = new Button ("bt1");
    BT1.setOnAction (new EventHandler < ActionEvent > () {}
    {} public void handle (ActionEvent event)
    System.out.println ("bt1 trying to the new dialog box > > >");
    Dialogue di = new dialog box (instance, "some trick here!");
    System.out.println ("bt1 dialogue again successfully, try to show");
    di. Show();
    System.out.println ("bt1 dialog hide? < < < < ");"
    }
    });
    vb.getChildren () .add (bt1).

    layerPane.getChildren () .add (vb);

    mainModalDimmer = new StackPane();
    mainModalDimmer.setId ("MainModalDimmer");
    mainModalDimmer.setMaxSize (Double.MAX_VALUE, Double.MAX_VALUE);
    mainModalDimmer.setVisible (false);
    mainModalDimmer.setStyle ("background - fx - color: RED ;"); ")
    layerPane.getChildren () .add (mainModalDimmer);

    Scene sc = new scene (layerPane, 800, 600);
    primaryStage.setResizable (true);
    primaryStage.setScene (sc);
    primaryStage.show ();

    }

    /**
    * Display the node given as a floating dialog on the entire application, with
    * the rest of the application grayed out and blocked from mouse events.
    *
    @param message
    */
    {} public void showModalMessage (message from node)
    mainModalDimmer.getChildren () .add (message);
    mainModalDimmer.setOpacity (0);
    mainModalDimmer.setVisible (true);
    mainModalDimmer.setCache (true);
    TimelineBuilder
    . Create()
    () .keyFrames
    new KeyFrame (Duration.seconds (1),)
    new EventHandler < ActionEvent > () {}
    {} public void handle (ActionEvent t)
    mainModalDimmer.setCache (false);
    }
    }, new KeyValue (mainModalDimmer
    . opacityProperty(), 1.
    Interpolator.EASE_BOTH))) infrastructure)
    . Play();
    }

    /**
    Hide the any modal message that appears
    */
    public void hideModalMessage() {}
    mainModalDimmer.setCache (true);
    TimelineBuilder
    . Create()
    () .keyFrames
    new KeyFrame (Duration.seconds (1),)
    new EventHandler < ActionEvent > () {}
    {} public void handle (ActionEvent t)
    mainModalDimmer.setCache (false);
    mainModalDimmer.setVisible (false);
    mainModalDimmer.getChildren () .clear ();
    }
    }, new KeyValue (mainModalDimmer
    . opacityProperty(), 0,.
    Interpolator.EASE_BOTH))) infrastructure)
    . Play();
    }

    /**
    @param args
    */
    Public Shared Sub main (String [] args) {}
    Launch();
    }

    Dialogue/public class extends TitledPane {}
    private owner of TitledPaneExample = null;
    instance of TitledPane private;

    Dialogue (owner of TitledPaneExample, String message) {}
    This.Owner = owner;
    this.parentThreand = Thread.currentThread ();
    This.instance = this;
    this.setExpanded (true);
    this.setText ("Dialog");
    this.setMaxWidth (400);
    this.setPrefWidth (300);
    this.setMinWidth (200);

    Label the tx = new Label ("message");
    tx.setTooltip (new Tooltip (message));
    tx.setWrapText (true);
    tx.setContentDisplay (ContentDisplay.LEFT);

    Bt button = new Button ("OK");
    bt.setOnAction (new EventHandler < ActionEvent > () {}
    {} public void handle (ActionEvent event)
    masquer();
    }
    });

    Sp ScrollPane = new ScrollPane();
    sp.setHbarPolicy (ScrollBarPolicy.AS_NEEDED);
    sp.setVbarPolicy (ScrollBarPolicy.AS_NEEDED);
    sp.setContent (tx);

    Hb HBox = new HBox (30);
    hb.setPrefHeight (40);
    hb.setAlignment (Pos.CENTER_RIGHT);
    hb.getChildren () .add (bt);

    BP BorderPane = new BorderPane();
    bp.setCenter (sp);
    bp.setBottom (hb);

    this.setContent (bp);
    }

    {} public void show()
    System.out.println ("dialogue show() 1 > > >");

    owner.showModalMessage (instance);

    System.out.println ("dialogue show() 2 > > >");

    }

    public void masquer() {}
    System.out.println ("dialogue masquer() 1 > > >");
    this.owner.hideModalMessage ();

    System.out.println ("dialogue masquer() 2 > > >");
    }
    }

    }

    I'm also interested in how to do this without the use of a step.

    But, if you are ready to use a step for this, you can create a useful first step (without borders) with its owner being your current stage. Then, you can call the function showAndWait on stage that allows to block the thread of your application. For example, I implemented a DialogStage like this:

    package hs.mediasystem.util;
    
    import javafx.animation.KeyFrame;
    import javafx.animation.KeyValue;
    import javafx.animation.Timeline;
    import javafx.event.EventHandler;
    import javafx.scene.effect.ColorAdjust;
    import javafx.stage.Modality;
    import javafx.stage.Stage;
    import javafx.stage.StageStyle;
    import javafx.stage.Window;
    import javafx.stage.WindowEvent;
    import javafx.util.Duration;
    
    public class DialogStage extends Stage implements Dialog {
    
      public DialogStage() {
        super(StageStyle.TRANSPARENT);
    
        this.setTitle("MediaSystem-dialog");
    
        initModality(Modality.APPLICATION_MODAL);
      }
    
      protected void setParentEffect(Stage parent) {
        ColorAdjust colorAdjust = new ColorAdjust();
    
        Timeline fadeOut = new Timeline(
          new KeyFrame(Duration.ZERO,
            new KeyValue(colorAdjust.brightnessProperty(), 0)
          ),
          new KeyFrame(Duration.seconds(1),
            new KeyValue(colorAdjust.brightnessProperty(), -0.5)
          )
        );
    
        parent.getScene().getRoot().setEffect(colorAdjust);
    
        fadeOut.play();
      }
    
      protected void removeParentEffect(Stage parent) {
        parent.getScene().getRoot().setEffect(null);
      }
    
      protected void recenter() {
        Window parent = getOwner();
    
        sizeToScene();
    
        setX(parent.getX() + parent.getWidth() / 2 - DialogStage.this.getWidth() / 2);
        setY(parent.getY() + parent.getHeight() / 2 - DialogStage.this.getHeight() / 2);
      }
    
      @Override
      public final void showDialog(final Stage parent, boolean synchronous) {
        initOwner(parent);
    
        setParentEffect(parent);
    
        setOnShown(new EventHandler() {
          @Override
          public void handle(WindowEvent event) {
            recenter();
            onShow();
          }
        });
    
        if(synchronous) {
          showAndWait();
        }
        else {
          show();
        }
      }
    
      protected void onShow() {
      }
    
      @Override
      public void close() {
        removeParentEffect((Stage)getOwner());
        super.close();
      }
    }
    
  • in windows 7 when you right click on how do you get the little line under the letter of the you can click on to make it open Windows 7

    in windows 7 when you right click on how do you get the little line under the letter of the you can click on to make it open Windows 7

    Example when you right click on a program, you can see Open if you click o the file opens, it was in XP, but not in 7

    That's what you want.

    1 - Open "Control Panel" and go to accessibility.

    2 - click make the keyboard easier to use.

    3. the title of 'Make it easier to use keyboard shortcuts' tick the box 'Underline access keys and keyboard shortcuts' and click 'Ok '.

    Oh sure, it could be useful.

  • How you can know if you want to compare materials is the problem between the processor and the memory when you have black screen!

    Hello

    If you have a black screen which can be if the processor is dead or memory is dead how you know if you do not reserve memory, the problem is the processor or memory?

    I tried this on my computer, I put on the CPU and I got black screen, I put in memory and I got black screen.

    Thank you

    Johan

    Thank you

    so in this case, how you can know if it is the processor or memory is the problem.

    you have to always have book of memory by you to resolve these issues (to make sure if the memory is problem) what memory or processor its work not at all.

    or it is too nested ways!

    Johan

    From what you described, it is possible that the processor, the RAM and the motherboard are all damaged. Or also the cold of power supply the problem (which could be checked for appropriate using a voltmeter). If you do not reply the existing motherboard then without spare parts (RAM, processor and motherboard) to use in tests, there is nothing more you can do with it to test these components.

  • Why overview begins with a file dialog box when it opens now?

    The last preview version now wants allows you to select a file when it is opened. I use the preview to create quick screenshots to the Clipboard and this behavior is a concern. It forces me to close this dialog box so that I can select new to show my screenshot. Is there a way to disable this option, if it goes back to the old way simply open the program without the Select file dialog box? plist change or something?

    Dtmps wrote:

    The last preview version now wants allows you to select a file when it is opened. I use the preview to create quick screenshots to the Clipboard and this behavior is a concern. It forces me to close this dialog box so that I can select new to show my screenshot. Is there a way to disable this option, if it goes back to the old way simply open the program without the Select file dialog box? plist change or something?

    It is seems more confused.  You can take a screenshot of the dialog box that opens.

    Preview allows you to create a screen capture?  How about pass order 4 and save to the desktop.

    How to take a screenshot on your Mac - Apple Support

    http://osxdaily.com/2011/01/26/change-the-screenshot-save-file-location-in-Mac-o s-x.

  • APEX 5.0 after you close a modal dialog box, I want to introduce the parent page, without losing session values

    I have a parent page that triggers a modal dialog box in APEX 5.0. When the user confirms in the dialog box, it closes the dialog box by using the process of dialogue.

    In the parent page, if I do not have a dynamic action "Dialog box closed", the user returned to page with the values, they recently came again here. If I add a closed action dialog box to send the page, the values are lost - it's as if the page refreshes before submitting. Someone knows how to solve this problem.

    Thank you.

    user3282753 wrote:

    Please update your forum profile with a recognizable username instead of "user3282753": Video tutorial how to change username available

    Also, is it possible to display the success message from the Page of the dialog box without updating the parent page.

    See Roels Blog: display a success message after you close a modal dialog box

  • Overview of the output only works when the preview dialog box is open?

    The preview of the output adjustment certainly between into force, but only when the output preview dialog box is open, while precisely the preview of the images in playback mode is not possible; It is only possible to preview by clicking on an image and open the dialog of OP. As soon as the OP dialog box is closed, the image reverts to its prior Preview State. This is not normal!

    That's how it has always been. Keep in mind, this is a modeless dialog box, it prevents you to navigate through the file.

    What do you mean by "reading mode" specifically and why you can not use?

Maybe you are looking for