OLD | NEW |
---|---|
(Empty) | |
1 {{header}} | |
2 {{object 1 0}} << | |
3 /Type /Catalog | |
4 /Pages 2 0 R | |
5 /AcroForm 4 0 R | |
6 /OpenAction 10 0 R | |
7 >> | |
8 endobj | |
9 {{object 2 0}} << | |
10 /Type /Pages | |
11 /Count 1 | |
12 /Kids [ | |
13 3 0 R | |
14 ] | |
15 >> | |
16 endobj | |
17 % Page number 0. | |
18 {{object 3 0}} << | |
19 /Type /Page | |
20 /Parent 2 0 R | |
21 /Resources << | |
22 /Font <</F1 15 0 R>> | |
23 >> | |
24 /Contents [21 0 R] | |
25 /MediaBox [0 0 612 792] | |
26 >> | |
27 % Forms | |
28 {{object 4 0}} << | |
29 /Fields [5 0 R] | |
30 >> | |
31 % Field | |
32 {{object 5 0}} << | |
33 /FT /Tx | |
34 /T (MyField) | |
35 >> | |
36 % OpenAction action | |
37 {{object 10 0}} << | |
38 /Type /Action | |
39 /S /JavaScript | |
40 /JS 11 0 R | |
41 >> | |
42 endobj | |
43 % JS program to exexute | |
44 {{object 11 0}} << | |
45 >> | |
46 stream | |
47 function testField(x) { | |
48 var field = this.getField("MyField"); | |
49 field.value = x; | |
50 var y = field.value; | |
51 app.alert("Answer for \"" + x + "\" is: " + typeof(y) + " " + y); | |
52 } | |
53 testField("goats"); | |
54 testField("b4"); | |
55 testField("b4.5"); | |
56 testField("4x"); | |
57 testField("4.5x"); | |
58 testField("4"); | |
59 testField(" 4"); | |
60 testField("4 "); | |
61 testField(" 4 "); | |
62 testField("4 3 2 1"); | |
63 testField("-4"); | |
64 testField("23.00000001"); | |
65 testField("23.00000000000000001"); | |
66 testField("25,5"); | |
67 testField("1e+5"); | |
68 testField("1e5"); | |
69 testField("1e-5"); | |
70 testField("-1e-5"); | |
71 testField("1.2e5"); | |
72 testField("NAN"); | |
73 testField("INF"); | |
74 testField("0x100"); | |
75 testField("123x6"); | |
76 testField("123xy6"); | |
77 testField("123.y6"); | |
78 testField("1,000,000"); | |
79 testField("1.2.3"); | |
80 testField("1-3"); | |
81 testField("1+3"); | |
82 testField("1.-3"); | |
83 testField("1.+3"); | |
84 endstream | |
85 endobj | |
86 {{xref}} | |
87 trailer << | |
88 /Root 1 0 R | |
89 >> | |
90 {{startxref}} | |
91 %%EOF | |
OLD | NEW |