Quantcast
Channel: Adobe Community: Message List - PDF Forms
Viewing all articles
Browse latest Browse all 57214

Page Number based on slice() method

$
0
0

I have a document that is spawning pages. So for simplicity with spawning renaming pages, I decided I would just use the slice() method to obtain the page number based on the spawing pages:

 

P3.mytemplate

 

var p_name = event.target.name;

 

var ram = p_name.slice(1,2);

 

event.value = ram;

 

Now this works great until the last page and I get: NaN filled in the text field. If I delete this then the number shows up correctly and stays. Any ideas what might be causing this??

 

Thanks as always,

 

Nathan


Viewing all articles
Browse latest Browse all 57214

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>