From one of the elements in a ListBox, click to buy another listbox element

Source: Internet
Author: User

Look first:

The authoring process in blend is as follows:

1. Create a new sample data in the data board, such as

2. Click on the Deterministic dialog box

3. This is the collection collection that appears in the data board, changing the Property1 under the set to name

4. When the grid is selected in the Objects and Timeline window, the Name property in the Zuojian point is dragged onto the artboard in the middle of blend, and the listbox is automatically created, placing the listbox on the left side of the artboard, such as:

5. Create an empty listbox on the right side of the artboard

6. If there is no problem with the above steps, this should be the case in the code

7. Add a double-click event to the left ListBox and double-click to add the ListBox element to the right ListBox1

8. Double-click the event as follows:

9. Press the F5 test to view the results, as shown, stating that the event is not a problem

10. Right-click on the left ListBox and press Enter ListBoxItem Edit Template

11. Select the TextBlock object in the Objects and Timeline window, and then find Fluidmovesettagbehavior drag and drop onto the TextBlock object of the artboard from the behaviors panel (see image)

12. Fluidmovesettagbehavior appears below the TextBlock of the object and Timeline window.

13. and set tag to DataContext on the right property window

14. Next set the template item to the right ListBox box, press Create

15. Bind the Name property in the template, such as

16. and choose Fliudmovebehavior to TextBlock from the behavior.

17. The drag and drop should be correct as shown below

18. Set Properties:

19. Finish, press F5, double-click on the left trial effect.

From one of the elements in a ListBox, click to buy another listbox element

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.