Home/Support/Support Forum/Project with xml files : data not update
Welcome to Digi Forum, where you can ask questions and receive answers from other members of the community.

Project with xml files : data not update

0 votes
In my application i use xml files for refresh the data on a web page.

In a page web there is 60 data , some of them are updated but in int data i read on the web page : var="ZHTML ERROR: Expecting variable
val="ZHTML ERROR: Unknown variable
The code is:
#define USE_RABBITWEB 1 // necessary for zhtml handler in XML file
#define HTTP_MAXBUFFER 2048
#define SSPEC_MAXNAME 48

#web S_valide[@] groups=all(rw)

When i compile i have:

//Segment Origin Size
Root Code 0000:0000 0042b4 ( 17076 )
Root Data 0010:b800 003ad5 ( 15061 )
Xmem Code 000e:e000 04f448 ( 324680 )

It's a problem of size of data?
This project work fine with the same file on a BL2665 but with the BL4S200 i have reduced the code by erasing the part that manage the GSM.( error with code out of xmem code space )

Thanck you for the answer.
asked Apr 8, 2020 in Rabbit Software by arizzorabbit New to the Community (10 points)

Please log in or register to answer this question.

3 Answers

0 votes
It sounds like your page has unrecognized RabbitWeb/ZHTML markup. What does that part of the source .zhtml file look like? Do you have a typo in the variable name? Did you forget to export that variable to RabbitWeb via a #web statement?
answered Apr 8, 2020 by TomCollins Veteran of the Digi Community (2,106 points)
0 votes
I have an application where i use xml files with a bL2665 , it work fine
I need use a BL4S200 so , after problem with the memory , resolved in part , i have a problem with the data in a xml file.

My statements in the main program are :
// This value is required to enable FAT blocking mode for ZServer.lib
#define FAT_BLOCK
// Necessary for zserver.
Import file
#ximport "..\web\user\xml\alarme.xml" alarme_xml
SSPEC_MIME_FUNC(".html", "text/html", shtml_handler),
SSPEC_MIME_FUNC(".xml", "text/xml", zhtml_handler),
SSPEC_RESOURCE_XMEMFILE("/user/xml/alarme.xml", alarme_xml)

#web AL_valide_z[@] groups=all(rw)

In the javascript file i have:
function display(){
type: "GET",
url: "xml/alarme.xml",
dataType: "xml",
In the xml file i have:
<zone val="<?z print($AL_valide_z[1]) ?>">
<nom val="<?z print ($DOM_des[1].s) ?>" />
<type val="Temporisée" />
<etat val="<?z print ($AL_etat[1]) ?>" />

All the data DOM_des[1].s are correctly display but in some other data there is an error.
I currently have 2 ideas
The space of root data is insufficient.
There are differences between Dynamic c 9.62 and Dynamic c 10.72D.
I still have to check.
thank you
answered Apr 9, 2020 by arizzorabbit New to the Community (10 points)
0 votes
I you need explication about xml with Dynamic C 10.72D , you can make your request on this forum.

For my problem see the solution on this tag:
XML and structure of data
answered Apr 22, 2020 by arizzorabbit New to the Community (10 points)