Please note that you can subscribe to the individual forums. A subscription for news only covers the news.

Regarding counters,...
Clear all

Regarding counters, strings and their applications.

2 Posts
2 Users
Topic starter

A couple of small questions regarding counters.

Q1  Is there a way to display the counter in the window?  I have a counter #punish, with   "add#=#punish,a number "  dotted all over the place. I can't see how to display the current count.

Q2 Can the counter be used as a punish value? 

    Punish= [the current punish count]

Q2b  Another counter is called 'mistakes'. Ideally I'd like this one to be connected to a string variable: 

     Input$=$Mistakes,# mistakes


     Punish=... {$Mistakes} or {#Mistakes} ??

Neither seems to work. It's possible I'm demonstrating an embarrassing level of numb-skullery here - there's still much in the manual that is over my head.

Any help from anyone would be much appreciated.

2 Answers

Hi Simon


Text=Punish value: {#punish}

Can be put in a status definition or in a flag that you can set or remove to show or hide the text. 



When you use a counter or time variable directly in a keyword, you should not use {}. {} is only used in text or strings.


Input#=#Mistakes,# mistakes

When you want to use a variable to replace a number in a keyword, it must be a counter. So you need to input a counter. 

If you want it as a string variable, you can turn the counter into a string. Not the other way around. {} is used to turn a counter or time variable into a text. 

Sven B.

(Sorry, written from the wrong account.)





Topic starter

Thanks in abundance, Sven. After some time playing with these terms, all is clear. On top of other things, I think I'd caused a problem using the term 'punish' to refer to something other than the severity of punishment. Changed my personalised counter to 'pund'.