Re: Passing a "callback" name to ixsl:schedule-action

Dimitre Novatchev <[email protected]>
Newsgroups gmane.text.xml.saxon.help
Message-ID <CAK4KnZdJiv1SG5163FCiyz3RdfwTv5pXH6VCUdQf094gcAoUmg@mail.gmail.com>
 > You don't need to have a hard-coded template name or even a named
template.
 >
 > Instead, you can use xsl:apply-templates and select an element that you
have constructed to have the name passed from a parameter.
 > This will select a "match" template on an element with that name (and,
optionally, with a given namespace).
 >
 > This gives you the equivalent of calling an arbitrarily named template
but via match templates.

FXSL ?    :)

On Sun, Aug 30, 2020 at 2:03 PM Alan Painter <[email protected]> wrote:

> You don't need to have a hard-coded template name or even a named template.
>
> Instead, you can use xsl:apply-templates and select an element that you
> have constructed to have the name passed from a parameter.
> This will select a "match" template on an element with that name (and,
> optionally, with a given namespace).
>
> This gives you the equivalent of calling an arbitrarily named template but
> via match templates.
>
> On Sun, Aug 30, 2020 at 9:46 PM Martynas Jusevičius <
> martynas-tyFqBaoSXPC1Z/[email protected]> wrote:
>
>> Okay, unfortunate indeed. And how about "Internal error: Target
>> component not found (slot=0 id=NaN)" - is that a bug?
>>
>> I'll see if I can live with a hardcoded template name in
>> <ixsl:schedule-action>, maybe the cases are general enough so that it
>> suffices.
>>
>> On Sun, Aug 30, 2020 at 8:57 PM Michael Kay <mike-JkSD5nQpfvpWk0Htik3J/[email protected]> wrote:
>> >
>> >
>> > I get "Cannot call xsl:result-document while evaluating function" with
>> your example.
>> >
>> >
>> > Yes, I'm afraid my advice to pass a function item as a parameter to the
>> named template, and then do a dynamic call on the function item, overlooked
>> the rule that you can't call xsl:result-document while evaluating a
>> function.
>> >
>> > Unfortunate, that.
>> >
>> > Michael Kay
>> > Saxonica
>> >
>> > _______________________________________________
>> > saxon-help mailing list archived at http://saxon.markmail.org/
>> > [email protected]
>> > https://lists.sourceforge.net/lists/listinfo/saxon-help
>>
>>
>> _______________________________________________
>> saxon-help mailing list archived at http://saxon.markmail.org/
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/saxon-help
>>
> _______________________________________________
> saxon-help mailing list archived at http://saxon.markmail.org/
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/saxon-help



-- 
Cheers,
Dimitre Novatchev
---------------------------------------
Truly great madness cannot be achieved without significant intelligence.
---------------------------------------
To invent, you need a good imagination and a pile of junk
-------------------------------------
Never fight an inanimate object
-------------------------------------
To avoid situations in which you might make mistakes may be the
biggest mistake of all
------------------------------------
Quality means doing it right when no one is looking.
-------------------------------------
You've achieved success in your field when you don't know whether what
you're doing is work or play
-------------------------------------
To achieve the impossible dream, try going to sleep.
-------------------------------------
Facts do not cease to exist because they are ignored.
-------------------------------------
Typing monkeys will write all Shakespeare's works in 200yrs.Will they write
all patents, too? :)
-------------------------------------
Sanity is madness put to good use.
-------------------------------------
I finally figured out the only reason to be alive is to enjoy it.

_______________________________________________
saxon-help mailing list archived at http://saxon.markmail.org/
[email protected]
https://lists.sourceforge.net/lists/listinfo/saxon-help
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.