Getting the line number of a script

Jim Ault JimAultWins at yahoo.com
Thu Jun 8 20:00:02 EDT 2006


I would use

get the script of this card
......then operate on the  it  variable.

I don't understand what you are actually trying to accomplish.
Do you want the actual line of the script?
The line number of the script?
Or the line number of the handler within the script?

One way of getting the line number is to make a comment at the end of the
line such as 
> 5   put (magical function/code to retrieve this line
> number) into tVar --locateThisKeyLine

Just need a few more details since this has more than one or two solutions.

Jim Ault
Las Vegas

On 6/8/06 10:56 AM, "Duong Le" <paladinx00 at yahoo.com> wrote:

> I'm looking for a way to get the line of a script.
> 
> For example,
> 1 global tVar
> 2
> 3 on mouseup
> 4   do stuff
> 5   put (magical function/code to retrieve this line
> number) into tVar
> 6   do more stuff
> 7 end mouseup
> 
> Basically I want "3" when I access tVar.  Putting the
> script of the object into a variable and then doing a
> lineoffset seems like it'd be too much work and give
> false results if the line of code appears more than
> once.  
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution





More information about the use-livecode mailing list