Skip to search.

Breaking News Visit Yahoo! News for the latest.

×Close this window

ntb-clips · The NoteTab Clips List

The Yahoo! Groups Product Blog

Check it out!

Group Information

? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Messages

Advanced
Messages Help
Messages 18756 - 18785 of 23887   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Show Message Summaries Sort by Date ^  
#18756 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Mon Dec 1, 2008 12:00 pm
Subject: Re: NAND per sand (NOT Ampersand)
ebbtidalflats
Send Email Send Email
 
Thanks Sheri,

It never ocurred to me that NoteTab sees the argument as multi-line.


Regards,


Eb



--- In ntb-clips@yahoogroups.com, "Sheri" <silvermoonwoman@...> wrote:
>
> --- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@>
> wrote:
> >
> > The problem:
> >
> > When I use ^& as argument passer, AND there are more than one
> > line of text in the "Sample Text" clip, the code [^!Set
> > %arg%=^$StrReplace("^%nl%^%nl%^%nl%";"^%nl%^%nl%";"^%arg%";0;0)$]
>
> That's not what is causing the pasting. I believe the problem is that
> only the first line of temp is making it to the StripDoubleBlankLines
> clip. Since the rest is "bare text" it is getting pasted. NoteTab
> doesn't have multiline command capability and it is expanding the
> variable inline. So you cannot pass multiline data (and calling it an
> array doesn't help).
>
> Regards,
> Sheri
>

#18757 From: "Flo" <flo.gehrke@...>
Date: Mon Dec 1, 2008 1:28 pm
Subject: Re: NAND per sand (NOT Ampersand)
jonas_ramus
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@...>
wrote:
>
> I have a user-defined function (custom function) which under
> SOME conditions does not execute its code as expected...
> When I use ^& as argument passer...

Eb, Sheri,

I think one questions was how to use "^& as argument passer". I can't
see how anything is "passed" here at all with...

^!Set %arg%=^&

It has been said that the ^& token works as a "shorthand for
preselected text (Sheri in a previous message)". Also it's a
shorthand for a parameter that is passed over to a sublip (see my
examples below). But Eb's clip doesn't select anything.

For me, a working Custom Clip Function -- similar to Eb's concept --
would be...

H="Test_Manager"
^$StripDoubleBlankLines$

H="_StripDoubleBlankLines"
; long line start
^!Set %arg%=^$StrReplace("^%nl%^%nl%^%nl%";"^%nl%^%nl%";"^$GetClipText
("Sample Text")$";0;0)$
; long line end
^!If ^$StrPos("^%nl%^%nl%^%nl%";"^%arg%";0)$>0 SKIP_-1
^!Result ^%arg%

Actually, it's a miracle for me how Eb's concept gets to any output
at all. Which command in his clip is producing the output of
paragraph #2 to #3 of the Sample Text clip?

Flo


P.S. If I'm not mistaken, these are three examples for the use of ^&

1. Select any text in a document and display it with...

^!Info ^&

2. Put a preselected word into a Wizard field...

^!Set %text%=^?[Select text first=^&]
^!Info ^%text%

3. Pass a parameter over to a subclip...

; Start Clip
^!Clip "Names" George

; Subclip "Names"
^!Info The name is ^&

#18758 From: "Sheri" <silvermoonwoman@...>
Date: Mon Dec 1, 2008 2:21 pm
Subject: Re: NAND per sand (NOT Ampersand)
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@...>
wrote:
>
> Thanks Sheri,
>
> It never ocurred to me that NoteTab sees the argument as multi-line.
>
>
> Regards,
>
>
> Eb

NoteTab has functions to use and remove tokens.

If in Test_Manager you change the call to this:

^!SetArray %article%="^$StripDoubleBlankLines(^$usetokens(^%temp%)$)$"

and in ^$StripDoubleBlankLines$ make this change:

^!Set %arg%=^$RemoveTokens(^&)$

I think it will do what you were expecting.

Regards,
Sheri

#18759 From: "Sheri" <silvermoonwoman@...>
Date: Mon Dec 1, 2008 2:36 pm
Subject: Re: NAND per sand (NOT Ampersand)
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "Flo" <flo.gehrke@...> wrote:
>
> --- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@>
> wrote:
> >
> > I have a user-defined function (custom function) which under
> > SOME conditions does not execute its code as expected...
> > When I use ^& as argument passer...
>

Hi Flo,

That was a misstatement. ^& is not an argument pass-er, it is the
argument pass-ed.

You can send optional text or data to a clip. If a clip refers to ^&
it is getting that optional "argument". If nothing has been explicitly
sent, it uses selected text in the document.

For example:

H="Test Hello"
^!Clip "Hello" Flo

H="Hello"
^!InsertText Hello ^&

Running the test clip would have the same result as running hello clip
after preselected "Flo" in the current document.

Regards,
Sheri

#18760 From: "Sheri" <silvermoonwoman@...>
Date: Mon Dec 1, 2008 3:14 pm
Subject: Re: NAND per sand (NOT Ampersand)
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "Flo" <flo.gehrke@...> wrote:

> Which command in his clip is producing the output of
> paragraph #2 to #3 of the Sample Text clip?

It is not a command producing the output -- it is the lines of text
with no commands that exist in the test clip after expansion of
^%temp% variable.

Regards,
Sheri

#18761 From: "Edward" <ebrown1927@...>
Date: Mon Dec 1, 2008 8:57 pm
Subject: beginners clip tutorial
horsefly_38866
Send Email Send Email
 
I have a couple of questions, I searched for and did not find, searched wrong
places I guess, a beginners tutorial for writing clips.  Someone point me that
direction please. That is if anyone is back from the Christmas shopping
experience of 2008.
Ed

[Non-text portions of this message have been removed]

#18762 From: "Edward" <ebrown1927@...>
Date: Mon Dec 1, 2008 10:06 pm
Subject: changed from nt-NTO
horsefly_38866
Send Email Send Email
 
Edward wrote:
> I have a library, "MY CLIPS 2" that is corrupted and I would like to delete
the Library. But it won't let me. Maybe a read only thing, how do I remove the
read only and make so that I can make changes to it or delete the thing.  Is
there a ntb-General list for questions relating to Notetab in General?
> Ed
>
>
Don wrote:
>Ed, a library would be under clips.

>The issue is possibly one of write permissions or location, depending on
what you are trying to do.

>Try adding a clip to the library.  If you can then I believe you have
proper permissions.

>The next issue is figuring out where it is.  Most are now under user
settings/application data instead of in the notetab folder as you might
expect.

Don,
today I cannot add a clip to a library or delete a clip from a library. Last
week I could. When I click on add from the clipboard, and I had a clip on the
clipboard nothing happened, nothing. Same when I clicked on a clip in a library
and selected Delete.  Nothing.   And this os is Vista, where do I find
user/settings/applications data. And I am still using Notetab Pro 4.95
------------------------------------

Yahoo! Groups Links




[Non-text portions of this message have been removed]

#18763 From: Axel Berger <Axel-Berger@...>
Date: Mon Dec 1, 2008 10:09 pm
Subject: Re: [Clip] changed from nt-NTO
absalom_nemini
Send Email Send Email
 
Edward wrote:
> today I cannot add a clip to a library or delete a clip from
> a library. Last week I could.

Have you run scandisk? This sounds like corruption.

Axel

#18764 From: "Sheri" <silvermoonwoman@...>
Date: Mon Dec 1, 2008 11:04 pm
Subject: Re: changed from nt-NTO
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "Edward" <ebrown1927@...> wrote:

> today I cannot add a clip to a library or delete a clip from a
library. Last week I could. When I click on add from the clipboard,
and I had a clip on the clipboard nothing happened, nothing. Same when
I clicked on a clip in a library and selected Delete.  Nothing.   And
this os is Vista, where do I find user/settings/applications data. And
I am still using Notetab Pro 4.95

4.95 is not Vista-ready. It would be best to upgrade.

In 4.95 NoteTab's ini file and clip libraries are stored in the
NoteTab application folder, which in normal circumstances is under
Program Files. Vista does not allow programs to write in Program Files
area. If you're determined to stay with 4.95, the easiest thing would
probably be to move the NoteTab application folder out of Program
Files and into My Documents. Otherwise you will need to change the
properties of Notepro.exe (compatibility) so that it "Always Runs as
Administrator". You would probably also to log in as an adminstrator
to use the program.

#18765 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Tue Dec 2, 2008 9:14 pm
Subject: Re: NAND per sand (NOT Ampersand)
ebbtidalflats
Send Email Send Email
 
Thanks, I'll give this a try out of curiosity.

I gather you are suggesting that ^& will not stumble over the newlines.

On the other hand, using ^%temp% as global variable (no ^&),
it works too.


Eb

--- In ntb-clips@yahoogroups.com, "Sheri" <silvermoonwoman@...> wrote:
>
> --- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@>
> wrote:
> >
> > Thanks Sheri,
> >
> > It never ocurred to me that NoteTab sees the argument as multi-line.
> >
> >
> > Regards,
> >
> >
> > Eb
>
> NoteTab has functions to use and remove tokens.
>
> If in Test_Manager you change the call to this:
>
> ^!SetArray %article%="^$StripDoubleBlankLines(^$usetokens(^%temp%)$)$"
>
> and in ^$StripDoubleBlankLines$ make this change:
>
> ^!Set %arg%=^$RemoveTokens(^&)$
>
> I think it will do what you were expecting.
>
> Regards,
> Sheri
>

#18766 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Tue Dec 2, 2008 9:31 pm
Subject: Re: NAND per sand (NOT Ampersand)
ebbtidalflats
Send Email Send Email
 
Flo,

You're right, I did not provide for visible output in the demo.
I guess I should have done so to remove ambiguity.

The test manager  clip stored the output of the UDF in the array
variable "article".

Whenever the UDF pasted to the current doc, it was an ERROR. Which I
wanted to demonstrate.


Regards,


Eb

--- In ntb-clips@yahoogroups.com, "Flo" <flo.gehrke@...> wrote:
>
> --- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@>
> wrote:
> >
> > I have a user-defined function (custom function) which under
> > SOME conditions does not execute its code as expected...
> > When I use ^& as argument passer...
>
> Eb, Sheri,
>
> I think one questions was how to use "^& as argument passer". I can't
> see how anything is "passed" here at all with...
>
> ^!Set %arg%=^&
>
> It has been said that the ^& token works as a "shorthand for
> preselected text (Sheri in a previous message)". Also it's a
> shorthand for a parameter that is passed over to a sublip (see my
> examples below). But Eb's clip doesn't select anything.
>
> For me, a working Custom Clip Function -- similar to Eb's concept --
> would be...
>
> H="Test_Manager"
> ^$StripDoubleBlankLines$
>
> H="_StripDoubleBlankLines"
> ; long line start
> ^!Set %arg%=^$StrReplace("^%nl%^%nl%^%nl%";"^%nl%^%nl%";"^$GetClipText
> ("Sample Text")$";0;0)$
> ; long line end
> ^!If ^$StrPos("^%nl%^%nl%^%nl%";"^%arg%";0)$>0 SKIP_-1
> ^!Result ^%arg%
>
> Actually, it's a miracle for me how Eb's concept gets to any output
> at all. Which command in his clip is producing the output of
> paragraph #2 to #3 of the Sample Text clip?
>
> Flo
>
>
> P.S. If I'm not mistaken, these are three examples for the use of ^&
>
> 1. Select any text in a document and display it with...
>
> ^!Info ^&
>
> 2. Put a preselected word into a Wizard field...
>
> ^!Set %text%=^?[Select text first=^&]
> ^!Info ^%text%
>
> 3. Pass a parameter over to a subclip...
>
> ; Start Clip
> ^!Clip "Names" George
>
> ; Subclip "Names"
> ^!Info The name is ^&
>

#18767 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Tue Dec 2, 2008 9:54 pm
Subject: Re: changed from nt-NTO
ebbtidalflats
Send Email Send Email
 
Hi Ed,

Generally, you're talking about a clip library, so stretch the point
and call this the correct forum. Even if most of my suggestions are
more OS related, than NoteTab.

Three DIFFERENT suggestions to try:

1. See if the file is open in another application
    Just selecting a file in the explorer will prevent
    you from deleting it in NoteTab.

2. In NoteTab, Documents menu, click the read-only entry.
    Now see if you can edit the file and save it.
    Perhaps you can save it to a different name?
    a. At best you'll have a working library
    b. at worst you'll have TWO files you can't delete.

3. Check the owner of the file (administrator ?)
    Change to the owner account, and delete the file.

Cheers,

Eb


--- In ntb-clips@yahoogroups.com, "Edward" <ebrown1927@...> wrote:
>
>
> Edward wrote:
> > I have a library, "MY CLIPS 2" that is corrupted and I would like
to delete the Library. But it won't let me. Maybe a read only thing,
how do I remove the read only and make so that I can make changes to
it or delete the thing.  Is there a ntb-General list for questions
relating to Notetab in General?

#18768 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Tue Dec 2, 2008 10:24 pm
Subject: Re: beginners clip tutorial
ebbtidalflats
Send Email Send Email
 
Ed,

This may not be your cup of tea, but I learned Clipping by reading the
help file.

Start by reading about Variables and Labels. Help menu, Help on clip
programming.

Pay particular attention to the caret with variables

^!Set %varnameWithOUTprecedingCaret%=^%varnameWITHCaret%

The caret ('^') is NoteTab's PARSING semaphore. Whenever NoteTab
encounters a caret it tries to parse the following word, according to
the rules the special symbol wrapper requires.

The most important such symbols are !, $, and %.
^!text(SPACE) is a command
^$text$ is a function (returns a value)
^%text% is a variable (returns a value stored in the variable)

This micro tutorial and the help files ought to give you a good start
in clip programming.

If you linve in the Houston Texas area, look for announcements on the
Houston Area League of PC Users (HAL-PC.org) - Clear Lake Educational
Center, General Computer SIG - for NoteTab activities in March or
April 2009.


Cheers.


Eb


--- In ntb-clips@yahoogroups.com, "Edward" <ebrown1927@...> wrote:
>
>
> I have a couple of questions, I searched for and did not find,
searched wrong places I guess, a beginners tutorial for writing clips.
  Someone point me that direction please. That is if anyone is back
from the Christmas shopping experience of 2008.
> Ed
>
> [Non-text portions of this message have been removed]
>

#18769 From: ntb-clips@yahoogroups.com
Date: Wed Dec 3, 2008 12:32 am
Subject: New file uploaded to ntb-clips
ntb-clips@yahoogroups.com
Send Email Send Email
 
Hello,

This email message is a notification to let you know that
a file has been uploaded to the Files area of the ntb-clips
group.

   File        : /ClipClass+Clip_Basics+more.zip
   Uploaded by : alecb3ca <buralex@...>
   Description : Jody's clip class lessons and some other things that might be
useful for "newbies"

You can access this file at the URL:
http://groups.yahoo.com/group/ntb-clips/files/ClipClass%2BClip_Basics%2Bmore.zip

To learn more about file sharing for your group, please visit:
http://help.yahoo.com/l/us/yahoo/groups/original/members/web/index.htmlfiles

Regards,

alecb3ca <buralex@...>

#18770 From: Alec Burgess <buralex@...>
Date: Wed Dec 3, 2008 12:41 am
Subject: Re: [Clip] Re: beginners clip tutorial
alecb3ca
Send Email Send Email
 
Edward:
Jody created a "clip class" (10 of 15 proposed lessons were completed)
sometime during or before 2001.
It "should" be accessible somewhere in or below
http://www.notetab.net/libraries.php I think but if it is I can't find
it - though there are lots of other good things on that page worth
having a look at.

When I googled [notetab clipclass] and ["clipclass.zip" OR
"cliptut.zip"] I found a number of old conversations in the groups
archives but the links referenced are no longer accessible. They may
still be accessible in or under http://www.notetab.net/ and I'm just not
finding the correct links :-(

However ... when I searched my hard-disk backups from previous computers
I found an old folder containing these files:
basic clip basics.txt

     * ClipClass.otl
     * ClipClass.pdf
     * ClipClass.ps
     * clipclass.zip - Jody's  original clip class set (pre Notetab 5.x)
       but (I think) 95% accurate and worthwhile
     * H-Clip Basics.txt - Jim Hall's intro to creating clips
     * H-ClipLanguage-Intro.txt
     * H-Create Clipbook Libraries.txt
     * index.html - html version of Clip Basics with illustrations
     * NoteAwk_Manual.otl
     * NoteTabRef460.otl
     * NTB485HelpFile-Full.rtf
     * ntp1.gif
     * ntp2.gif
     * ntp3.gif
     * ntp4.gif

  which I've uploaded to the Files area as:
http://tech.groups.yahoo.com/group/ntb-clips/files/ClipClass+Clip_Basics+more.zi\
p


Note: I requested a notification which should get sent but at least
currently, trying to d/l *ANY* file from
http://tech.groups.yahoo.com/group/ntb-clips/files/ is giving me a Yahoo
error message "The requested document is not accessible."
Is anyone else able to access the file I uploaded or any other file from
the files area?

--
Regards ... Alec   (buralex@gmail & WinLiveMess - alec.m.burgess@skype)

ebbtidalflats (ebbtidalflats@...) wrote (in part)  (on 2008-12-02
at 17:24):
>  --- In ntb-clips@yahoogroups.com, "Edward" <ebrown1927@...> wrote:
>  >
>  >
>  > I have a couple of questions, I searched for and did not find,
>  searched wrong places I guess, a beginners tutorial for writing clips.
>  Someone point me that direction please. That is if anyone is back
>  from the Christmas shopping experience of 2008.



[Non-text portions of this message have been removed]

#18771 From: "Edward" <ebrown1927@...>
Date: Wed Dec 3, 2008 2:22 am
Subject: Re: [Clip] New file uploaded to ntb-clips
horsefly_38866
Send Email Send Email
 
That was what I was looking for. I sure miss Jody and Jim Hall.
Ed

A dog is the only thing on earth that loves you more than he loves himself.
-- Josh Billings

   ----- Original Message -----
   From: ntb-clips@yahoogroups.com
   To: ntb-clips@yahoogroups.com
   Sent: Tuesday, December 02, 2008 6:32 PM
   Subject: [Clip] New file uploaded to ntb-clips



   Hello,

   This email message is a notification to let you know that
   a file has been uploaded to the Files area of the ntb-clips
   group.

   File : /ClipClass+Clip_Basics+more.zip
   Uploaded by : alecb3ca <buralex@...>
   Description : Jody's clip class lessons and some other things that might be
useful for "newbies"

   You can access this file at the URL:
  
http://groups.yahoo.com/group/ntb-clips/files/ClipClass%2BClip_Basics%2Bmore.zip

   To learn more about file sharing for your group, please visit:
   http://help.yahoo.com/l/us/yahoo/groups/original/members/web/index.htmlfiles

   Regards,

   alecb3ca <buralex@...>






[Non-text portions of this message have been removed]

#18772 From: "Dave" <dmc43959@...>
Date: Wed Dec 3, 2008 1:03 pm
Subject: varibles
david_99_au
Send Email Send Email
 
Hi
with the line below is it possible to make (.*) into two variables .

^!Find "SMITH\s{10}(.*)\r\nJONES\s{10}(.*)" RS

     THANKYOU DAVE M

#18773 From: "Don - HtmlFixIt.com" <don@...>
Date: Wed Dec 3, 2008 2:37 pm
Subject: Re: [Clip] varibles
dpasseng
Send Email Send Email
 
Well sort of, but you'd need a "delimiter" to make it mean anything.
Knowing what the data is would be helpful.

I assume it is catching anything between two names.  I assume there is a
space in between what is caught in the middle.

Your {10}'s are possibly not necessary.
^!Find "SMITH\s*(.*)\s*(.*)\r\nJONES\s*(.*)\s*(.*)" RS

or maybe just:
^!Find "SMITH\s*(.*)\r\nJONES\s*(.*)\s*(.*)" RS

if only the second one is supposed to be split.



Dave wrote:
> Hi
> with the line below is it possible to make (.*) into two variables .
>
> ^!Find "SMITH\s{10}(.*)\r\nJONES\s{10}(.*)" RS
>
>     THANKYOU DAVE M
>
>
>
> ------------------------------------
>
> Fookes Software: http://www.fookes.com/
> NoteTab website: http://www.notetab.com/
> NoteTab Discussion Lists: http://www.notetab.com/groups.php
>
> ***
> Yahoo! Groups Links
>
>
>
>

#18774 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Sat Dec 6, 2008 3:24 pm
Subject: GetDocMatchAll
ebbtidalflats
Send Email Send Email
 
Hi Y'all,

Can anyone suggest a way to use ^$GetDocMatchAll to match lines that
do _NOT_ contain a target word?

I've tried various combinations of assertions, but without success.
Either the function returns ALL lines in a document, including the
ones containing the unwanted target, or it returns NOTHING.

Here is the basis of what I'm testing (TARGET is the unwanted word):

^!SetListDelimiter ^%nl%
^!SetArray %keepers%=^$GetDocMatchAll("^[^\r\n]*(?!TARGET)[^\r\n]*")$
^!Select ALL
^!InsertText ^%keepers%

By the way, stripping lines that do not contain the target with:

^!Set %keepers%=^$GetDocMatchAll("^[^\r\n]*?^%target%[^\r\n]*?$")$

works fine.


Go ahead, point out any stupid mistakes I'm making!



Thanks,


Eb

#18775 From: "Flo" <flo.gehrke@...>
Date: Sat Dec 6, 2008 3:29 pm
Subject: Confusing Date Functions & Masks
jonas_ramus
Send Email Send Email
 
The Help says: "d" displays the day as a number without a leading
zero (1-31), and "m" the month as a number without a leading zero (1-
12).

Accordingly...

^!Info ^$GetDateFromInt(39610;m/d/yyyy)$

will output "6/11/2008". That is, the "d" represents one-digit days
as well as two-digit days.

When turning the date into a date integer, the same mask doesn't
work...

^!Info ^$GetDateToInt(6/11/2008;m/d/yyyy)$

No output!

It works with...

^!Info ^$GetDateToInt(6/11/2008;m/dd/yyyy)$

That is, in this case, the mask has to accord exactly with the date
format. The "d" doesn't represent all days from 1 to 31 any more.
It's the same problem with "m" etc.

Isn't that incosistent?

I got to this problem when trying to check if the dates in a list are
within a certain range using...

^!IfInRange ^$GetDateToInt(^$GetLine$;dd/mm/yyyy)$ 29221..40543 etc..

If the dates have a mixed format like...

"12/06/2008", "12/6/2008", "1/10/2007", "2/2/2009" etc

I first have to adjust the given dates to a defined mask.

Flo
 

#18776 From: "Don - HtmlFixIt.com" <don@...>
Date: Sat Dec 6, 2008 3:41 pm
Subject: Re: [Clip] GetDocMatchAll
dpasseng
Send Email Send Email
 
Okay, I don't understand regex at all ... in this context  .... so this
is just a guess, but I think you are excluding the ending return.  Isn't
that what ^ means? Exclude that?  So this is meant to work line by line.
   You need a delimiter to create the array.  The return is in fact the
delimiter, therefore there is no delimiter.  That is my guess.  Leave
off the last exclude line.

ebbtidalflats wrote:
> Hi Y'all,
>
> Can anyone suggest a way to use ^$GetDocMatchAll to match lines that
> do _NOT_ contain a target word?
>
> I've tried various combinations of assertions, but without success.
> Either the function returns ALL lines in a document, including the
> ones containing the unwanted target, or it returns NOTHING.
>
> Here is the basis of what I'm testing (TARGET is the unwanted word):
>
> ^!SetListDelimiter ^%nl%
> ^!SetArray %keepers%=^$GetDocMatchAll("^[^\r\n]*(?!TARGET)[^\r\n]*")$
> ^!Select ALL
> ^!InsertText ^%keepers%
>
> By the way, stripping lines that do not contain the target with:
>
> ^!Set %keepers%=^$GetDocMatchAll("^[^\r\n]*?^%target%[^\r\n]*?$")$
>
> works fine.
>
>
> Go ahead, point out any stupid mistakes I'm making!
>
>
>
> Thanks,
>
>
> Eb
>
>
> ------------------------------------
>
> Fookes Software: http://www.fookes.com/
> NoteTab website: http://www.notetab.com/
> NoteTab Discussion Lists: http://www.notetab.com/groups.php
>
> ***
> Yahoo! Groups Links
>
>
>
>

#18777 From: "Don - HtmlFixIt.com" <don@...>
Date: Sat Dec 6, 2008 4:09 pm
Subject: Re: [Clip] Bugs in Notetab - how to report (was: Confusing Date Functions & Masks)
dpasseng
Send Email Send Email
 
Flo wrote:
> The Help says: "d" displays the day as a number without a leading
> zero (1-31), and "m" the month as a number without a leading zero (1-
> 12).
>
> Accordingly...
>
> ^!Info ^$GetDateFromInt(39610;m/d/yyyy)$
>
> will output "6/11/2008". That is, the "d" represents one-digit days
> as well as two-digit days.
>
> When turning the date into a date integer, the same mask doesn't
> work...
>
> ^!Info ^$GetDateToInt(6/11/2008;m/d/yyyy)$
>
> No output!
>
> It works with...
>
> ^!Info ^$GetDateToInt(6/11/2008;m/dd/yyyy)$
>
> That is, in this case, the mask has to accord exactly with the date
> format. The "d" doesn't represent all days from 1 to 31 any more.
> It's the same problem with "m" etc.
>
> Isn't that inconsistent?
>
> I got to this problem when trying to check if the dates in a list are
> within a certain range using...
>
> ^!IfInRange ^$GetDateToInt(^$GetLine$;dd/mm/yyyy)$ 29221..40543 etc..
>
> If the dates have a mixed format like...
>
> "12/06/2008", "12/6/2008", "1/10/2007", "2/2/2009" etc
>
> I first have to adjust the given dates to a defined mask.
>
> Flo

That would seem inconsistent.  Which brings up my next point, what do we
do with bugs to get Eric's attention.  As you know I have recently
discovered two issues that I perceive as bugs.  Rather than blast them
out to the world, I have written the smaller development group in hopes
of having them addressed, but to my knowledge they have not been
addressed or acknowledged.

Should there not be a list on the notetab.com website of known bugs or
errata somewhere that we can add to and then have some response from the
author:
1. will fix first opportunity -- critical bug
2. will fix on some longer schedule
3. cannot fix -- inherent bug caused by some unfixable issue
4. not a bug at all -- intended to function that way

This would allow us to report the error or erratic behavior we are
perceiving, would allow others with issues to become aware of it, and
would give us confirmation that the bug has been registered and placed
on the "I'll look into that list".

In searching to find my two issues I find a number of other perceived
bug reports.  Perhaps such a mechanism already exists.  But I am unaware.

Here are the two recent bugs I have reported:
We have recently noticed that notetab's strip html command seems a
little uncertain as to what it does.

I am trying to figure one out  ....

Use this three line bit as your text to work on:
http://www.domain.com/view.html?ID=11494&t=1
http://www.domain.com/view.html?ID=11494&ti=1
http://domain.com/index.php?option=com_content&task=view&id=58481&Itemid=61

Run this clip:
^!Select All
^$StrStripHTML("^$GetSelection$";FALSE)$

or this one:
^!Select All
^$StrStripHTML("^$GetSelection$";TRUE)$

Both come out the same on this test sample.

But look at the end of the first two lines carefully ...
in line one, ...4&t=1 outputs as 4t
but
in line two, ...4&ti=1 outputs as 4&ti=1
As it should I propose.  Why is it chopping dropping the & and chopping
everything after the t?

AND

  > I have a clip that was working great previously and now is not. I
  > suspect that there is a problem with getresubstrings.
  >
  > I find the email address I am looking for with the following line, but
  > the set doesn't set anything.
  >
  > ^!Find "\r\nEmail: (.*@.*\..*)\r\n" CIWRS
  > ^!Set %eMail%=^$StrLower(^$GetReSubStrings$)$
  >
  > The email address is highlighted. I suspect a bug in regex or the
  > getresubstring command .... or I'm missing something basic, but it
  > worked in prior versions of notetab and no longer does.
  >
  >
I have confirmed that this is not working properly (or like it used to
at least).

Note that I missed a backslash in my find above, but that is/was not the
issue as I had it right in my actual clip:
^!Find "\r\nEmail\: (.*@.*\..*)\r\n" CIWRS
^!Set %eMail%=^$StrLower(^$GetReSubStrings$)$

Here is what I found:
* used to -- work if there is one (subpattern) in the find in prior
versions of notetab
* now -- only works correctly if there are two or more (subpatt)(erns)
in the find!

I think it should work with just one subpattern found to be honest,
despite the fact there is an s at the end of getresubstringS.

I have copied the list most commonly read by Eric even though this post
is primarily meant for the clips list. I hope that is okay? Is there
still a bugs list and is that commonly read as well? I don't think I am
a member if there is such a list.

I disclose these so that others may find them if they are suffering the
issues I did.

In trying to find my two instances I found several others reporting
perceived bugs.  So what is the proper protocol and how can we get
confirmation from Eric?

#18778 From: "Sheri" <silvermoonwoman@...>
Date: Sat Dec 6, 2008 4:32 pm
Subject: Re: GetDocMatchAll
silvermoonwo...
Send Email Send Email
 
You probably need the latest NoteTab release for this:

^!Toolbar New Document
Some Target Bla
Subject
Bla Bla Target Bla Bla
Interesting
^!Jump Doc_End
;begin long line
^!InsertSelect "^$GetDocListAll("(?i)(^.*\bTarget\b.*)|(^.+)";"$2\r\n")$"
;end long line
^!If ^$GetSelSize$=0 Next Else Skip_2
^!Set %result%=""
^!Goto Quit
^!Set %result%=^$GetDocReplaceAll("^\R+";"")$
^!InsertText ^%Empty%
:Quit
^!Select All
^!Continue Replace Content with Result Shown Below?^%NL%^%result%
^%result%
;end of clip

#18779 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Sat Dec 6, 2008 10:23 pm
Subject: Re: GetDocMatchAll
ebbtidalflats
Send Email Send Email
 
Verrry Interrrestingg,

Thanks Sheri. Your test lines work as desired.

But,

(Eric, are you lurking?) the code does not work when I
remove the New Document command and the test text, then
run it on an open document.

It still jumps to the end of the doc, and runs the same
from then on. And the clip removes 65 lines from the
document.  But only 24 lines contained the target word,
some of which targets were NOT removed!


Plus, there is a BONUS BUG? ;-)


The Confirm promt is larger than the screen, leaving the user to guess
what the options are. ESC and ENTER work, but what about a newbie to
NoteTab, when the bottom line is somewhere down-under?

Multiline prompts have their uses, and I could fix the prompt size.
But I would expect a well-behaved application to create windows with
_accessible_ controls.


I see the code working, when I single-step. But I do not understand
what is happening.

--- In ntb-clips@yahoogroups.com, "Sheri" <silvermoonwoman@...> wrote:
>
> ;begin long line
> ^!InsertSelect
"^$GetDocListAll("(?i)(^.*\bTarget\b.*)|(^.+)";"$2\r\n")$"
> ;end long line

What is the purpose of "|(^.+)"?
What is the purpose of "$2\r\n"?
I do not understand how the next line sets the desired "keeper" lines.


> ^!Set %result%=^$GetDocReplaceAll("^\R+";"")$

On first blush this looks like you'r just stripping empty lines.



Regards,



Eb

#18780 From: "ebbtidalflats" <ebbtidalflats@...>
Date: Sat Dec 6, 2008 10:43 pm
Subject: Re: [Clip] GetDocMatchAll
ebbtidalflats
Send Email Send Email
 
Thanks for the suggestion, Don.

--- In ntb-clips@yahoogroups.com, "Don - HtmlFixIt.com" <don@...> wrote:
>
> Okay, I don't understand regex at all ... in this context  .... so this
> is just a guess, but I think you are excluding the ending return.
Isn't
> that what ^ means? Exclude that?  So this is meant to work line by
line.


Yes, more or less. But I know I'm getting delimited data. When I use
only the lookahead assertion, It returns ALL lines, delimited!


But when I try to integrate the lookbehind assertion, the function
matches NOTHING.



Eb

#18781 From: "Flo" <flo.gehrke@...>
Date: Sun Dec 7, 2008 3:25 am
Subject: Re: GetDocMatchAll
jonas_ramus
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@...>
wrote:
>
> Verrry Interrrestingg,
>
> Thanks Sheri. Your test lines work as desired.
> I see the code working, when I single-step. But I do not understand
> what is happening...

Eb, Sheri, and all,

This is an another instructive solution presented by Sheri! Regarding
Eb's questions, I would like to try the following reply:

>>"^$GetDocListAll("(?i)(^.*\bTarget\b.*)|(^.+)";"$2\r\n")$"
>
> What is the purpose of "|(^.+)"?
> What is the purpose of "$2\r\n"?

I would say: The RegEx matches either a line that
contains "Target" OR it matches any line. If "Target" is found, the
RegEx Machine immediately stops the search and doesn't care for the
rest. It replaces the match with $2 and a CRNL. Since the search has
been stopped, $2 is empty, and the line is replaced with a CRNL only
(that's why it outputs empty lines in this case). If "Target" isn't
found, the whole line is captured with $2 (those are the lines you
want to select since they don't contain "Target").

So, choosing Sheri's four lines, the function returns...

[empty][CRNL]
Subject[CRNL]
[empty][CRNL]
Interesting[CRNL]

This is inserted at the Doc_End and selected.

Next,...

^!Set %result%=^$GetDocReplaceAll("^\R+";"")$

assigns the selected text to %result%, that is: the hits only,
removing those empty lines that were produced by ^$GetDocListAll$.

Finally, the whole text is selected and replaced with the contents of
%result%, that is: the two matching lines only (if we don't cancel
the job). I get into trouble with...

^!InsertText ^%Empty%

It removes the hits, but - in the end - those are removed anyway.
Maybe its useful to see these hits in case we cancel the replacing of
the whole text with the hits?

*** I hope this interpretation will survive Sheri's critical eye ;-)
***

Eb, in case you insist on ^$GetDocMatchAll$, I would like to present
to you another version based on Sheri's concept...


^!SetClipboard ^$GetDocMatchAll("(^.*TARGET.*$)|(^.+$)";2)$
^!SetClipboard ^$StrReplace(";";"^P";^$GetClipboard$;0;0)$
^!Toolbar Paste New
^!Replace "^\r\n" >> "" AWRS


Want some more? What about this...


^!SetArray %Lines%=^$GetDocMatchAll(^.+$)$
^!Set %Count%=1
:Loop
^!IfMatch "^.*TARGET.*$" "^%Lines^%Count%%" Skip
^!Append %Select%=^%Lines^%Count%%^%NL%
^!Inc %Count%
^!If ^%Count% = ^%Lines0% Out
^!Goto Loop
:Out
^!Toolbar New Document
^!InsertText ^%Select%
^!ClearVariable %Select%


Eb, maybe it's interesting to understand why your first idea...

^$GetDocMatchAll("^[^\r\n]*(?!TARGET)[^\r\n]*")$

didn't work. I think combining a Negative Lookahead Assertion
with "[^\r\n]*" can't work.

The RegEx says: "Find a position from where you don't see "TARGET"
when looking ahead. This position must be preceded or not preceded or
followed or not followed by anything that is no CRNL".

That means: This RegEx is always true. That's why your concept
selects all lines without excluding lines which contain "TARGET".

I think in a more conventional way we just would remove lines
containing "TARGET" in order to get lines NOT containing that word.
This still works with "good old" ^!Replace...

^!Replace "^.*TARGET.*(\r\n|\Z)" >> "" AWRS

This is my homework for today...

Flo :-P

Note: Never post to this forum unlesse you are prepared to make a
fool of yourself!
 

#18782 From: "Sheri" <silvermoonwoman@...>
Date: Sun Dec 7, 2008 4:54 am
Subject: Re: GetDocMatchAll
silvermoonwo...
Send Email Send Email
 
--- In ntb-clips@yahoogroups.com, "ebbtidalflats" <ebbtidalflats@...>
wrote:

> the code does not work when I
> remove the New Document command and the test text, then
> run it on an open document.
>
> It still jumps to the end of the doc, and runs the same
> from then on. And the clip removes 65 lines from the
> document.  But only 24 lines contained the target word,
> some of which targets were NOT removed!

You would need to present your doc and clip for help explaining that.
Two things come to mind. First, in the pattern I used:

(?i)(^.*\bTarget\b.*)|(^.+)

the \b's require the target text to be whole words, e.g., "targets",
"targeting" and "targeted" are not being in/excluded.

Second, if you change the target text, you need to make sure any
metacharacters it contains are escaped. You can't for example use a
variable that might contain metacharacters like "^" without escaping
them, like "\^".

Flo has given a very good explanation of what the pattern does.
Regular expressions search for text that affirmatively matches a
pattern, not one that doesn't. Even when you use a negative assertion,
you are actually searching for something that follows from a given
position.

Regular expressions always work from left to right. Both of the
subpatterns match whole lines that are not empty lines. If a line
fails to match the first subpattern (because it doesn't contain
"target"), it must match the second subpattern because that subpattern
matches anything (except linebreaks). The vertical bar says "or"
between the subpatterns. But if it matches the first subpattern, it
doesn't try the second. In the format string, we ask only for the
second subpattern, aka $2 in GetDocListAll or just 2 in GetDocMatchAll.

There was a long standing bug until the latest NoteTab version that
prevented this type of pattern from working properly in
GetDocMatchall. Cheers to Eric that its fixed now. :)

Regards,
Sheri

#18783 From: "Sheri" <silvermoonwoman@...>
Date: Sun Dec 7, 2008 1:39 pm
Subject: Re: GetDocMatchAll
silvermoonwo...
Send Email Send Email
 
Hi Flo,

> I think in a more conventional way we just would remove lines
> containing "TARGET" in order to get lines NOT containing that word.
> This still works with "good old" ^!Replace...
>
> ^!Replace "^.*TARGET.*(\r\n|\Z)" >> "" AWRS

That is probably the most direct approach. If for some reason we
wanted the result in a variable instead of the document we could use
the new ^$GetDocReplaceall$ function instead. But I think you meant to
use \z instead of \Z... :D

Also my list pattern could have been improved resource-wise by not
capturing substring #1 (since it wasn't needed), e.g.,

"(?i)(?:^.*\bTarget\b.*)|(^.+)";"$1\r\n"

>
> This is my homework for today...

A+ :D

Regards,
Sheri

#18784 From: "donnybahama" <donnybahama@...>
Date: Mon Dec 8, 2008 4:50 am
Subject: ^!Keyboard - multiple key presses?
donnybahama
Send Email Send Email
 
I remember doing something like this...

^!Keyboard {down,12}
OR
^!Keyboard {down 12}

But I get an error message either way. This isn't covered in the clip
programming help. Can anyone tell me the correct syntax for this?

#18785 From: "Dave" <dmc43959@...>
Date: Mon Dec 8, 2008 12:12 pm
Subject: Re: [Clip] ^!Keyboard - multiple key presses?
david_99_au
Send Email Send Email
 
Hi
there is a
^!keyboard down
or
^!MoveCursor +/-nnn
^!Jump +/-nnn
     THANKYOU DAVE M

----- Original Message -----
From: "donnybahama" <donnybahama@...>
To: <ntb-clips@yahoogroups.com>
Sent: Monday, December 08, 2008 3:50 PM
Subject: [Clip] ^!Keyboard - multiple key presses?


>I remember doing something like this...
>
> ^!Keyboard {down,12}
> OR
> ^!Keyboard {down 12}
>
> But I get an error message either way. This isn't covered in the clip
> programming help. Can anyone tell me the correct syntax for this?
>
>
>
> ------------------------------------
>
> Fookes Software: http://www.fookes.com/
> NoteTab website: http://www.notetab.com/
> NoteTab Discussion Lists: http://www.notetab.com/groups.php
>
> ***
> Yahoo! Groups Links
>
>
>
>

Messages 18756 - 18785 of 23887   Oldest  |  < Older  |  Newer >  |  Newest
Add to My Yahoo!      XML What's This?

Copyright © 2010 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines NEW - Help