sometimes you need to do
\starttexcode ... \stoptexcode
when inside some special caocode regime (which happens in xml)
Hans
Hans, thank you - that was the golden hint! It works now as I've always wanted! And I realize once again that I know far less about ConTeXt than I wished and thought... Wolfgang: thanks for your suggestions, too! I had thought about loading the xml document twice, the first time just for extracting the "language" information, but felt it was less than elegant and maybe not quite efficient (my lecture course xmls tend to have more thah 25,000 lines). But I didn't provide enough information for you to see the easiest solution. Thanks, I'm a happy camper again (I have to prepare the handout for a talk I'm giving next week in Israel...) Thomas