Welcome to the nuBuilder forums!

Please register and login to view forums and other content only available to registered users.

Lookup Text

Locked
armstrs01
Posts: 20
Joined: Tue Jul 14, 2015 5:00 pm

Lookup Text

Unread post by armstrs01 »

Another newbie question about the Lookup object...

How do I return the text from the Code Field or Description Field part of a Lookup object in Javascript?

In the example below, either "W0005F-03" (Code Field) or "eFX Relocation..." (Description Field).
mylookup.jpg
mylookup.jpg (128.38 KiB) Viewed 6147 times
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Lookup Text

Unread post by admin »

armstrs01,

I don't understand the question (what do you mean return the text?)

Steven
armstrs01
Posts: 20
Joined: Tue Jul 14, 2015 5:00 pm

Re: Lookup Text

Unread post by armstrs01 »

I want to be able to use the text from the Description part of the lookup in a Javascript alert message.

I want to be able to use/display the text "eFX Relocation (SWD Pre-Prod to TSQ Phase 2)" but I don't know how to refer to (get) that part of the Lookup object. If is say something like alert($('#ReleasedProj_ID').val())); I get the underlying code id, when I really want the Description.
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Lookup Text

Unread post by admin »

armstrs01,

Hit F12 in your browser and then click the icon in red.

Hover or click this on the fields who's name you want..
fieldnames.png
fieldnames.png (62.28 KiB) Viewed 6109 times
Steven
armstrs01
Posts: 20
Joined: Tue Jul 14, 2015 5:00 pm

Re: Lookup Text

Unread post by armstrs01 »

Got it! Works a treat.

Many thanks.
admin
Site Admin
Posts: 2781
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5
Been thanked: 1 time

Re: Lookup Text

Unread post by admin »

.
Locked