Follow below steps to include AdShufflr

  1. Install the Visual Studio Extension by downloading it from Visual Studio Gallery or here.
  2. Add reference to AdShufflr SDK in your project
    1. Right click reference in solution explorer, and select Add Reference
    2. Click Window, then extensions, then select AdShufflr, then OK
  3. To use AdShufflr as supplement for Microsoft ads, update ad control
    1. UI:AdControl should be inside StackPanel
    2. Set IsAutoRefreshEnabled="False" for ad control

    3. Add this line in page constructor

      this.Loaded += AdShufflrForXAML.Handler.SetRefresh;

      Sample ad control after update:

      <StackPanel> <UI:AdControl ApplicationId="3e87b95c-59d6-4365-977e-cda8f39bdbf6" AdUnitId="138196" IsAutoRefreshEnabled="False" HorizontalAlignment="Right" Height="250" VerticalAlignment="Top" Foreground="Gray" Width="250"/> </StackPanel>

Follow below steps to include AdShufflr

  1. Install the Visual Studio Extension by downloading it from Visual Studio Gallery or here.
  2. Add reference to AdShufflr SDK in your project
    1. Right click reference in solution explorer, and select Add Reference
    2. Click Window, then extensions, then select AdShufflr, then OK
  3. To use AdShufflr as supplement for Microsoft ads, update ad control
    1. Set isAutoRefreshEnabled to false
    2. Set onErrorOccurred to errorLogger

      Sample ad control after update:

      <div class="ad" data-win-control="MicrosoftNSJS.Advertising.AdControl" data-win-options="{adUnitId:'138196', applicationId:'3e87b95c-59d6-4365-977e-cda8f39bdbf6', isAutoRefreshEnabled:false, onErrorOccurred:errorLogger}"></div>

  4. To add AdShufflr ad control, update your existing code
    1. Add reference to adRefresh.js in default.html

      <script src="/AdShufflr/js/adRefresh.js"></script>

    2. Add AdShufflr ad-control in your HTML page

      <div class="ad" data-win-control="AdShufflr.AdControl"></div>

    3. Call AdRefresh.resetRefreshCounter() when page/DOM is ready

      AdRefresh.resetRefreshCounter();