Application Login Screen

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
gpearson
Posts: 84
Joined: Wed Feb 03, 2010 12:55 pm

Application Login Screen

Post by gpearson » Thu Feb 11, 2010 7:10 pm

As I work through my first runrev application I am to the point of creating a substack with a login card on it. On this card I have 3 labels and 3 text entry field plus 2 buttons. The issue which I am having is on all of my text entry fields, I am wanting to display what the user has entered into a field I call TraceField.

My code is

Code: Select all

put MediaIDField into tResult
answer information "User Entered Media ID of " & tResult
What I get back when running the card is
User Entered Media ID of MediaIDField
If I entered a 5 for the Media ID Field then I would think that my answer box would say something like User Entered Media ID of 5


Where am I overlooking on this.
---
Graham Pearson
Goshen, IN USA

We Are Closed Today is your single internet resource for Indiana Area School Closings, Visit http://www.weareclosedtoday.com

Dixie
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 1336
Joined: Sun Jul 12, 2009 10:53 am

Re: Application Login Screen

Post by Dixie » Thu Feb 11, 2010 7:39 pm

Hi...

In the script of the fld you are entering your 'MediaID', try

Code: Select all

on returnInField
/* if you want the entered number/text in tracefield add this line */
    put the text of me into fld "traceField"
/* or if you just want it in the answer dialog then just use*/
   answer Information " User Entered MediaID" && the text of me
end returnInField
Enter the ID number and press return...

hope this helps

be well

Dixie

Klaus
Posts: 14198
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Application Login Screen

Post by Klaus » Thu Feb 11, 2010 7:50 pm

Hi Graham,

to get the content of a field use this:
...
## Important to use QUOTES for names!!!!!
put the text of fld "MediaIDField" into tResult
...

Or simply:
...
put fld "MediaIDField" into tResult
...
does also work.

In your script:
...
put MediaIDField into tResult
...
MediaIDField is seen as a variable name by the engine and since you did not "fill" this variuable it just contains its own name!
Therefore you get "User Entered Media ID of MediaIDField".

Hope that helps!


Best from germany

Klaus

Post Reply