LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

silver style other style subVI

Solved!
Go to solution

When I create a control for a subVI it will always use the style used in the subVI. I want to create all my controls in Silver style, but now I am stuck between part silver style and part modern style. Is there a way to bypass the style of the subVI? If not, is there a way to create literally any control without using right-click create control on the subVI? 

 

PS. the last question is my problem mainly with DAQmx VI's. I don't know how to make a physical channel of the exact right type, for instance one that only recognises counters. If I create a physical channel in Silver style in the front panel, I will only be able to select analog inputs, regardless of whether I am connecting to a counter physical channel, analog output or analog input.

 

I am using Labview 14.01 (64-bit)

0 Kudos
Message 1 of 9
(3,689 Views)

@BramMooij wrote:

When I create a control for a subVI it will always use the style used in the subVI. I want to create all my controls in Silver style, but now I am stuck between part silver style and part modern style. Is there a way to bypass the style of the subVI? If not, is there a way to create literally any control without using right-click create control on the subVI? 

 

I'm not sure I understand your question.  If you are creating a control on the Front Panel, and your default Palette is the Silver Controls, then any Control/Indicator you place down should be Silver.  If you want to convert a Front Panel Control to its Silver counterpart, and Silver is the default palette, you can use Quick Drop.  Left-click the Control/Indicator, type Ctrl-Space to bring up Quick Drop, type the name of the Control (e.g. Error In), then type Ctrl-R (Replace).  Voilà.

 

PS. the last question is my problem mainly with DAQmx VI's. I don't know how to make a physical channel of the exact right type, for instance one that only recognises counters. If I create a physical channel in Silver style in the front panel, I will only be able to select analog inputs, regardless of whether I am connecting to a counter physical channel, analog output or analog input.

 

An I/O Channel is the same, regardless of the Style of the Control.  The value will differ depending on whether the device is Analog or Digital, Input or Output, but you should be able to put a Silver Physical Channel Control on your Front Panel and wire it to any DAQmx function (in the upper left corner, of course).  Just "adjust" the content of the Control as appropriate.

 

I am using Labview 14.01 (64-bit)

 

Why?  Do you really need the Address Space, and are you willing to give up the relative lack of 64-bit LabVIEW drivers and other support?  Most of us run LabVIEW 32-bit on Windows 64-bit


 

Bob Schor

 

0 Kudos
Message 2 of 9
(3,682 Views)

@Bob_Schor wrote:

BramMooij wrote:

I'm not sure I understand your question.  If you are creating a control on the Front Panel, and your default Palette is the Silver Controls, then any Control/Indicator you place down should be Silver. 


If you right-click a subVI terminal followed by "create control|indicator", you get the style used in the subVI, not the default for your environment.

0 Kudos
Message 3 of 9
(3,671 Views)

Hi Bob,

 

Thanks very much for your answers. We're not really on the same page yet, I hope my answers to your answers will clarify this. Hope you find the time to reply again.

 

________________________________________________________________________________-

Bob_Schor wrote:

I'm not sure I understand your question.  If you are creating a control on the Front Panel, and your default Palette is the Silver Controls, then any Control/Indicator you place down should be Silver.  If you want to convert a Front Panel Control to its Silver counterpart, and Silver is the default palette, you can use Quick Drop.  Left-click the Control/Indicator, type Ctrl-Space to bring up Quick Drop, type the name of the Control (e.g. Error In), then type Ctrl-R (Replace).  Voilà.

 

Thanks for the reply. underston the first question. The subVI's style determines the style of the control you make, the built in functions of LabView do follow what you're stating. Indeed, replacing is an option which I don't mind too much, but I want people who use and adapt the code after me to not have to go through such a tedious and indirect process. I would like to find a way to bypass this feature where controls are automatically in the subVI's style.

 

 

 An I/O Channel is the same, regardless of the Style of the Control.  The value will differ depending on whether the device is Analog or Digital, Input or Output, but you should be able to put a Silver Physical Channel Control on your Front Panel and wire it to any DAQmx function (in the upper left corner, of course).  Just "adjust" the content of the Control as appropriate.

 

I'm afraid you misunderstood my question. I am unable too choose anything else but analog inputs when I connect the physical I/O channel to any "Create Virtual Channel", whether it's a counter, analog output or analog input. The options I can select are limited only to the inputs that actually fit the channel (if I use modern controls), and in the Silver case where I make a physical channel on the front panel I am limited only to the analog output. Indeed, I can make modern controls, select the input I want, convert them to Silver controls and it works. However, I am then unable to change the physical channel without first changing back to modern and selecting the channel I want (for instance I cannot change my counter from Dev1/ctr1 to Dev1/ctr0 without doing this).

 

 

I am using Labview 14.01 (64-bit) Why?  Do you really need the Address Space, and are you willing to give up the relative lack of 64-bit LabVIEW drivers and other support?  Most of us run LabVIEW 32-bit on Windows 64-bit

I have no real reason to run the 64-bit version of LabView. The computer I am using now is not a research computer (just my office computer with an old DAQ board), I'll be sure to think about this regarding the choice of LabView version on the lab computer. Judging from the national instruments link I found it's probably better if I keep to the 32-bit version in the end.

 

0 Kudos
Message 4 of 9
(3,634 Views)

You are correct -- I misunderstood the nature of your question.  I knew about the default behavior, but didn't think you would be "designing" new Front Panel Controls by right-clicking on the Block Diagram and choosing "Create Control", so I told you how to, after-the-fact, "fix" it on the Front Panel.  Incidently, I even made a mistake there -- the correct Quick Drop command for Replace is Ctrl-P (my fingers know this, my head doesn't).

 

I am astonished that the Silver I/O Constants are so limited.  I'll play a bit with this (now that I understand what you were saying) and see if I have any Bright Ideas.

 

Bob Schor

Message 5 of 9
(3,628 Views)

Thanks a lot.

 

I know for a fact that Silver I/O Controls don't have to be this limited, for I can copy them from the example VI's, I just haven't found out how to make them in a smarter way than copying from an example VI. Unfortunately your fix works only partially (just answering extra in case it wasn't clear from my last post), if I use that and have already got the right input set it will stay there (default value), but I can't choose anything else than the analog inputs.

 

Look forward to your findings.

0 Kudos
Message 6 of 9
(3,610 Views)
Solution
Accepted by topic author BramMooij

I found the solution to how to create a proper control in the silver way. It turns out the issue is unrelated to the silver style.

 

If you create a new physical control and just connect it to a "DAQmx Create Virtual Channel VI", you will only be able to select analog inputs (in my case at least). This holds both for silver and modern controls. However, a right click on the control on the front panel and then selecting I/O name filtering allows you to select the I/O type. Here you can change the behaviour of the control to Analog Output, Digital Input, Digital Output, Counter etc. 

 

Thanks a lot for your efforts, sorry this turned out to be a question I should've been able to solve earlier myself. 

 

If there is anyone who knows of a direct override to creating a control in the style of the subVI, please post :). 

0 Kudos
Message 7 of 9
(3,581 Views)

I'm glad you found how how to fix this.  I must confess that when I tried (very briefly, as I was too busy today), I couldn't see the problem, it seemed to work (for me) regardless of Analog or Digital, Input or Output.

 

BS

0 Kudos
Message 8 of 9
(3,543 Views)

Do you mean that you didn't have to change any setting for the silver control to work properly (so just create the control on the front panel, connect it in the block diagram and it immediately shows you the right inputs)? If so I reckon it's a bug in my specific version. 

0 Kudos
Message 9 of 9
(3,520 Views)