[Xerte] Problem getting accurate count of pages in framework
Paul Swanson
Paul.Swanson at harlandfs.com
Wed Oct 8 17:53:52 BST 2008
I'm adding a "Page x of y" to a framework, and I'm not getting the
correct value for y (the number of pages in the framework).
I'm using an Entry Frame to the framework, and within that is a text
icon with an id of aboutDPCounter. The framework id is aboutDPFrame. On
each page, I include a script icon with the following:
aboutDPCounter.setText('Page ' + (aboutDPFrame.currentPage + 1) + ' of '
+ aboutDPFrame.pages.length;
When I enter the framework, which currently has two pages of content,
the page counter reads "Page 1 of 1." When I go to the next page, it
reads "Page 2 of 2," and when I back to the first page it reads "Page 1
of 2." If I then advance to page 2, it reads "Page 2 of 2."
What's going on? I would expect myFramework.pages.length would be
consistent. It appears as though it doesn't count the page until you've
actually navigated to it.
_____________________________
Paul Swanson
Instructional Designer
Harland Financial Solutions
800.274.7280 Ext. 2462
Paul.Swanson at harlandfs.com
_____________________________
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.nottingham.ac.uk/pipermail/xerte/attachments/20081008/69e508be/attachment.html
More information about the Xerte
mailing list