<?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: update Combobox set to dbf in ArcPad Questions</title>
    <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698874#M5067</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yep, that looks correct.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 07 Jan 2011 05:18:07 GMT</pubDate>
    <dc:creator>RolfBroch</dc:creator>
    <dc:date>2011-01-07T05:18:07Z</dc:date>
    <item>
      <title>update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698866#M5059</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a project that has a couple dbf tables that are feeding a couple comboboxes.&amp;nbsp; Whent he app opens the comboboxes are populates with values from the dbf tables.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I then wrote code that allows teh user to update the dbf tables.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;THis works and the dbf files are updated ALTHOUGH these changes are not reflecting when the user clicks the comboboxes the next time.&amp;nbsp; I have to completly leave the application and start it again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;So this points to the fact that the Comboboxes are being populated on the application open...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So my next question is obvious....how can I force the refresh of these comboboxes after the dbf update.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If I was loading the comboboxes when they open no problem...but this is something a bit different...I am using ArcPAD to populate the comboboxes by pointing to a dbf table in the list values tab of the combobox.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any thoughts?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;THanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Dec 2010 16:13:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698866#M5059</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2010-12-17T16:13:25Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698867#M5060</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I think I made a owrk around....but for soem reason it takes about 12-15 seconds to refresh the combobox/listbox...there are about 1200 records in the dbf...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Anyoen knwo of a faster way to do this....and this time taken is from a desktop computer...uggggg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Dec 2010 18:00:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698867#M5060</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2010-12-17T18:00:50Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698868#M5061</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Would using the .AddItem method on the combobox at the same time you're saving the new DBF entries work? Maybe this is already what you're doing, but it would create the illusion that it's refreshing the DBF-based combobox, but really it's the DBF plus the few new entries. The next time ArcPad gets started up, it will load entirely from the DBF and forget the items you added manually, so it would be pretty seamless to the end user.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Dec 2010 16:55:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698868#M5061</guid>
      <dc:creator>EricHajek1</dc:creator>
      <dc:date>2010-12-20T16:55:10Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698869#M5062</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yea that is what i decided to do....I was seeign a huge reload time on my PC but for soem reason on the laptop it was only a couple seconds...very confusing because the PC is 10 more powerful than the laptop.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Dec 2010 12:06:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698869#M5062</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2010-12-21T12:06:36Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698870#M5063</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Jay,&amp;nbsp; can you post what code you have?&amp;nbsp; Im trying something similar to what your doing but cant get it to work.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Dec 2010 19:45:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698870#M5063</guid>
      <dc:creator>ColbyParnell</dc:creator>
      <dc:date>2010-12-22T19:45:36Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698871#M5064</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This is what I am doign to refresh the combobox after I update or create a new record in the dbf.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this what you are refering to or are you talking about updating the dbf?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I simply call this sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Note is you are usign the DBF as a lookup table then it has to be in the same folder as the .axf file.&amp;nbsp;&amp;nbsp; (Where you set it in ArcStudio in the listvalues tab of the control properties of the combobox)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If all you are doing is calling it for a query etc then it can be anywhere...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
Sub PopulateListBoxMUTCDPage&amp;nbsp;&amp;nbsp; 

&amp;nbsp; Dim objRS4, objSelLayer4, objEFPageOneControls4, objEditForm4
&amp;nbsp; Set objSelLayer4 = Map.SelectionLayer
&amp;nbsp; Set objRS4 = objSelLayer4.Records

&amp;nbsp; objRS4.Bookmark = Map.SelectionBookmark

&amp;nbsp; Set objEditForm4 = application.map.layers("Supports").forms("EDITFORM")
&amp;nbsp; Set objEFPageOneControls4 = objEditForm4.Pages("page3").Controls

&amp;nbsp;&amp;nbsp; Dim MUTCD_CodeValue
&amp;nbsp;&amp;nbsp; MUTCD_CodeValue = objEFPageOneControls4("mutcd_code").Value
&amp;nbsp;&amp;nbsp; 'msgbox MUTCD_CodeValue

 objEFPageOneControls4("List1").Clear

' SPECIFY THE PATH TO LOCATE THE DBF FILE FOR QUERYING
 Dim path
&amp;nbsp;&amp;nbsp;&amp;nbsp; path = "C:\GPS_data_collections\Packets_Outgoing\Support_Signs_Data_Collection_2011\MUTCD_Code.dbf"

&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim pDS
&amp;nbsp;&amp;nbsp;&amp;nbsp; Set pDS = Application.CreateAppObject("RecordSet")
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp; pDS.Open(path)

 pDS.Find("MUTCD_CODE")

 pDS.MoveFirst
 Do While Not pDS.EOF

&amp;nbsp;&amp;nbsp; Dim Description, ObjectID&amp;nbsp; 
&amp;nbsp;&amp;nbsp; Description = pDS.Fields("MUTCD_CODE").Value
&amp;nbsp;&amp;nbsp; ObjectID = pDS.Fields("MUTCD_CODE").Value
&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;&amp;nbsp;&amp;nbsp;&amp;nbsp; objEFPageOneControls4("List1").AddItem ObjectID, Description 

&amp;nbsp; pDS.MoveNext 
 Loop

 pDS.Close 
 Set pDS = Nothing
End Sub
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;WAIT A SECODN I AM CONFUSING MYSELF HERE....THT updates a list box on have on my form...this will update the combobox after saving the record in teh dbf&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Call this sub&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
Sub Save

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ....code to Save or Update the dbf

&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Call PopulateMUTCDCodeComboBox

End Sub


Sub PopulateMUTCDCodeComboBox

&amp;nbsp; Dim objRS4, objSelLayer4, objEFPageOneControls4, objEditForm4
&amp;nbsp; Set objSelLayer4 = Map.SelectionLayer
&amp;nbsp; Set objRS4 = objSelLayer4.Records
&amp;nbsp; objRS4.Bookmark = Map.SelectionBookmark
&amp;nbsp; Set objEditForm4 = application.map.layers("Supports").forms("EDITFORM")
&amp;nbsp; Set objEFPageOneControls4 = objEditForm4.Pages("page2").Controls

 objEFPageOneControls4("mutcd_code").Clear

 MsgBox "The MUTCD Code List is Updating, Please hold on!" &amp;amp; vbnewline &amp;amp; "The combobox will populate shortly", vbExclamation, "MUTCD Updating"

 Dim path
 ' Desktop path
&amp;nbsp;&amp;nbsp;&amp;nbsp; path = "C:\GPS_data_collections\StreetSign_Collection_ArcPAD\Packets_Outgoing\Support_Signs_Data_Collection_2011\MUTCD_Code.dbf"

&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim pDS
&amp;nbsp;&amp;nbsp;&amp;nbsp; Set pDS = Application.CreateAppObject("RecordSet")
&amp;nbsp; pDS.Open(path)
 pDS.Find("MUTCD_CODE")

 pDS.MoveFirst
 Do While Not pDS.EOF
&amp;nbsp;&amp;nbsp; Dim varMUTCDCode 
&amp;nbsp;&amp;nbsp; varMUTCDCode = pDS.Fields("MUTCD_CODE").Value
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; objEFPageOneControls4("mutcd_code").AddItem varMUTCDCode, varMUTCDCode 
&amp;nbsp; pDS.MoveNext 
 Loop
 pDS.Close 
 Set pDS = Nothing


End Sub
&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 05:24:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698871#M5064</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2021-12-12T05:24:52Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698872#M5065</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;If I read your code correctly it would be easier to use these requests:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;objEFPageOneControls4("mutcd_code").Clear&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;objEFPageOneControls4("mutcd_code").AddItemsFromTable path, "MUTCD_CODE", "MUTCD_CODE"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;and not do any looping at all.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Rolf&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Dec 2010 04:58:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698872#M5065</guid>
      <dc:creator>RolfBroch</dc:creator>
      <dc:date>2010-12-30T04:58:26Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698873#M5066</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt; If I read your code correctly it would be easier to use these requests:&amp;nbsp; &lt;BR /&gt; &lt;BR /&gt;objEFPageOneControls4("mutcd_code").Clear&amp;nbsp; &lt;BR /&gt;objEFPageOneControls4("mutcd_code").AddItemsFromTable path, "MUTCD_CODE", "MUTCD_CODE"&amp;nbsp; &lt;BR /&gt; &lt;BR /&gt;and not do any looping at all.&amp;nbsp; &lt;BR /&gt; &lt;BR /&gt;Rolf&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Something like this?&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
 objEFPageOneControls4("mutcd_code").Clear

Dim &lt;SPAN style="color:&amp;quot;red&amp;quot;;"&gt;path&lt;/SPAN&gt;
&lt;SPAN style="color:&amp;quot;red&amp;quot;;"&gt;path &lt;/SPAN&gt;= "C:\GPS_data_collections\StreetSign_Collection_ArcPAD\MUTCD_Code.dbf"

objEFPageOneControls4("mutcd_code").AddItemsFromTable &lt;SPAN style="color:&amp;quot;red&amp;quot;;"&gt;path&lt;/SPAN&gt;, "MUTCD_CODE", "MUTCD_CODE"&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 05:24:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698873#M5066</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2021-12-12T05:24:54Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698874#M5067</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Yep, that looks correct.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Jan 2011 05:18:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698874#M5067</guid>
      <dc:creator>RolfBroch</dc:creator>
      <dc:date>2011-01-07T05:18:07Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698875#M5068</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Something weird is going on here....Nothing to do with the code...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;That code worked by the way, thanks....&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;UL&gt; &lt;BR /&gt; &lt;LI&gt;I have a Windows 7 machine, 64 bit, Intel Core(TM) 2 Duo CPU, 8 gigs of RAM&lt;/LI&gt; &lt;BR /&gt; The update and saving takes about 13-15 seconds....&amp;nbsp; &lt;BR /&gt; &lt;LI&gt;I place the same app (ArcPAD) on a Windows XP machine with Dual Core, about 1 gig Ram and it does it in 2-3 seconds....&lt;/LI&gt; &lt;BR /&gt;&lt;/UL&gt;&lt;SPAN&gt;I have no idea whats going on here....How can my desktop process this so slow and the laptop be so fast?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But anyways I am going to test on the Laptop and see where I am at....THANKS AGAIN.....&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Jan 2011 15:14:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698875#M5068</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2011-01-07T15:14:00Z</dc:date>
    </item>
    <item>
      <title>Re: update Combobox set to dbf</title>
      <link>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698876#M5069</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Man thats fast....blazing speed compared to looping....FANTASTIC&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;THANKS , Your help is very appreciated....&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Have&amp;nbsp; great weekend&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Jan 2011 15:22:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/update-combobox-set-to-dbf/m-p/698876#M5069</guid>
      <dc:creator>JayKappy</dc:creator>
      <dc:date>2011-01-07T15:22:36Z</dc:date>
    </item>
  </channel>
</rss>

