Join the Power Platform Masterclass #2 starting April 23

Sync Filter: Difference between revisions

Jump to navigation Jump to search
1,080 bytes added ,  1 July 2020
Line 76: Line 76:


If you want to ensure the same data in the application in online and offline mode, you can force using of the sync filter also in online mode. This can be configured for each mobile [[view]]; edit the properties of your view and enable '''Sync Filter - Use Sync Filter in Online Mode'''.
If you want to ensure the same data in the application in online and offline mode, you can force using of the sync filter also in online mode. This can be configured for each mobile [[view]]; edit the properties of your view and enable '''Sync Filter - Use Sync Filter in Online Mode'''.
== Analyzing SyncFilter.xml ==
When you synchronize your device with an app project, the sync filters for all entities are saved in one file, SyncFilter.xml. In the case of Windows apps, you can easily find this file on your file system; see [[Log_files#Finding_physical_files_in_Windows_versions_of_mobile_apps|finding physical files]]. If you're in charge of troubleshooting sync filter issues, it may make your life easier if you can read and understand the file SyncFilter.xml directly, instead of relying on Woodford.
For example, your sync filter file may start with the Account entity:
<syntaxhighlight lang="xml">
<fetchcollection>
  <fetch version="1.0">
    <entity name="account">
      <filter type="and">
        <condition attribute="statuscode" operator="ne" value="2"/>
        <condition attribute="ownerid" operator="eq-userid"/>
      </filter>
    </entity>
  </fetch>
  ...
</fetchcollection>
</syntaxhighlight>
This corresponds to the following sync filter:
[[File:Sample sync filter.png]]
The filter criteria are saved using the [[FetchMXL]] format.


== See also ==
== See also ==

Navigation menu