12-11-2017 04:50 AM
Hi,
I am execting a VI wich consists on download de font code of an specific web.
the following image works perfectly. as you see, the input string is an standard inpunt control.
where the front panel is:
I do not want to write the standard input directly, I want to pass it as string, this string will be different depends on the web page that I want to explore.
So the problem is that if I change the standard control input by a constant with the same text, it does not work.
As you can see, the standard input is the same but introduced in differents ways.
The error that appears is the following:
Please, Can you help me?
I attach the VI.
Thanks in advance.
12-11-2017 05:41 AM
Did you generate the string constant by typing or right clicking on the standard input control and then choosing "Create constant" from the context menu?
12-11-2017 05:43 AM
Hi,
right clicking on the standard input control and then choosing "Create constant"
12-11-2017 05:46 AM
Changing your control's display style to \ Codes, I see that you have "\n\n" at the end, indicating you have a couple of End Of Line characters. I am pretty sure you do not want those there. But it is hard to tell without the constant so I can examine it the same way.
12-11-2017 05:54 AM
what should I do?
I do not know how to visualize in \Codes.
12-11-2017 06:00 AM - edited 12-11-2017 06:03 AM
Hi aitor,
what should I do?
- always attach VIs (or snippets) instead of plain pictures!
- right-click the string constant and change the display mode…
- even better: make the display style item visible (right-click!) and select the display style with this item…
12-11-2017 06:01 AM
The context menu is your friend. For both the control and the constant. You can also choose to display the current style (Visible items -> Display Style).
12-11-2017 06:01 AM
Hi, the Vi is attached,
LA SOLUCIÓN ÉS AÑADIR UN ENTER EN LA LÍNEA DE COMANDA, NADA DE FORMATO NI NADA.
12-11-2017 06:02 AM
Hi,
LA SOLUCIÓN ES AÑADIR UN ENTER EN LA LÍNEA DE COMANDA,
THANKS
12-11-2017 07:01 AM
So it actually sounds like you have too many "enters" at the end of the command in your control (you had 2 when you should only have 1).
The formatting was purely to help understand exactly what you are sending. Right-click on the control and choose "Visible Items->Display Style". You should see a little glyph added to your string control (or constant) to show what the display style is. When using \ Codes, you will see things like \s for space, \t for a tab, \\ for \, and \n for an end of line ("enter").