<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Getting control of the TableForm element through VB in ArcPad Questions</title>
    <link>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46798#M338</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;My apologies for not being more descriptive &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Let me try to demonstrate:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ThisEvent object represents an ArcPad event that is occurring at a particular time and supplies a series of standard properties such as object, name and result.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For example: a person is an object. It has properties such as NAME, AGE and GENDER. It also has events such as TALK, RUN and SIT.&amp;nbsp; However, using&amp;nbsp; ThisEvent.object exposes that the RUN event has properties: DIRECTION and SPEED. So every time the person runs we can tell how fast they are going.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;An ArcPad example could be to check if the textboxName has a value entered using it's onValidate event -&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If textBoxName = "" &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;then&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ThisEvent.Result = False&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ThisEvent.MessageText&amp;nbsp; = �??Please enter a Name�?�&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End If&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As you can see, instead of writing "layer.forms("EDITFORM").pages("PAGEONE").controls("textBoxName")", I have used ThisEvent to refer to the control. This also allows for the re-use of scripts as ThisEvent is generic and can be used to refer to any control, simply copy your script to run on different control events.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this is more helpful,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hannah &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 06 Jan 2014 02:04:17 GMT</pubDate>
    <dc:creator>HannahFerrier</dc:creator>
    <dc:date>2014-01-06T02:04:17Z</dc:date>
    <item>
      <title>Getting control of the TableForm element through VB</title>
      <link>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46795#M335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a related table in an axf which has created a tableform.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I want to programmatically get access to the controls on the page for the tableform.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the code for the editform I use:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Set pApplicantsDataForm = Application.Map.Layers("Applicants_2011").Forms("EDITFORM")&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Set pApplicantsDataControls = pApplicantsDataForm.Pages("page1").Controls&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So how would one get reference to the tableform using the above methodology - can it be done?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Jun 2012 20:49:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46795#M335</guid>
      <dc:creator>CamKenny</dc:creator>
      <dc:date>2012-06-27T20:49:40Z</dc:date>
    </item>
    <item>
      <title>Re: Getting control of the TableForm element through VB</title>
      <link>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46796#M336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Cam,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You will need to use the 'This.Event' object to access your Related Table Forms&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It is not able to be accessed using the method you have described &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hannah&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Jun 2012 00:17:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46796#M336</guid>
      <dc:creator>HannahFerrier</dc:creator>
      <dc:date>2012-06-29T00:17:00Z</dc:date>
    </item>
    <item>
      <title>Re: Getting control of the TableForm element through VB</title>
      <link>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46797#M337</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Does anyone know how to do this exactly?&amp;nbsp; Where do you place the thisevent.object code and how to do you write it?&amp;nbsp; I'm trying to show/hide a combo box on a tableform dependent on the values selected in another combo box on the same form.&amp;nbsp; The following code worked for an Editform but I can't mimic on the tableform.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Sub Test&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Dim domSPRT_NUM&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Set domSPRT_NUM = layer.forms("EDITFORM").pages("mntPage").controls("domSPRT_NUM")&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Dim domCONDITION&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Set domCONDITION = layer.forms("EDITFORM").pages("mntPage").controls("domCONDITION")&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If domCONDITION.value = "Good" then&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;domSPRT_NUM.visible = false&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End if'End Sub&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Dec 2013 19:02:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46797#M337</guid>
      <dc:creator>BrianRandall</dc:creator>
      <dc:date>2013-12-17T19:02:16Z</dc:date>
    </item>
    <item>
      <title>Re: Getting control of the TableForm element through VB</title>
      <link>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46798#M338</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;My apologies for not being more descriptive &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Let me try to demonstrate:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ThisEvent object represents an ArcPad event that is occurring at a particular time and supplies a series of standard properties such as object, name and result.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For example: a person is an object. It has properties such as NAME, AGE and GENDER. It also has events such as TALK, RUN and SIT.&amp;nbsp; However, using&amp;nbsp; ThisEvent.object exposes that the RUN event has properties: DIRECTION and SPEED. So every time the person runs we can tell how fast they are going.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;An ArcPad example could be to check if the textboxName has a value entered using it's onValidate event -&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If textBoxName = "" &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;then&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ThisEvent.Result = False&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ThisEvent.MessageText&amp;nbsp; = �??Please enter a Name�?�&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;End If&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As you can see, instead of writing "layer.forms("EDITFORM").pages("PAGEONE").controls("textBoxName")", I have used ThisEvent to refer to the control. This also allows for the re-use of scripts as ThisEvent is generic and can be used to refer to any control, simply copy your script to run on different control events.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this is more helpful,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hannah &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jan 2014 02:04:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/getting-control-of-the-tableform-element-through/m-p/46798#M338</guid>
      <dc:creator>HannahFerrier</dc:creator>
      <dc:date>2014-01-06T02:04:17Z</dc:date>
    </item>
  </channel>
</rss>

