The cancellation of the 'file' dialog box and handle errors caused by the empty path that makes the DB connection

Hi guys.

I developed a VI that connects to the database reads the names of tables, columns of the selected table, etc. It works well as I want to.

However, I have problem with identifying the UDL file with function of dialog 'file' use in a structure of the event that is triggered when the button 'Open' value is changed. It also works well, when I choose the UDL file, but the problem is when I cancel it and I get the error 43.

I tried to deal with this problem with a "error handler" function to clear the error 43 but the next errors that are associated with the database conncetion appeared. The reason is, when file dialog is cancelled, an empty path passes by reference of connection and I can't start the while loop where are the key codes. I also used a box Structure connected to "Cancelled" with 'DB connection tool' in case of real and connection the reference connection for the while loop, but I get the same result.

I want to apply for work as: start to push the button "Open" and select the file UDL, the loop run to establish the connections database, if not with the cancellation of the file dialog box, the application waits by pushing the button open and select the UDL file again.

Thanks a lot for your help in advance.

Hi lman,.

start to push the button "Open" and select the file UDL, the loop run to establish the connections database, if not with the cancellation of the file dialog box, the application waits by pushing the button open and select the UDL file again.

Some pseudocode, easy to implement:

WHILE

  onevent(OPEN button)
    FileDialog

  IF file selected THEN
    open database
    do calculations
  ELSE
    do nothing
  ENDIF

WEND

What is your problem with the help of loops and structures of the case?

Tags: NI Software

Similar Questions

  • Order of execution for explicit file dialog boxes and query the user input dialogue

    Hello

    In my VI I use 1 and 2 express file dialog boxes prompt the user for input dialogue box. Y at - it any easy way to determine an order of exuction for these express dialog boxes? Or I have to use screws to notify?

    In fact, I just need the input of fo dialogue to prompt the user to be the first.

    Thanks for the tips!

    Martin

    Like most of the functions, the flow of execution can be set by plugging the error / mistake on clusters.

  • SQL Server 2003 change open query file dialog box default to the details

    When you use the open the SQL query file dialog box, and then select Details to see the dates, etc..

    It's always come back for when the list opened again very boring and tedious.

    I managed to set the directories of the default folder for more details, running Windows XP

    but have had no luck with SQL Server.  If someone has conquered it?

    Hi ArmintaForrer,

    The question you have posted is better suited to the MSDN forums. You can ask your question in the help link.

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

    Hope the helps of information.

  • Import layered file dialog box not to come

    Hey I am currently using Adobe Premiere Pro v7.0 and when I go to import a layered photoshop file to the layered file dialog box is not coming! Is there another way that I can choose which layer I want to import? or a way to make the upcoming dialog box?

    Thank you very much!

    Once you've done a Save_As > PSD in PS, you will get then two choices:

    1.) sequence, where the layers will be flattened (not what you want)

    Sequence 2.), where the layers are kept on their own video track, which is what you want - if I read correctly.

    Use the PSD for this, says Ann.

    Good luck

    Hunt

  • I'm trying to reduce the file size of a jpeg file, but the dialog box under image > image size reflects a much smaller that the file is. I saved the image after resampling and by reducing the size of the image, reduced the pip to 72 and lowered the qua

    I'm trying to reduce the file size of a jpeg file, but the dialog box under image > image size reflects a much smaller that the file is. I saved the image after resampling and simplistic image, the pip size reduced to 72 and lowered the low quality only to see the minimum file size reduction. Why the dialog box in photoshop gives me a different file size than my computer and how do I solve this problem? Thank you!

    The Image Size dialog box dialog box shows the uncompressed size.

    Your operating system (Explorer/Finder) shows the size compressed. (size on the disk)

    If you use save for Web, you can see the compressed size, but also an overview.

  • How to use the view 'cover flow' in an open file dialog box?

    I often post pictures, such as screenshots, Web - like the one I included here!

    I always use "cover flow" as an aid to make sure that I'm the one that I want to load the download.

    In El Capitan, I see "cover flow" in the Finder, but not in a file open dialog box. How do I access view 'cover flow' in the open file dialog boxes? I have to use a preference somewhere to add it to the toolbar, or what?

    In the Finder, go to view, and then customize the toolbar and made drag the point of view of the toolbar window you Finder.

  • Problem with the file dialog box

    Hello erveryone,.

    My problem is quite easy... I try to use the file of dialogue vi of NOR and its work properly, but when I select a file using the double click, the second click is detected as a click on my Panel of...

    Example, if the file I select in the local file dialog box is justa button on my Panel (under the pop - up), the action for this button is run...

    I tried to disable my front panel when you use the dialog box, but it doesn't change anything.

    Someone there had the same problem? Anyone find a solution to this problem?

    Thanks for the help,

    Fabrice

    Hmm... What's not here? When the file in the dialog selected with double-click, and then disappeared with the mouse down, so dialogue, your dialogue control receives the mouse upward:

    Double click: mouse-> mouse-> mouse downwards upwards downwards (here missing dialogue)-> the mouse upwards (you got it). Nothing wrong. Can be inconvenient in some cases.

    Andrey.

  • File dialog box cut the default name

    Hi all

    I recently migrated from LV2011 to LV2012 and I have a problem with the dialog file Express vi. It seems, that in LV2012 the Windows dialog box that appears after invoking the file dialog box, adjust the default name to 14 characters (or rather the chain moves to the left so the first x characters are hidden). Please see screenshot attached screen and VI. It's OK in LV2011 (have tested the same code yesterday on another PC with LV2011). Is there a solution or the solution? This is a minor bug, but given that my application is distributed to a customer who pays it mind rather

    Thank you for your reply, Andrew!

    Your VI not exactly help me with my code, but it helped me to find the path . Unfortunately, when I used your VI, the behavior was exactly the same as with the file dialog box. But I noticed that it works only when I select 'create' to the function input terminal (with "create or replace" or something else I've known the cutting chain).

    Then I tried to override the setting of file express VI dialog box of 'New or existing' on 'New' with this setting, the file dialog box works very well (and there seems to be no difference between 'New or existing' and 'New').

    This problem is solved, thank you once more!

  • How to get the name of the file in the file dialog box

    Hi all

    I use the file dialog box to open a file and read the contents of it. However, I want to show the name of the opened file and do not know how to do it.

    Someone has an idea to display the name of the opened file?

    Thank you.

    Hi powerplay.

    the file dialog box has an output "selected path. You can use the path of the strip function to get only the file name.

    Mike

  • The open file dialog box does not show up on Windows 7

    My first installation of Win 7 32 bit on my systemeverything was end of work, but after some time all of a sudden all the program that I opened in Windows 7 which has an and save as dialog box or try to download an attachment in mail. the open file dialog box will appear, so I can't be able to open, save, and download any file, it seems that the open a file dialog box is disabled somehow, but I can't be able to find the exact cause of this problem so I need help very badly as soon as possible. So please help and answer...

    Hello Bharat Bhushan Wadhwa,

    Below, I've added a link where other users have had this problem.  There are a few steps to try troubleshooting.  Please let us know status.

    Microsoft Answers:

    http://answers.Microsoft.com/en-us/Windows/Forum/Windows_7-windows_programs/the-open-file-or-browse-for-file-dialog-box-doesn ' t/50f452f7-f73b-4ad5-8887-b8bb361f07b9

    Thank you

  • How can I configure the location for file dialog boxes?

    See the topic. File open, Save Fale and friends display the file dialog box.

    On the side of Lleft are in some places and I want to configure them. How is that possible?

    Thanks a lot for listening!

    Norbert

    There is no mechanism for this today. What you see here are common OS directories like 'Home' or 'Documents' and then recently traversed directories.

  • Open file dialog box does not appear after a certain time in the latest version of Illustrator CC 2014

    Hi all

    Everyone knows a problem doing a file > open after using Illustrator for awhile? I select file > open and nothing happens after I used Illustrator for awhile. Doesn't seem to have any model, the open a file dialog box does not appear only so I close and reopen Illustrator.

    Thank you

    Ben

    benkop,

    There seems to be a bug in CC2014, that appears when you open Illustrator / place dialogue together for display column and sort by date. You can adapt it to display by name or a list of point of view.

  • CS5 Win7 64 bit: cannot display Canon RAW (CR2) thumbnails in the open file dialog box.

    I know that there must be a VERY easy answer to this, but I have when I go to open a file in CS5, of my RAW CR2 appear only as a generic icon and not a thumbnail in the file dialog box to open, even though I see a CR2 thumbnail in minijonction.

    CR2 Thumbnail.JPG

    I hope you can help!

    Thank you

    Paul

    Try the microsoft camera codec pack:

    http://www.Microsoft.com/download/en/details.aspx?ID=26829

  • 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.

  • innovation file dialog box?

    Is there a function teststand API, or call the windows dll or activex somewhere, method that displays a browse dialog box and the path to the selected output file?

    Thank you
    David Jenkinson

    Engine.DisplayFileDialog will do the trick for you.

Maybe you are looking for