FEATURE REQUEST: Lasso Tool to help organize code into separate VI's

Sometimes VI's can end up growing out of hand, and it is not so easy to re-organize sections of a VI into a separate VI.
It would be fantastic if there was a tool we could use to select a portion of our code inside of a VI (see Lasso tool in Photoshop or Free From Select in MSPaint), and have LabVIEW automatically move that code into a new VI with automatic assignment of inputs and outputs. All that code can then be replaced by a single VI.
This would make code organization so much faster and easier.
What do you think?

For the most part, it's already in LabVIEW.  If you select code in your VI and go to Edit->Create SubVI, LabVIEW will take the slected code and create a subVI and automatically replace the selected code with the subVI.
The only thing it doesn't have is the lasso selection.  You have rectangular selection and can keep addeding to the selecting using the SHIFT key.
You should post ideas to the Idea Exchange, too BTW.

Similar Messages

  • How to restructure this code into separate classes?

    I have C# code that initializes a force feedback joystick and plays an effect file(vibrates the joystick). I have turn the console application into library
    code to make a dll so that I can use it in LabVIEW. 
    Right now all the code is written under one class, so went I put the dll in LabVIEW I can only select that one class. labVIEW guy told me that I need to
    restructure my C# code into separate classes. Each class that I want to access from LabVIEW needs to marked as public. Then I can instantiate that class in LabVIEW using a constructor, and call methods and set properties of that class using invoke nodes and
    property nodes.
    How can I do this correctly? I tried changing some of them into classes but doesn't work. Can you guys take a look at the code to see if it is even possible
    to break the code into separate classes? Also, if it is possible can you guide me, suggest some reading/video, etc.
    Thank you
    using System;
    using System.Drawing;
    using System.Collections;
    using System.Windows.Forms;
    using Microsoft.DirectX.DirectInput;
    namespace JoystickProject
    /// <summary>
    /// Summary description for Form1.
    /// </summary>
    public class Form1 : System.Windows.Forms.Form
    private System.Windows.Forms.Label label1;
    /// <summary>
    /// Required designer variable.
    /// </summary>
    private System.ComponentModel.Container components = null;
    private Device device = null;
    private bool running = true;
    private ArrayList effectList = new ArrayList();
    private string joyState = "";
    public bool InitializeInput()
    // Create our joystick device
    foreach(DeviceInstance di in Manager.GetDevices(DeviceClass.GameControl,
    EnumDevicesFlags.AttachedOnly | EnumDevicesFlags.ForceFeeback))
    // Pick the first attached joystick we see
    device = new Device(di.InstanceGuid);
    break;
    if (device == null) // We couldn't find a joystick
    return false;
    device.SetDataFormat(DeviceDataFormat.Joystick);
    device.SetCooperativeLevel(this, CooperativeLevelFlags.Exclusive | CooperativeLevelFlags.Background);
    device.Properties.AxisModeAbsolute = true;
    device.Properties.AutoCenter = false;
    device.Acquire();
    // Enumerate any axes
    foreach(DeviceObjectInstance doi in device.Objects)
    if ((doi.ObjectId & (int)DeviceObjectTypeFlags.Axis) != 0)
    // We found an axis, set the range to a max of 10,000
    device.Properties.SetRange(ParameterHow.ById,
    doi.ObjectId, new InputRange(-5000, 5000));
    // Load our feedback file
    EffectList effects = null;
    effects = device.GetEffects(@"C:\MyEffectFile.ffe",
    FileEffectsFlags.ModifyIfNeeded);
    foreach(FileEffect fe in effects)
    EffectObject myEffect = new EffectObject(fe.EffectGuid, fe.EffectStruct,
    device);
    myEffect.Download();
    effectList.Add(myEffect);
    while(running)
    UpdateInputState();
    Application.DoEvents();
    return true;
    public void PlayEffects()
    // See if our effects are playing.
    foreach(EffectObject myEffect in effectList)
    //if (button0pressed == true)
    //MessageBox.Show("Button Pressed.");
    // myEffect.Start(1, EffectStartFlags.NoDownload);
    if (!myEffect.EffectStatus.Playing)
    // If not, play them
    myEffect.Start(1, EffectStartFlags.NoDownload);
    //button0pressed = true;
    protected override void OnClosed(EventArgs e)
    running = false;
    private void UpdateInputState()
    PlayEffects();
    // Check the joystick state
    JoystickState state = device.CurrentJoystickState;
    device.Poll();
    joyState = "Using JoystickState: \r\n";
    joyState += device.Properties.ProductName;
    joyState += "\n";
    joyState += device.ForceFeedbackState;
    joyState += "\n";
    joyState += state.ToString();
    byte[] buttons = state.GetButtons();
    for(int i = 0; i < buttons.Length; i++)
    joyState += string.Format("Button {0} {1}\r\n", i, buttons[i] != 0 ? "Pressed" : "Not Pressed");
    label1.Text = joyState;
    //if(buttons[0] != 0)
    //button0pressed = true;
    public Form1()
    // Required for Windows Form Designer support
    InitializeComponent();
    // TODO: Add any constructor code after InitializeComponent call
    /// <summary>
    /// Clean up any resources being used.
    /// </summary>
    protected override void Dispose( bool disposing )
    if( disposing )
    if (components != null)
    components.Dispose();
    base.Dispose( disposing );
    #region Windows Form Designer generated code
    /// <summary>
    /// Required method for Designer support - do not modify
    /// the contents of this method with the code editor.
    /// </summary>
    public void InitializeComponent()
    this.label1 = new System.Windows.Forms.Label();
    this.SuspendLayout();
    // label1
    this.label1.BackColor = System.Drawing.SystemColors.ActiveCaptionText;
    this.label1.Location = new System.Drawing.Point(8, 8);
    this.label1.Name = "label1";
    this.label1.Size = new System.Drawing.Size(272, 488);
    this.label1.TabIndex = 0;
    // Form1
    this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
    this.BackColor = System.Drawing.SystemColors.ControlText;
    this.ClientSize = new System.Drawing.Size(288, 502);
    this.Controls.AddRange(new System.Windows.Forms.Control[] {
    this.label1});
    this.Name = "Form1";
    this.Text = "Joystick Stuff";
    this.ResumeLayout(false);
    #endregion
    /// <summary>
    /// The main entry point for the application.
    /// </summary>
    [STAThread]
    static void Main()
    using (Form1 frm = new Form1())
    frm.Show();
    if (!frm.InitializeInput())
    MessageBox.Show("Couldn't find a joystick.");

    Imho he means the following.
    Your class has performs two tasks:
    Controlling the joystick.
    Managing the joystick with a form.
    So I would recommend, that you separate the WinForm from the joystick code. E.g.
    namespace JoystickCtlLib
    public class JoystickControl
    private Device device = null;
    private bool running = true;
    private ArrayList effectList = new ArrayList();
    private string joyState = "";
    public string State { get { return this.joyState; } }
    public bool InitializeInput() { return true; }
    public void PlayEffects() { }
    private void UpdateInputState() { }
    So that your joystick class does not reference or uses any winform or button.
    btw, there is a thing which is more important than that: Your polling the device in the main thread of your application. This will block your main application. Imho this should be a job for a thread like background worker.

  • Feature request: Include tool to mount disk images as virtual drives

    Such a tool has been put out by Microsoft before, but as new versions of Windows come they break compatibility as the driver needs to change with the version. If you become dependent on such a feature (I don't want to use up writable disks if I don't have to) you tend to need to rely on some adware laced software until something better comes around, and probably has a few problems. (Like giving no error message when hard drive images attempt to load, which I have to find another program for.) Not to many people need it, but those that do just require that it exist for their version of Windows and that they can find it fairly easily.

     
    Gordon_Ryan said:
    Can't help with mounting ISOs but have you noticed the ability to burn ISOs?
    Gordon
    www.longneckconsulting.com
    I have indeed, Gordon.
    Thanks.
    Adelino Araujo said:
    Just use the tool from Microsoft for XP.
    This is from the readme.txt:
    1. Copy VCdRom.sys to your %systemroot%\system32\drivers folder.
    2. Execute VCdControlTool.exe
    3. Click "Driver control"
    4. If the "Install Driver" button is available, click it. Navigate to the %systemroot%\system32\drivers folder, select VCdRom.sys, and click Open.
    5. Click "Start"
    6. Click OK
    7. Click "Add Drive" to add a drive to the drive list. Ensure that the drive added is not a local drive. If it is, continue to click "Add Drive" until an unused drive letter is available.
    8. Select an unused drive letter from the drive list and click "Mount".
    9. Navigate to the image file, select it, and click "OK". UNC naming conventions should not be used, however mapped network drives should be OK.
    The donwload link is http://download.microsoft.com/download/7/b/6/7b6abd84-7841-4978-96f5-bd58df02efa2/winxpvirtualcdcontrolpanel_21.exe
    And YES! It works on Windows 7! Can you believe that?
    Adelino Araujo
    Okay, more downloading to do. I will test it on the 64 bit version.
    Charles

  • Feature request: Better tool for organizing image files

    Hi all,
    I'm considering rearranging the directory structure of my photo library completely (for a number of reasons: new cameras, a new variety of tools on new PCs).
    I would like to reorganize my photos into a year\month directory structure and that will basically spread all my image files into new locations.
    I have searched quite a bit and the advices I have seen don't seem to work:
    (1) Moving the files outside LR is fairly easy (using exiftool) but I cannot make LR link to the files automatically in their new locations. And doing it manually with "Locate file" or "Find missing folder" is not practical due to the large number of files and large number of new locations.
    (2) Moving the files with LR tools is also not practical: Manually dragging the photos into the new directory structure will take forever, and the only automatic rename feature I know of is "Rename Files ..." cannot move the photos into new directories (it can, however, assign names from the file dates and other metadata).
    Now my feature suggestion: Either make it possible for LR to automatically relink files that have been scattered into a new directory structure or - better yet - make it possible for LR to perform such auto-organize operations.
    My mp3 manager (MediaMonkey) is a good example to follow: It can organize (move or copy) any number of music files into any directory structure built from the audio file's metadata (such as my standard audio directory structure: Music\<Artist>\<Album>\<Track#:2> - <Title>).
    Interestingly, the LR "Rename file" function can almost do it already; it just cannot move the file into a new directory.
    Or can this be done in a way I haven't discovered?

    Sorry if I might be stating the obvious (but at least I was such a *dummy* once that I needed this explicitely):
    In order to move the sequence of images per drag&drop in grid view you need to
    Put the sort order in the bottom toolbar to "user order" (toggle visibility with letter T if not displayed)
    Grab an image from within its thumbnail, not from its border-cell.
    When you move around you see a vertical black thick line wandering in between images where you would be able to drop it
    Put the images first into a collection in case they should be spread across multiple folders.
    This is the reason why most often from a filter result you cannot re-arrange.
    Still sometimes it does not work as I want, but can *be persuaded*, i.e. I repeat the same trial after first moving to another collection, then return back. I can't nail it down sufficiently to file a bug.
    For an automated sorting according to filename (chosse that setting finally in toolbar) you could rename the photos in place, without exporting & re-importing. Just select them and hit <F2> to bring up the renaming dialog like possible during import.
    +1 vote from me, as I am neither satisfied with the responsiveness of moving folders within LR e.g. from laptop hard disk to NAS.
    Apart from that I try not to build much on my folder structure, just break them into manageable quantities and have a quick "diary-overview" by using naming convention "YYYY-MM-DD description of event" (pictures of up to 4 cameras go inside, unique filenames for Canons achieved by renaming during import). For all the rest I prefer to build (smart) collections.

  • Feature request: better tools for commenting and editing text

    We currently use a comments-enabled Acrobat workflow with InDesign to track changes to our large catalog project. Was hoping to move our team over to CS Live, but currently the commenting tools are sub-par, and not accurate enough for extensive text editing. My request would be to imitate the text editing functionality of Acrobat:
    In CS Live online:
    - allow users to be able to copy selected text. (This is useful when a reviewer wants to be able to modify a sentence or paragraph. It's a headache now to have to retype the sentence prior to making modifications)
    - Ability to highlight text and hit "delete" to mark text as deleted, or highlight and type over to indicate replaced text
    - Ability to click to insert text, and have the comment appear with the inserted text designation (little blue carat like in Acrobat)
    - ability to highlight a section of text
    In InDesign:
    - ability to copy the text in a comment and NOT copy all the other extraneous meta data. (Currently, if you click "copy text", it will copy the comment along with all the details about the comment. For example, "- Amy Stewart [10.06.11 at 12:56 PM]"
    - ability to see in InDesign the EXACT part of the text that needs to be modified. Right now, the red box outlines the general area. The CS Review panel shows a tiny thumbnail with black highlight over the area of text that needs to be changed, but unfortunately, there's no way to zoom in on it, so you're stuck having to toggle between InDesign and the online review, where it's possible to zoom. (This diminishes the utility of the CS Review panel.)
    If you were able to incoroprate all the commenting functionality of Acrobat, I think you'll have a winner. But right now, we're going to have to stick with Acrobat as it's the only way to easily modify text.

    Sorry if I might be stating the obvious (but at least I was such a *dummy* once that I needed this explicitely):
    In order to move the sequence of images per drag&drop in grid view you need to
    Put the sort order in the bottom toolbar to "user order" (toggle visibility with letter T if not displayed)
    Grab an image from within its thumbnail, not from its border-cell.
    When you move around you see a vertical black thick line wandering in between images where you would be able to drop it
    Put the images first into a collection in case they should be spread across multiple folders.
    This is the reason why most often from a filter result you cannot re-arrange.
    Still sometimes it does not work as I want, but can *be persuaded*, i.e. I repeat the same trial after first moving to another collection, then return back. I can't nail it down sufficiently to file a bug.
    For an automated sorting according to filename (chosse that setting finally in toolbar) you could rename the photos in place, without exporting & re-importing. Just select them and hit <F2> to bring up the renaming dialog like possible during import.
    +1 vote from me, as I am neither satisfied with the responsiveness of moving folders within LR e.g. from laptop hard disk to NAS.
    Apart from that I try not to build much on my folder structure, just break them into manageable quantities and have a quick "diary-overview" by using naming convention "YYYY-MM-DD description of event" (pictures of up to 4 cameras go inside, unique filenames for Canons achieved by renaming during import). For all the rest I prefer to build (smart) collections.

  • Source code / feature request

    Hi
    This tool is fantastic and saves me a huge amount of time, helping us find some interesting bugs (like why "delete myarr.pop()" was having such an odd side-effect when the array contained strings..).
    I'm trying to get hold of the source code for this but my SVN clients can't connect, I've tried lots of different network configurations (from work, home and mobile connections) and both the SVN and HTTP connections, so I think the issue is on the Adobe/SoureForge end. Can anyone check/fix this?
    The reason for wanting the source is to add a minor change to the Tag Viewer / Tag Information output. Currently I'm trying to work out what function is defined at offset 0x348B2 of my SWF file. I can see it in the hex editor but it's tricky to work out what this function name is: the class is defined in DoInitActions offset 200492 and length 24355 i.e. a big class.
    What I'm hoping for is to add the offsets into each line in the DoInitActions 'Tag Information' panel, so e.g. instead of:
            if L63
            push $1
            push 'isMouseDown'
            getMember
            pushDuplicate
    I'd see:
    1522:        if L63
    1527:        push $1
    1527:        push 'isMouseDown'
    1534:        getMember
    1535:        pushDuplicate
    etc where the number at the start is the offset of this instruction within the DoInitActions tag.
    If anyone with the source can do this and update the binaries then great but I suspect it's something I would have to do myself... but currently I can't get at the source without having to individually browse to and download every file :-(
    thanks
       Andrew

    A new version of SWF Investigator was released on Friday (version 0.6.2) and I will be updating the open-source repository in the next day or two.  When the update is complete, I will respond to this thread so that you know to pull down the latest version of the source code.
    For SVN access, I have used TortoiseSVN on Windows which is supported by SourceForge: http://sourceforge.net/apps/trac/sourceforge/wiki/TortoiseSVN%20instructions
    The logic for your feature request already exists in SWF Investigator but it is currently commented out. For the next release, I can work on enabling it. If you want to play with the functionality in the meantime, then the code is in SWFInvestigator/src/decompiler/tools/Disassembler.as.Within that file there is a function called, "start." Within that function, there is an if-block which checks for "showOffset". You will need to uncomment the out.print() statement within the showOffset if-block. You will also want to set showOffset to true just before the if statement. Recompile the application and it will begin to show the information you want.

  • Polygon lasso tool in fireworks - Help

    Is there a way to undo the last step when you are using the polygon lasso tool in fireworks?
    Really struggling. I know in photoshop it is the delete key.
    I am using it on a imac within a virtual window 7 machine.
    Any and all help appreciated
    Thanks
    1Coops

    You can view the alternate option here.  Hope it helps.
    How Do You Delete A Step with the Polygon Lasso Tool

  • Polygonal Lasso Tool and White menus bug in Mavericks - help!

    After installing Mavericks I´m having so much trouble with the lasso tool and white menus in photoshop that it is really breaking my production speed and causing a lot of problems for me.
    Especially the Polygonal Lasso Tool, how its auto completing when painting with a tablet.
    Sadly I´ve upgraded to Mavericks, and I wish I never did that. Because these problems never occured in Mountain Lion. I´ve tried going back 3-4 steps on the tablet drivers - but no luck. I tried reinstalling photoshop and I´ve tried pretty much anything I can think of but nothing helps. I deperately need to fix this and I have a long line of architectural illustrations coming up and it takes me a lot more time working with masks if I cant do it with a tablet...
    I hope Adobe reads this! But if there´s anyone with a similar problem that has found a workaround or something I can do to fix this, please help!

    Yes, 3 MAJOR problems which bugs the hell out of me.
    -The white menus (which I assume Adobe is going to fix, since its a very common problem and it has gotten a lot of complaints)
    -The polygonal Lasso tool (which Adobe has not responded to at all ) and I assume its something everyone with a wacom struggle with in Mavericks, but not everyone is that dependent on this tool, which we haven´t seen more complaints.
    -The keyboard doesn´t always respond to a keystroke, and you have to do a left click for it to start reacting again. (which I also assume is something everyone with Mavericks is experiencing, but you need to use the keyboard a lot to notice it.
    But why Adobe hasn´t given a single reply to the threads (except those about the white menus) about these problems baffles me I guess if they don´t know of a quick fix, it´s better to ignore it entirely. I´m considering every day if I should take the time to revert back to Mountain Lion - though that isn´t exactly a tempting solution. It´s weird how Mavericks can create that many bugs to Photoshop and why there´s not any info on any bug fix updates in the near future. I´m paying a lot of money for this software. I should get better customer care for this. ...sorry for ranting, but it´s making me more frustrated every day.

  • Lasso tool not working at all. Please help!

    Hi Community. I just started the CC version of Illustrator and the lasso tools isn't working. I am able to select the tool and draw an outline with it, but nothing is selected when I make a closed loop. I cannot select anything in any way with the lasso tool. I have made sure that I am circling strokes that are on the active layer. Please help!! I'm currently stuck in my project as a result.
    -A

    What OS do you have, have you updated to thte latest  dot verison eg: 10.9.1?
    Reset your Illustrator preferences? Try making a new documnet really simple, to see if this happens on all documennts.

  • Is there a lasso tool in preview? Help!

    I am wondering if there is a way to have a 'Lasso Selection Tool' in preview. I see the option for the 'Rectangular Selection Tool', however I am struggling to find a way to find a Lasso selection. Help!!

    CMD ⌘ + Shift ⇧ + A. (key combination)

  • Photoshop Help | Selecting with the lasso tools

    This question was posted in response to the following article: http://helpx.adobe.com/photoshop/using/selecting-lasso-tools.html

    In Photoshop CS5 I was able to use the magnetic lasso, select a section from a photo and drag and drop the selection either in another Pshop or Illustrator doc. Now in Photoshop CS6 when I use the Magnetic Lasso and select an area of a picture, I get a bounding box with a white background that is coming with the selection.I am not getting just what I selected. Do I have something set up wrong, can someone please help with? Thank you....

  • Help Spice Feature Request Up, Another Gathering, Paintball Saturday?

    Hi all.
    I have a Spiceworks feature request that I'd like some help spicing up.  You can see it here:
    http://community.spiceworks.com/feature_request/show/Help%20Desk/5367
    Also, is it time for another get together yet?  I think so.  
    Anyone up for paintball Saturday morning?  I'll be there with full Multi-cam on :)  Oh, and I've never paintballed before.
    http://www.paintballjungle.com/
    Aaron
    This topic first appeared in the Spiceworks Community

    Hi all.
    I have a Spiceworks feature request that I'd like some help spicing up.  You can see it here:
    http://community.spiceworks.com/feature_request/show/Help%20Desk/5367
    Also, is it time for another get together yet?  I think so.  
    Anyone up for paintball Saturday morning?  I'll be there with full Multi-cam on :)  Oh, and I've never paintballed before.
    http://www.paintballjungle.com/
    Aaron
    This topic first appeared in the Spiceworks Community

  • Where can i find the magnetic lasso tool in adobe photoshop touch? i used it all the time before but suddenly cant find it please help

    i started my photoshop touch after some while and now i cant find the magnetic lasso tool it used to be there i used it all the time for editting but now i cant find it maybe i disabled it somehow. can anyone tell how to enable it again?

    I honestly don't remember a magnetic lasso tool. (I've been using PS Touch since version 1.0.) The closest things I can think of are the Quick Selection Tool, the Scribble Selection Tool and the Magic Wand Tool, all located under the same set of tools (3rd set from the top in the tool panel).

  • Feature Request: Color code lightroom folders

    I have several hundred folders inside of lightroom. I would like to colorcode "favorite" folders to make them easier to find when moving imported photos from "Dated" folders into subject specific folders. Seems like this should be easy,
    Or is there already a way to do this?
    Collections will accept selected pictures but how about selected folders?

    The place to add your voice to an existing feature request.
    http://feedback.photoshop.com/photoshop_family/topics/colour_coding_folders_and_collection s_to_simplify_navigation_cataloguing
    This is a user-to-user forum.

  • Need Help With Lasso Tool..........Plz

    Hi  I am doing a business card layout and I have an image to place into my document which will be placed on a gradient pattern.  I need to use the lasso tool on the image to place it into my document.  However, the lasso tool is picking up too many jagged lines from the image.  When I place the image in my document you can see the jagged edges on the outline.  How can I correct the image to not have jagged edges on the outline.  I have tried everything.  Thanks.

    Go to File>new>blank file. Duplicate the background layer, and apply the gradient.
    Open the car picture file, select the car using one of the selection tools, go to Edit>copy to place it on the clipboard
    Go back to the gradient file, go to Edit>paste. The car will be on its own layer
    Access the move tool, position the car and resize using the corner handles of the bounding box
    http://www.pixentral.com/show.php?picture=1vXIkFj9U83m8CZCQC3PBLACgkKIKB0
    This screen shot shows 2 boats on a complex background - see red arrow pointing to the photo bin.
    These were selected and placed via the recipe above. The layers are included for your reference.
    To make the subject blend into the background so that it does not look fake (as it does here), make Layer 1 active. Press CTRL on the keyboard and left click on the layer thumbnail..Go to Select>refine edge and adjust feather to suit.

Maybe you are looking for