Jump to content

Darren

NI
  • Content Count

    582
  • Joined

  • Last visited

  • Days Won

    50

Everything posted by Darren

  1. Call the "Get Tag" method of the ProjectItem class and use the alias.value tag:
  2. In this thread I posted a VI that wraps a private function to suppress LabVIEW dialogs. Standard disclaimer here about using private functionality in production code, etc. etc.
  3. The MenuLaunchApp property only works the way you desire when the menu launch VI is launched from the menu of a VI. If you want to gain access to the project from which the menu launch VI was run, you'll need to use the Active Project property: From here, you can parse the project and get the Application Instance (which will be different per target in the project) you want.
  4. Maybe use a subpanel to switch out the visible controls depending on user preference?
  5. I don't know anything about the internals of LabVIEW window management, so I can't speak to whether or not what you're seeing is intended behavior when the windows are reparented via winapi calls. Here's a VI that may help, though. This password-protected VI (saved in LabVIEW 2013) calls a private VI Server property to suppress LabVIEW editor dialogs. Call this VI before you do your scripting, with a TRUE input. Then when your scripting is done, call it again with a FALSE input to reenable LabVIEW editor dialogs. <standard disclaimer here about using private LabVIEW functionality in pro
  6. In LabVIEW 2013, you can check out the following shipping example to see some snippets of scripting code that modify the configured events in an Event Structure: LabVIEW 2013examplesApplication ControlVI ScriptingStructuresVI Scripting with Structures - Event Structure.vi Here's a screenshot of the applicable part of the example's diagram: Unfortunately, this functionality is not available in LabVIEW prior to version 2013.
  7. Nope, still not prompted: Here's the VI I'm trying (saved in LabVIEW 2013), if anybody wants to modify it in such a way that I get a prompt when the VI closes. test script and close.vi
  8. The LabVIEW Run-Time Engine excludes functionality that is purely for editing use...for example, there are no palettes in a built EXE. I'm guessing this is done to keep the Run-Time Engine size down. For better or worse, LabVIEW Scripting is considered editor functionality, and as a result, is not currently included in the Run-Time Engine. FYI, the VI Analyzer Toolkit includes a test called Built Application Compatibility that will check your application for any functionality that is not included in the Run-Time Engine.
  9. What specifically are you doing to the VI to cause it to prompt on close? When I create a new VI and drop an object in it, I don't get prompted to save when I close the VI, even if I set up an Undo transaction.
  10. Are you trying to close the VI interactively, or programmatically?
  11. Scripting properties and methods are not supported in the run-time engine, so a built EXE does not have the ability to perform VI inspection.
  12. Sure, here you go. Saved in LabVIEW 2012. OS Window and Native Window properties.vi
  13. I have said almost those exact words on more than one occasion.
  14. Open your main VI, press Ctrl-F, select "Objects", and specify a MathScript Node as the item to search for. Assuming your application doesn't call any dynamic VIs, and you have the "Search Scope" set to <All VIs in Application Instance>, this should find all the MathScript Nodes in your application.
  15. I have added a link to this post to the CAR, and indicated that we should prioritize this over some of the other CARs I've filed about moving private stuff to public/scripting.
  16. High Resolution Relative Seconds.vi works on all desktop platforms, and it also works in RT.
  17. Here are this year's BBQ limericks. If you find that your woman is yearning, for a good dose of sweet LabVIEW learning. Show her 2013, where the examples are clean, and no longer cause stomach churning. A weirdo who loved C++ Met JeffK while riding the bus. A discussion transpired, His brain got rewired, Now the weirdo loves LabVIEW like us! You’ve heard of this framework called Actor, Well it’s great for your LabVIEW geek factor! When a girl sees your app, It won't look like crap, And you can use that to somehow attract her. You might wonder how I got so skilled,
  18. Argh, you're right. When I checked this morning I was awash in several open LabVIEWs and checked the wrong one. The "Focus Item" property of the TreeControl class is only available in LabVIEW 2013 and later. I have updated my post above to reflect this. Sorry about that.
  19. The FocusRow and FocusItem properties are still private in LabVIEW 2013. I will add them to our internal list of properties to consider moving to public/scripting in LabVIEW 2014.
  20. From what I could tell, we were *supposed* to see the focus row be correctly set while editing in 2013, but from my preliminary tests, it appears to still be a problem in 2013, and will thus still require the programmatic workaround.
  21. I didn't think they did, but I was pleasantly surprised when I looked this morning. Here is the same property for the Tree (saved in 2012), also only available in 2012 SP1 and later. tree_FocusItem.vi Edit: Turns out the "Focus Item" property of the TreeControl class is only available in LabVIEW 2013 and later. My previous statement that it was available in 2012 SP1 is incorrect.
  22. There are some private properties you can use in LabVIEW 2012 SP1 and later that allow you to set the focus row of a Listbox or Multicolumn Listbox programmatically. Whenever you programmatically change the value, if you also programmatically change the focus row, it should behave in the manner you're looking for. I had heard the behavior was fixed natively to the controls in LabVIEW 2013, but it appears to still be an issue that we have to workaround programmatically. This VI (saved in LabVIEW 2012) contains the private properties you would need. Again, these properties were added in 2012
  23. In my case, the password they sent me had a lowercase "L" that looked like an uppercase "I". Once I figured that out, it worked for me.
  24. Yes, Jack asked me to do some again. I promise I won't forget the lines to any this year.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.