![]() |
#1 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,971
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Template: possible error?
I wanted this template (for Action Chains' single field edit) to return "99" if the values match:
Code:
program: if and( check_yes_no('#onkobo', '', 1, 1), field('#fanficcat'), raw_field('#percentread') ==# 100 ) then '99' else raw_field('#percentread') fi Any ideas? ![]() Last edited by ownedbycats; 03-19-2021 at 05:43 PM. |
![]() |
![]() |
![]() |
#2 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,196
Karma: 1995558
Join Date: Aug 2015
Device: Kindle
|
It seems the template evaluator does not like any white space before the 'program:' part.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 10,971
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
I took the whitespace out (I was modifying it in Notepad2 because I have set a fixed-width font there) and it works
![]() |
![]() |
![]() |
![]() |
#4 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,445
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre 3.3 Template Error | srv181 | Library Management | 7 | 09-08-2018 02:59 AM |
Template Error during conversion | MontyJ | Conversion | 4 | 10-03-2013 11:00 AM |
Error message: "TEMPLATE ERROR Single '}' encountered in format string" | frank14612 | Calibre | 22 | 07-02-2013 11:05 AM |
template editor error | lrui | Calibre | 2 | 11-06-2012 10:07 AM |
v8.4 template error | cybmole | Calibre | 5 | 06-04-2011 11:10 AM |