Pergunta

I have this demo piece of code below:

<Image Name="imgCam" Width="400" Height="600" Visibility="Visible" Source="http://www.graffiti.org/prague/phoe_whs_2000.jpg" />

This shows in the designer, but when I run the emulator or try to view it on a phone it doesn't work? Is there something that I'm missing to get this image to display in the emulator and phone? The url will load the the image in a browser fine.

Foi útil?

Solução

This image also works in an Emulator for me, unless I remove the Networking permission from the App.

You should check that you have specified ID_CAP_NETWORKING in the Capabilities section of WMAppManifest.xml

<Capabilities>
 <Capability Name="ID_CAP_NETWORKING"/>
</Capabilities>

Outras dicas

I have check with your URL in Emulator and its showing image in emulator. Check if your emulator has internet connection and is working properly.

Also you can try this. Uri uri = new Uri("Your URL", UriKind.RelativeOrAbsolute); Your_Image.Source = new BitmapImage(uri);

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top