LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Counting letters

Ok so here is where I am at now, I am missing something, how do I count the letters? Is there something I am missing in my formula

0 Kudos
Message 11 of 19
(1,196 Views)

This is where I am now, I just cant figure out how to count the letters.  I am not sure what to hook the Number indicator up to.  All it has to do is count the how many letters in the persons last name so if it was, Jet Li, last name would be 2.

 

Any suggestions you have are greatly appreciated

0 Kudos
Message 12 of 19
(1,194 Views)

Perhaps a function that is named something like "String Length" would be useful?

0 Kudos
Message 13 of 19
(1,193 Views)

@Ravens Fan wrote:

Perhaps a function that is named something like "String Length" would be useful?


If only some genius had thought of creating such a function...

 

LabVIEW Idea Exchange, here I come!  I can just see all the Kudos flowing in. Pshaw on the improved Boolean constant.

Message 14 of 19
(1,158 Views)

Here's a hint:

You will need the following elements on your front panel: (the grey screen)

 

A String Control named "Name"

A String Indicator named "Greeting"

A Numeric Indicator named "Last Name Length"

 

You will need the following elements on your block diagram: (the white screen)

 

The terminals for "Name", "Greeting", and "Last Name Length"

Three (3) functions from the string palette

One (1) function from the numeric palette

Two (2) String Constants

 

 

*NOTE* The suggested number of functions is how many I used to solve your problem.
I'm sure the Knights of NI who have responded to this thread could solve it using fewer functions.

 

I have decided to make a Rube Goldberg VI for this problem mainly because my tasks are low at work today (i.e. documentation day)

but also to hopefully entertain the aformentioned Knights. (also, couldn't it just be kNIghts?)

Message 15 of 19
(1,138 Views)

Hi,

 

this may help,

 

Using the match pattern, search for the space string charactere, then keep the part before and you'll get your name.

-get the second part and you will get your surname, then use a string lenght to know the number of letters.

 

NB: you also can have a look at the labview help, using the help menu--> find exemple.

 

Stoad.

 

0 Kudos
Message 16 of 19
(1,119 Views)

Stoad,

 

This is homework.  You want to help guide them to the answer, not do the work for them.

0 Kudos
Message 17 of 19
(1,114 Views)

@stoad wrote:

Hi,

 

this may help,

 

Using the match pattern, search for the space string charactere, then keep the part before and you'll get your name.

-get the second part and you will get your surname, then use a string lenght to know the number of letters.

 

NB: you also can have a look at the labview help, using the help menu--> find exemple.

 

Stoad.

 


In the future, please refrain from doing somebody's homework. This is not a homework writing service.

0 Kudos
Message 18 of 19
(1,108 Views)

I'll assume the homework is already due, I almost posted this earlier with an evil grin thinking about someone (who needed help with this problem) using it then being forced to explain to the teacher what the code was doing.

 

SillyHW.png

 

 

Message 19 of 19
(1,037 Views)