Select to view content in your preferred language

custom forms with comboboxes not showing up in ArcPad

1335
5
08-05-2010 02:31 PM
GaryEhrhardt
New Contributor II
I have created several custom forms for easier collection of data in ArcPad. The forms that contain comboboxes (for FC's with domains) are not showing up in ArcPad. Instead, the generic list of attributes show up when collecting data for such a FC. The custom forms that do not have any comboboxes on them show up just fine in ArcPad.

Anyone have any idea what I may be missing? We are using ArcPad 8.0 SP3

Thanks,
Gary
Tags (3)
0 Kudos
5 Replies
EricHajek1
Occasional Contributor
You might be totally aware of this and something else is the issue, but this was the only thing I could think of:
Is at least one of your forms the "EDITFORM" form? You can create a myriad of custom forms, but unless you fire them via a toolbutton, they won't replace the default "EDITFORM" form (the "list of attributes" one). You can check by double clicking your feature layer in ArcPad Studio and then double clicking the <FORMS> icon, the form you want to fire when editing should be called "EDITFORM" in the name column.

As mentioned above, to fire your other forms you'll have to program a button on the toolbar.

This doesn't really address the distinction of why forms won't show up with comboboxes, unless the one without combo boxes is the editform.

Eric
0 Kudos
GaryEhrhardt
New Contributor II
Eric,

Thanks for your response. I think you nailed it with my problem. All of my forms that are not showing up in ArcPad are listed as 'FORM 1' and are not the EDITFORM. But I'm not clear on how to "fire them via a toolbutton" in order to have my forms replace the default EDITFORM. Do I need to come up with some code to create such a toolbutton?

Gary
0 Kudos
EricHajek1
Occasional Contributor
Yes, you'll have to create some applet files (.apa & optionally .vbs if there are scripts you want to run via toolbutton) so that you have a new toolbar. These will go in the Applets folder within your ArcPad10 folder, if they're there, they will load automatically when ArcPad starts.

To make your FORM 1 (or any form besides the editform) show when you want to edit a feature, some statement like this...

Application.Map.Layers("layername").Forms("FORM 1").Show

...can go in the "onclick" event of your new toolbutton. You can use the wizard interface within Studio to create the toolbar / buttons pretty easily, it's just the New Applet button and then once that window is open, click on the Toolbars button along the top to start adding toolbars / buttons with the wizard interface. Just like the forms they can be switched to XML view using the red / blue arrows, which may be useful for editing the toolbutton once it is created. Here's an example of a quick and dirty toolbar I created for a project recently:

<?xml version="1.0" encoding="UTF-8"?>
<ArcPad>
<APPLET name="applDocks" onload="">
  <TOOLBARS>
   <TOOLBAR name="Dock_Depths" caption="Dock Depths" onload="" visible="true" image="$maproll" buttonsize="1">
    <TOOLBUTTON name="SelectByGPS" shortcut="" image="@gpsselect" onclick="Call SelNearest"/>
    <TOOLBUTTON name="AddPoint" shortcut="" image="@modedrawpoint" onclick="Call AddPoint"/>
    <TOOLBUTTON command="gpsenable"/>
   </TOOLBAR>
  </TOOLBARS>
</APPLET>
<SCRIPT src="Dock_Depths.vbs" language="VBScript"/>
</ArcPad>


You can see in my onclicks I'm calling scripts from Dock_depths.vbs, but you could just as easily put the code above to show the form instead. Also there's the bottom command where it's simply the normal gpsenable button, but on my new custom toolbar. If the user only needs a few buttons 99% of the time, I find its nice to have it all on one toolbar. You can add any of the regular ArcPad buttons to your custom toolbar by searching for "internal command names" in the Customizing ArcPad Help and using those command names in the same way.

Hope this helps!
Eric
0 Kudos
GaryEhrhardt
New Contributor II
Eric,

Thanks very much. I've only had a little experience with applet files so your detailed response and example will help me a lot in creating toolbuttons. Much appreciated!

Gary
0 Kudos
EricHajek1
Occasional Contributor
No problem, I've gotten a lot out of these forums after being totally new to ArcPad a little over a year ago and then having to dive right into a project with custom forms / related tables pre-10. Happy to help and good luck!

Eric
0 Kudos