dpar:
--------------------------------------------------------------------------------
Hi,

Trying to write my first PSPad script (thanks for the fantastic editor).

It's a JScript and I want to know the current line:


    var line = myEditor.lineText();
    var lineNum = getVarValue("%Line%");
    echo(lineNum);


This returns an empty string into lineNum and the echo messagebox is blank.

Is there a way to do this I can't see?

Thanks,

dpar
--------------------------------------------------------------------------------


Hi dpar

i think %Line% is to use in Editor itself only, not in script function.

You may use 
var lineNum = caretX;
if i remember well :-/

See here for more help:
http://gogogadgetscott.info/pspad/scripts.htm

Script Language Reference ==> http://gogogadgetscott.info/pspad/functions.htm

-- 
greets,     Stefan
[img]http://pspad.milten.lima-city.de/Fan.gif[/img]  (pleased user since 1722)
[url=http://tinyurl.com/52xrj]inofficial FAQs[/url] +  
[url=http://forum.pspad.com/read.php?2,16286,page=2]Infos[/url] + 
[url=http://forum.pspad.com/read.php?6,24628]Special Settings[/url]

<http://forum.pspad.com/read.php?2,46907,46912>
PSPad freeware editor http://www.pspad.com

Odpovedet emailem