多做题,通过考试没问题!

微软认证考试

睦霖题库>其他计算机考试>微软认证考试

You use Microsoft .NET Framework 4 to create a Windows Presentation Foundation (WPF) application that displays a high-resolution graphic image named Image1.jpg. You need to limit the width of the image to 200 pixels. You also need to preserve the aspect ratio of the image. Which code fragment should you use?()

  • A、 <Image Width="200" Source="Image1.jpg"/>   <Image Width="200" Height="200" Source="Image1.jpg"/>   <ImageWidth="200"><Image.Source>
  • B、 <BitmapImage DecodePixelWidth="200"DecodePixelHeight="200"UriSource="Image1.jpg" />   </Image.Source>
  • C、 </Image><Image Width="200"><Image.Source>
  • D、 <BitmapImage DecodePixelWidth="200" UriSource="Image1.jpg" /></Image.Source> </Image>
正确答案:D
答案解析:
进入题库查看解析

微信扫一扫手机做题