VisualStudio Mobile Development (C #, VB. NET) Smobiler Development Platform--albumview album controls how to use

Source: Internet
Author: User

Albumview controls

One, style one

We want to achieve the effect in the following actions:

    1. Drag a Albumview control to the form interface from "Smobiler components" on the toolbar

    1. Modifying the properties of a Albumview
      1. Load event code

C#:

private void Testalbumview_load (object sender, EventArgs e)

{

DataTable mattable = new DataTable ();

MATTABLE.COLUMNS.ADD ("Mat_desc1", typeof (String));

MATTABLE.ROWS.ADD ();

mattable.rows[0]["MAT_DESC1"] = "Q1";

MATTABLE.ROWS.ADD ();

mattable.rows[1]["MAT_DESC1"] = "Q2";

MATTABLE.ROWS.ADD ();

mattable.rows[2]["MAT_DESC1"] = "Q3";

MATTABLE.ROWS.ADD ();

mattable.rows[3]["MAT_DESC1"] = "Q4";

MATTABLE.ROWS.ADD ();

mattable.rows[4]["MAT_DESC1"] = "Q5";

MATTABLE.ROWS.ADD ();

mattable.rows[5]["MAT_DESC1"] = "Q6";

MATTABLE.ROWS.ADD ();

mattable.rows[6]["MAT_DESC1"] = "Q7";

MATTABLE.ROWS.ADD ();

mattable.rows[7]["MAT_DESC1"] = "Q8";

MATTABLE.ROWS.ADD ();

mattable.rows[8]["MAT_DESC1"] = "Q9";

MATTABLE.ROWS.ADD ();

mattable.rows[9]["MAT_DESC1"] = "Q10";

Bind data to Albumview

This.albumView1.DataSource = mattable;

This.albumView1.DataBind ();

}

    1. ColumnCount Property

Gets or sets the number of columns for the Albumview, set by default to "4", 1;

Figure 1 Setting up the interface

    1. Dispalymember Property

Set the data display field, set the property to "Mat_desc1", 2;

Figure 2 Setting up the interface

    1. Location Property

Make the control appear in the appropriate position (0, 120), 3;

Figure 3 Setting up the interface

    1. Mode property

Gets or sets the get image mode, the default setting is "file", which means that the image is read directly from the file, 4;

Figure 4 Setting up the interface

Setting this property to "Customize" indicates that the binary data of the image can be obtained from the custom interface.

    1. RowHeight Property

Gets or sets the row height of the control, which is set by default to "30", 5;

Figure 5 Setting up the interface

    1. Size Property

Make the Albumview control size (120, 90), 6;

Figure 6 Setting up the interface

Second, the mobile phone effect display

VisualStudio Mobile Development (C #, VB. NET) Smobiler Development Platform--albumview album controls how to use

Related Article

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.