<?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: Scripting - Update AXF Status and Timestamp fields via code in ArcPad Questions</title>
    <link>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175296#M1249</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Tim,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks very much for the prompt and helpful response.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As I'm updating checked out data I've changed the query to:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;UPDATE [POINTS] SET AXF_TIMESTAMP = GETDATE(), AXF_STATUS = 16777218;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'll use your query for new records.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 13 Apr 2012 04:49:38 GMT</pubDate>
    <dc:creator>SteveFitzgerald</dc:creator>
    <dc:date>2012-04-13T04:49:38Z</dc:date>
    <item>
      <title>Scripting - Update AXF Status and Timestamp fields via code</title>
      <link>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175294#M1247</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi all.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I've written a script that can update attributes of any number of point records at once.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;By drawing a box around the points the script updates the record fields without opening the forms.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is all great but...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;the AXF TIME_STAMP and AXF_STATUS fields required for check-in are not automatically being updated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I guess there is some kind of trigger in opening the form that causes these to update.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Does anyone know a way to update these in Arcpad using a script or SQL?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2012 01:22:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175294#M1247</guid>
      <dc:creator>SteveFitzgerald</dc:creator>
      <dc:date>2012-04-12T01:22:20Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting - Update AXF Status and Timestamp fields via code</title>
      <link>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175295#M1248</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This should do the trick:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;Dim objLayer, objDS
Set objLayer = Map.Layers("POINTS")
Set objDS = objLayer.DataSource

Dim strsql
strsql = "insert INTO [POINTS] (AXF_TIMESTAMP, AXF_STATUS) VALUES (GETDATE(), 1)"
objDS.Execute strsql
Map.Refresh(True)

Set objLayer = Nothing
Set objDS = Nothing&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 09:02:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175295#M1248</guid>
      <dc:creator>TimHopper</dc:creator>
      <dc:date>2021-12-11T09:02:41Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting - Update AXF Status and Timestamp fields via code</title>
      <link>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175296#M1249</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Tim,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks very much for the prompt and helpful response.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As I'm updating checked out data I've changed the query to:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;UPDATE [POINTS] SET AXF_TIMESTAMP = GETDATE(), AXF_STATUS = 16777218;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'll use your query for new records.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 13 Apr 2012 04:49:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175296#M1249</guid>
      <dc:creator>SteveFitzgerald</dc:creator>
      <dc:date>2012-04-13T04:49:38Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting - Update AXF Status and Timestamp fields via code</title>
      <link>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175297#M1250</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm glad you were able to get it working.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Although I haven't tested, the status code of 16777218 indicates that the feature has had attributes modified and has then been checked in.&amp;nbsp; My guess is that if you were to go and try to check the data in it would not show any changed features.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Simply having "attributes modified" and having a status of "not checked in" would be a status of 2.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]13492[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]13493[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]13494[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]13495[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hopefully this info will prove helpful to you and others in the future.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'd appreciate it if you could mark this post as "answered" by clicking the check mark to the right of one of my posts.&amp;nbsp; This will help others quickly locate helpful info on this same topic.&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, 13 Apr 2012 14:35:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175297#M1250</guid>
      <dc:creator>TimHopper</dc:creator>
      <dc:date>2012-04-13T14:35:38Z</dc:date>
    </item>
    <item>
      <title>Re: Scripting - Update AXF Status and Timestamp fields via code</title>
      <link>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175298#M1251</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Tim,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks again! The tables will come in handy too.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Apr 2012 23:32:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcpad-questions/scripting-update-axf-status-and-timestamp-fields/m-p/175298#M1251</guid>
      <dc:creator>SteveFitzgerald</dc:creator>
      <dc:date>2012-04-17T23:32:03Z</dc:date>
    </item>
  </channel>
</rss>

