Select to view content in your preferred language

ArcPad Script for Page Referencing

1738
2
10-21-2013 11:10 AM
ChristopherBowering
Frequent Contributor
I believe what I'm trying to do is a simple page reference but I'm running into the same problem every time I try. 

On Page 1, there is a combo box with Street Names.  On Page 2, there is a 'Facility ID' texbox where an ID is generated when a value is input into the # field (Code is set to convert street name to a CR## format and concatenate with # value to form ID).

If the combo box value is changed, the 'Facility ID' does not automatically update (somewhat intentional as the code was not used as an OnSetActive event).  Thus, I created a Refresh button which loops through the same code and updates the 'Facility ID'.  This button works fine if it is on the same page as the 'Facility ID' but I can't get it to work if it is on the first page.  I want it to run exactly the same way - with the button itself being on the first page.  No matter what I try, a certain object is not being declared properly.

If someone could at least provide a sample code which takes a value on the first page and populates a text box on the second page, via first page button click, that would be great!  Attached is a picture of my Edit Form.
Tags (3)
0 Kudos
2 Replies
ChristopherBowering
Frequent Contributor
Upon further testing, it appears that ArcPad is not allowing the first page of an application to reference any other page.  The app I previously mentioned has 4 pages.  I used a simple enable/disable code as a test (OnSetActive Event) - setting the code on pages 2, 3, and 4 allowed me to reference any other page, including the first.  When setting the code on the first page, however, referencing pages 2, 3, and 4 did not work.  Is there something special/different about the first page of an application?  This is very perplexing.
0 Kudos
ThaiTruong
Deactivated User
Under OnSelChange event of your combo box control on Page 1, call your funtion that generates the ID and populates the value to 'Facility ID' texbox on Page 2.  It should work for you when ever the street value from the combo box is changed.

Hope this helps.
0 Kudos