Create a customer code using the First letter of a customer name and the last 4 digits of a phone number

I am trying to create a form where one the customer has input their name and phone number it should grab the first letter of the customer's name and then the last 4 digits of the phone number.
I am not very good at coding, and have VERY VERY limited background in coding. I understand a little (the basics pretty much).
I am thinking i am not using the right expression to get what i want. Below is the statement I have write. This is just to find the first letter of the name, have an idea on how to get the phone number but i was trying the use the "left" and "right" functions but they wouldn't work. More specifically the left.
form1.#subform[0].CustCode::initialize - (JavaScript, client)
str = CustName;
var a = str.substr(0, 1);
any help would be greatly appreciated.
If more information is needed, please don't hesitate to ask.

If you switch your language to FormCalc you can use the Left and Right functions, e.g.
Concat(Left(Name,1) , Right(Phone,4))

Similar Messages

  • Help please - have a Nano and a Shuffle and neither are working! The Nano wheel appears to have stopped working - I can't get it to do anything. I've done the reset,it worked the first time but not since. And the shuffle won't sync with my library!

    Hi,
    I have an iPod shuffle 4th generation and an iPod Nano 5th generation . The Nano wheel appears to have stopped working - I can't get it to play or anything. I've done the reset and it worked the first time, but now the only way I can get it to play anything is to shake it and go with the shuffle choices - I can't change volume, song, pause or turn it off.
    So, I decided to start using the Shuffle which I was given as a present last year. I've plugged it into my laptop (running windows 8 and newest version of iTunes). It appears in iTunes on the left hand side, but when I click to sync (whether I tick sync all or choose artists) it says synched but has no music. It seems to not be linked to the music library - when I tick synch all songs, next to the "sync music" it says 0 songs?
    Any help to fix either would be really appreciated - I'm without any music at the moment and I'm going away this weekend!
    Thanks

    Hi Bblairjones,
    If you are having issues with your Nano and Shuffle, you may want to try the Troubleshooting Assistants on the following page:
    Apple Support: iPod Troubleshooting Assistants
    http://www.apple.com/support/ipod/five_rs/
    Regards,
    - Brenden

  • HT1918 how can i get the first device i put in out and the second one to stay in without time restrictions?

    So I've been having an apple account before I got my first and only iphone. But I plugged in my friend's device first into my account and the account read it as the owner device of the ID. Two days later, I plugged in my device and read it as a second device in the accound and therefore, my device is just "borrowing" the ID and it set a time limit to use it. But it needs to be the other way around. The first device is not mine and I want it out, and I want the second device in as the owner of the apple account.
    What do I do?
    I've already removed the first device,but it still has a time restriction on the second device. THE SECOND DEVICE IS MY DEVICE AND ITS MY ACCOUNT!

    "Well, since its the first device into the account, I guess the account read it as the "owner" device of the account."
    There is no such thing as "owner" device at all.
    "Apparently, the account read it as the second device and thought that it was "borrowing" the account since it was the second device"
    There is no such thing as "borrowing" the account.  You can use your account from ANY device/computer that has itunes.
    You seem to completely misunderstand the way it works.
    There is no time limit.  You are confucing your account with associated devices:
    iTunes Store: Associating a device or computer to your Apple ID
    If you want to buy music from your iphone, simply go to Settings and sign into your account.
    The musci your friend bought using your account belongs to you and it is not legal from your friend to use.
    iPhone User Guide (For iOS 6 Software)

  • I think I finished installing Mountain Lion, and am at the "log in" page with my name and the Lion icon, but I cannot do any of the functions on screen. That is, I cannot log in, sleep, restart, or shut down. I am running it on an Early 2009 Macbook Pro

    I think I finished installing Mountain Lion, and am at the "log in" page with the Mountain Lion icon, but I cannot do any of the functions on screen. That is, I cannot log in, sleep, restart, or shut down. I am running it on an Early 2009 Macbook Pro, which is said to have the capabilities of running Mountain Lion.

    BrettGoudy wrote:
    ...Is there any way I can install a partition that runs snow leopard on my early 2011 MB pro with what I have (new SSD, New RAM, Current version Lion running, no external drive, lack of original snow leopard disks [I lost them ] and the general 10.6.3 snow leopard boot disks)...
    As the last post suggests, call Apple and order a replacement original disc for about $17.  They will ask you the model and serial numbers.
    Your retail version of Snow Leopard OS 10.6.3 will not work on that Mac as it requires a minimum of OS X 10.6.7 to boot and operate.
    Another alternative is to again borrow another Mac to install your retail Snow Leopard into an external HD or partition, upgrade it to 10.6.8 and then clone it back to a partition on your MBP.

  • I temporarily have to use a blackberry curve for a few days and I need to disable my phone number from my apple ID so I can receive text messages from people.  How do I do this???

    Help! I need to disable my phone number from my apple id

    Read here:
    http://support.apple.com/kb/ts5185

  • How to get the first letter alone in Upper case?

    SQL*Plus: Release 9.2.0.1.0 - Production on Thu Jan 15 11:13:44 2009
    Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production
    With the Partitioning, OLAP and Data Mining options.
    Hi all,
    Sorry if i am posting this one as a clone. I want the first letter alone in UPPER case in the given data. Is there any specific SQL function to do it or can we do it in REGEXP?
    I have tried with this below one query.
    select Upper(substr('oracle code',1,1))||substr('oracle code',2) from dual;
    Oracle code
    Is anything better than this in performance wise? If so please help me.
    Thanks,
    Ram

    Hi,
    what if the string is like this
    SELECT INITCAP(substr('oracle code Error ', 1, instr('oracle code Error ', ' '))) ||
           substr('oracle code Error', instr('oracle code Error ', ' '), length('oracle code error '))
    FROM dual;

  • How do i stop firefox from auto suggesting my email adress after i type the first letter

    after the first letter typed it comes up with lots of suggestions even ones i've typed by mistake and i would like to clear these

    You can very quickly eliminate the mistyped entries with the down cursor key and use of "Del" key on the selected item ("Shift+Del" on a Mac). So you would just have the ones you want. You do not need to type the first letter you can double-click within the entry box to see all items whether to use or to delete.
    That does not answer what you asked. If you only want to suppress that, I don't think that would be possible with Firefox alone, but I also would not think that you would want to suppress all autoform entry because of that.

  • Ideas on how to use p:first-letter

    Hi,
    Any ideas on how to get the first letter in a paragraph
    floating in the
    text, to the left, so that the top of the letter lines up
    with the top
    of the first line, and the bottom of the letter lines up with
    the bottom
    of the third line?
    For some reason I am not able to set the line-height of the
    first-letter, so it starts in the wrong place.
    Thanks!
    Misha

    Hmm does not look right on my firefox (mac 1.5). The drop cap
    starts too
    low (I think it is keeping the line-height or margin of the
    paragraph). Looks worse in safari.
    Odd that this is such a problem for good browsers. I think IE
    gets it right.
    Gary White wrote:
    > On Fri, 06 Apr 2007 16:16:01 -0400, Misha Cohen
    <[email protected]>
    > wrote:
    >
    >
    >>Still looking for a fix for this (or a reason why it
    isn't working).
    >
    >
    > I don't know why yours isn't working. I was playing with
    this a while
    > back:
    http://testing.apptools.com/experiments/drop-cap/
    >
    > It works well in both IE6/7 and Firefox, but gets pretty
    ugly in Opera.
    > Because of that, I left the example on my site using
    spans:
    >
    http://apptools.com/examples/dropcap.php
    >
    > Gary

  • HT203477 Font inspector when creating titles, do you seriously have to scroll in order to go to the font instead of typing the first letter?

    There has to be something wrong with the font inspector.. When I create a title and I want to change the font I press the pull-down menu for all my fonts. The default font if Helvetica and I press the letter F to find Futura. The problem is it doesnt matter wich letter on the keyboard I press cause it automaticly goes to the top and i have to scroll thru all my fonts to find the one I was looking for. There has to be something wrong. Im new to fcpx but there is no way I cant just press the first letter of the font im looking for in order to go to "that" section. I press f-key to go to the section of the fonts that starts with the letter F.
    Im going mad even the turds on youtube that have tutorials for doing titels are scrolling thru all of their fonts to get to the one they want.. seriously..?
    Am I doing something wrong?

    No you are not doing anything wrong.  Perhaps it is like this because those single keys are shortcuts that the app uses, I do not know tho. It doesn't bother me. I stopped drinking coffee, perhaps...
      Perhaps someone has (or will be) creating a third party Plug-In for this. Get rich!
       No, really... here is what you do. Go to the Final Cut Pro menu and use the "Provide Final Cut Feedback" feature. They'll fix it the way you want.
    Hope This Helps

  • How to Capitalize the first letter or an entire word using a shortcut on the keyboard just like in microsoft that uses shift+F3

    please how can one How to Capitalize the first letter or an entire word using a shortcut on the keyboard just like in microsoft that uses shift+F3

    What do you mean there was "no effect?" I'm not aware of any effects.
    It looks like that Service is also in the App Store. From their screen shots, the services are prefaced with WordService:
    You can see an example in the App Store for their app: App Store
    After installing, you should now have those text services in your Services menu. You can then add shortcuts in the Keyboard System Prefs.
    Most Apple apps have a Transformations menu in the Edit menu. You can Make upper, lower, and Initial caps with those. I would stick with Word Services, but you can make Application Shortcuts for the items in the Transformations menu.
    Again, in Keyboard System Prefs, Under Applications, Click the Add button on the right side pane.
    Set it for All Applications
    Enter the menu command exactly as they appear in the Transformation menu (separate entries for each),
    Make Upper Case
    Make Lower Case
    Capitalize
    Give them a shortcut.

  • I was set up to use mac mail but it is slow so I have switched back to gmail. When I write an email the first letter of each sentence does not capitalize and it use to. what do i do...

    When I bought this computer it was set up for mac mail but i am not using it it's to slow. i am using my gmail thru safari and when I type an email the first letter of each sentence is NOT capitalized and it use to be, any help is appreciated.

    Talk to Google. Gmail is not an Apple product. Writing an email message is using the Google editor.

  • I deleted a specific website from the "History" and used "forget this site" but it still shows up when I type the first letter of the site. How do I delete it?

    I am not computer savvy. I don't want to clear all my history, just one specific site. I deleted it, its cookies, passwords and everything and when I type the first letter of the website in, it shows up as one of the options for websites. I need to delete it, but how?

    Maybe these will help?
    *http://kb.mozillazine.org/Deleting_autocomplete_entries
    *[[Remove websites from the Awesome Bar suggestions]]
    It's possible the website is in your bookmarks and when you type in some letters in the Location Bar that match that bookmark, it is coming up from there. See [[Search your bookmarks, history and tabs with the Awesome Bar]] for details on changing your Location Bar settings in your [[Options Window - Privacy panel|privacy settings]].

  • Making the first letter of every word a capital

    hello CF oracles
    could you guys please advise me the best way to make the
    first letter in every word of a string a capital letter. (and make
    all the other letters lower case).
    eg. convert "the quick brown fox" into "The Quick Brown Fox"
    or convert "THE QUICK BROWN FOX" into "The Quick Brown Fox"
    I am taking form data and inserting it into my table, so i
    want to get it right as the data is inserted.
    i found a "UDF" on CFLIb.org that proports to do this, but i
    don't know how to set up a UDF, are there other ways or is this
    considered the best approach.
    http://www.cflib.org/udf.cfm?id=9&enable=1
    thanks for any help you can give me

    found it, here's the top info, Titlecase is what you want for
    this.:
    changecase.cfm
    Rev 1.01
    cf_changecase is a simple custom tag to format case in given
    string.
    (c) 2001, Rizal Firmansyah, [email protected]
    Input var:
    * case (mandatory)
    possible inputs are
    - sentencecase: Sentence case (default)
    - titlecase: Title Case
    - lowercase: lowercase
    - uppercase: UPPER CASE
    "happysailingdude" <[email protected]> wrote
    in message
    news:e46tjv$e30$[email protected]..
    > hi Dan thanks very much. I have made an executive
    decision to do a bit of
    > a
    > hack for now as my site is only small so if a user
    enters something in the
    > wrong way i can quickly manually update it myself.
    >
    > so now i have this which works 9 times out of ten if the
    user enters a one
    > word name eg "bill" or "fred" of "jane" then it works
    just fine
    >
    > the only time it doesnt work is if the user's name is
    more than 1 word (or
    > is
    > hyphenated) eg "mary anne" or "anne-marie" hence the
    first cfif line - in
    > these
    > cases i can manually update
    >
    > i put this here in case it is of use to anyone else
    >
    > cheers
    >
    > <cfif not (FORM.firstName contains " " or
    FORM.firstname contains "-")>
    > '#Left( UCase( "#FORM.firstName#" ), 1 )##Right( LCase(
    > "#FORM.firstName#" ), Len("#FORM.firstName#" ) - 1 )#'
    > <cfelse>
    > '#FORM.firstName#'
    > </cfif>
    >

  • Pagnation by the first letter of the last name

    Hello,
    I have a report that is Grouped by Cities and then Last Name.  So New York is the city and then all the customers are listed below in Ascending order starting with the first customer who last name begins with the letter A and continues thru to Z and then the next City Starts with it's customers listed A thru Z.
    What I need now is to have the report put the customers on a new page when the first letter of the last name changes.  So New York will have it's cutomers with last names that start with A on page 1 and end on page 2 and New York customers with last names that start with B will start on page 3 and end on 5 and so on.  How do I achieve this?
    Thanks,
    Heather

    So if you have a last name field, and the names are in the detail section simply do this:
    1 - Go to the section expert for the detail section.
    2 - Click on the X-2 button to the right of New Page Before
    3 - In the formula editor use the following (with your last name field instead of my generic fieldname):
      not onfirstrecord;
      LEFT (, 1) <> PREVIOUS (LEFT(, 1))
    4 - Save & close the formula and OK out of the section expert.

  • How to set my pages to capitalise the first letter?

    IO am not able to capitalise the first letter automatically in documents i am creating, it seams that pages is getting wors every time the new update comes out.

    I agree, sharing options taken out, no capitalisation, sharing only link, how can i do it for those that uses microsoft, it was so easy earlier.  Why is that happening, looks like a factory workers or giant team working on this one simple application and it takes ages to correct simple mistakes. thank you anyway for your help.

Maybe you are looking for