Academic Company Events Community Support Solutions Products & Services Contact NI MyNI
17 ratings:
 4 out of 5   

Can I Import an Image to Use for a VI Icon in LabVIEW?



Primary Software:
Primary Software Version: 8.6.1
Primary Software Fixed Version: N/A
Secondary Software: N/A

Problem: Can I import an image, such as a .bmp, .jpg, or .png file, to use for a VI icon? I have an existing image that I do not want to redraw in the Icon Editor dialog box. Can I import the image into LabVIEW without having to redraw or resize the image manually?

Solution:

You can drag an image from anywhere in your file system to the VI icon at the upper right corner of the front panel window or block diagram.

You also can copy an image to the clipboard and then paste the image into the Icon Editor dialog box.

Note: In LabVIEW 2009 and later, the Icon Editor dialog box provides an enhanced set of editing tools for creating icons. The Icon Editor dialog box provides icon templates, glyphs from the Icon Library at ni.com, options for adding and formatting icon text and support for editing with layers.

Complete the following steps to copy and paste an image into the Icon Editor dialog box.

  1. Copy the image to the clipboard in one of the following ways:
    • In a graphics editing application or Web browser, copy an image to the clipboard.
    • From the LabVIEW front panel window or block diagram, select Edit»Import Picture to Clipboard, and navigate to and select the image file.
        Note: In LabVIEW 8.0 or earlier, select Edit»Import Picture from File.
  2. Right-click the VI icon at the upper right corner of the front panel window or block diagram and select Edit Icon from the shortcut menu to display the Icon Editor dialog box.
  3. Select Edit»Paste to paste the image from the clipboard into the Icon Editor dialog box.
  4. Click the OK button to close the Icon Editor dialog box and apply the image as the VI icon.

LabVIEW supports most standard graphics formats. If LabVIEW does not support the type of image you want to use, you can use a third-party graphics format converter to convert the image to a supported type.

Refer to the LabVIEW Help, available by selecting Help»Search the LabVIEW Help, for more information about creating VI icons, importing graphics, and dragging and dropping objects in LabVIEW.



Related Links: KnowledgeBase 2IE9PUQ2: image.cpp, line 10809 Crash When Using the Set VI Icon Method
KnowledgeBase 2T2CG4TL: How Do I Load Images Into the LabVIEW Clipboard Within Various Operating Systems Which NI Supports?
LabVIEW 2009 Help: Icon Editor Dialog Box

Attachments:





Report Date: 08/21/2003
Last Updated: 09/13/2012
Document ID: 30KFGK2Q

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit