0

私はWP7アプリを開発し、xmlファイルデータを読み取ってボタンのクリックイベントのリストボックスコントロールにバインドしようとしているのは非常に新しいです。

誰かが私を助けてくれませんか。

これが私のxmlファイル形式です。ボタンをクリックしたときに、このxmlのdescriptionタグをリストボックスコントロールにバインドしたいと思います。

<ROOT>
<COMPANY NAME="Mercedes Benz">
<Car NAME="A-Class—Hatchback">
<Description>
<![CDATA[ Mercedes Benz will launch the sporty A-Class hatchback, its entry level variant based on the MFA platform for the European market in September 2012.]]>
</Description> 
<COLOR>Red</COLOR>
<Car NAME="Mercedes-Benz G-Class">
<Description>
<![CDATA[ It's the midweek hump and for many a first day back to work, time to jump to action, here's a Mercedes-Benz G-Class in action to inspire to push on to the end of the week!]]>
</Description> 
<COLOR>BLACK</COLOR>
</COMPANY>
<COMPANY NAME="BMW">
<Car NAME="BMW X1">
<Description>
<![CDATA[ The sporty and elegant design of the all-new three-door model, along with additional engine choices, are distinguishing features that sharpen the unmistakable profile of the all-new BMW 1 Series (3-door) as the recognised standard of sheer driving pleasure in the premium compact car segment.]]>
</Description> 
<COLOR>BLUE</COLOR>
</COMPANY>
</ROOT>

ヘルプや提案は大歓迎です。

ありがとう、Sudh

4

1 に答える 1

0

このチュートリアルを参照してください。

http://www.windowsphonegeek.com/tips/wp7-working-with-xml-reading-filtering-and-databinding

于 2012-06-09T10:52:47.700 に答える