Modification Description: The Youku API is not very GeliAnd then use the potato API,ArticleYou can modify the text in the project on your own.
I have been learning WP7 for some time. I just started to use a small demo to implement the WP7 Youku searcher.
First, we use expression blend 4 to create a project named wp7youkusearch, and then design its home page, as shown in figure
Then we create the sample data for binding. navigate to the data panel (if not, you can select Windows> data in the menu bar) and select new sample data... Used for data binding.
We can see that blend generates two attributes by default. One is string type and the other is boolean type. Change the boolean type to the image type, and drag the collection to the page. You can see that a list is automatically generated on the page (ListBox is displayed in the object and time panel ), the list contains strings and images.
The sampledatasource in the data panel is surrounded by a yellow box, indicating that the data source is used for binding.
If we think that the template automatically generated by blend cannot meet our requirements, or we need to rearrange the template, right-click ListBox, and select edit additional templates-> edit generated items (itemtemplate) -> edit current, as shown in figure
Now we can edit the template. Note that the default container is stackpanel. Right-click stackpanel and select change layout type to change the layout type. Here we select grid, as shown in figure
After the interface is adjusted, the general template is as follows:
We need to set textwarping of textbox to warp so that the line feed can be automatically wrapped when there are many strings:
Exit template editing and switch to XAMLCodeInterface, you can see a resource similar to the followingSource code:
For more tips on expression blend, see the author's expression blend knowledge sharing. I will not introduce it too much here.
To be continued .....