Code will move MapView from here and place it in the above DocumentViewer. The user wants to be able to print the map but the application always throws an ArgumentNullException. ``` ``` public MainWindow() { InitializeComponent(); this.Loaded += (sender, args) => { // Remove the MapView from the Layout GridLayout.Children.Remove(MyMapView); MyMapView.Width = MyMapView.Height = 300; // Add the MapView to a Fixed Page var fixedPage = new FixedPage { Width = 300, Height = 300 }; fixedPage.Children.Add(MyMapView); GridLayout.Children.Remove(listBox); listBox.Width = listBox.Height = 300; fixedPage.Children.Add(listBox); // Add the FixedPage to the PageContent var pageContent = new PageContent { Child = fixedPage }; // Add the PageContent to the FixedDocument MyFixedDocument.Pages.Add(pageContent); }; } ```"/>
laptop and a wrench

Bogue

ArgumentNullException is returned when hosting MapView in Microsoft DocumentView control for client side printing.

Dernière publication: December 30, 2015 ArcGIS Runtime SDK
Numéro d’ID de bogue BUG-000092761
EnvoiDecember 5, 2015
Dernière modificationJune 20, 2022
S’applique àArcGIS Runtime SDK
Version trouvée10.2.5
Plateforme serveurWindows OS
Plateforme client7.0 64 Bit
StatutNon-Reproducible

Informations supplémentaires

Appears to be a bug in FixedDocument. Suggested workaround: ``` Code will move MapView from here and place it in the above DocumentViewer. The user wants to be able to print the map but the application always throws an ArgumentNullException. ``` ``` public MainWindow() { InitializeComponent(); this.Loaded += (sender, args) => { // Remove the MapView from the Layout GridLayout.Children.Remove(MyMapView); MyMapView.Width = MyMapView.Height = 300; // Add the MapView to a Fixed Page var fixedPage = new FixedPage { Width = 300, Height = 300 }; fixedPage.Children.Add(MyMapView); GridLayout.Children.Remove(listBox); listBox.Width = listBox.Height = 300; fixedPage.Children.Add(listBox); // Add the FixedPage to the PageContent var pageContent = new PageContent { Child = fixedPage }; // Add the PageContent to the FixedDocument MyFixedDocument.Pages.Add(pageContent); }; } ```

Étapes pour reproduire

ID de bogue: BUG-000092761

Logiciel:

  • ArcGIS Runtime SDK

Obtenir de l’aide auprès des experts ArcGIS

Contacter le support technique

Télécharger l’application Esri Support

Accéder aux options de téléchargement

En savoir plus sur ce sujet