| |

VerySource

 Forgot password?
 Register
Search
Author: sonicliao

A little fun question!

[Copy link]

1

Threads

5

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-3-31 22:00:02
| Show all posts
Never done it, Bangding!
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-4-4 10:45:01
| Show all posts
To bind the primary key. . .

this.GridView1.DataKeyNames = new string [] {"ID"};
Reply

Use magic Report

0

Threads

4

Posts

5.00

Credits

Newbie

Rank: 1

Credits
5.00

 China

Post time: 2020-4-4 20:45:02
| Show all posts
Rebind
Reply

Use magic Report

0

Threads

2

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 Invalid IP Address

Post time: 2020-4-10 09:00:02
| Show all posts
The landlord try to use DataSet or DataTable for data binding
Reply

Use magic Report

0

Threads

7

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-4-12 08:45:01
| Show all posts
See what you mean is to change the data that needs to be displayed
You can use c # to change the select statement of the SqlDataSource!
Reply

Use magic Report

2

Threads

11

Posts

11.00

Credits

Newbie

Rank: 1

Credits
11.00

 China

 Author| Post time: 2020-4-14 14:00:01
| Show all posts
Back:死神一博导Brothers:
To bind the primary key. . .

this.GridView1.DataKeyNames = new string [] {"ID"};

Or not. You can try. I don't know what you said: "You only need to bind the primary key ..." Is it a positive sentence or a question sentence?
Reply

Use magic Report

2

Threads

11

Posts

11.00

Credits

Newbie

Rank: 1

Credits
11.00

 China

 Author| Post time: 2020-4-19 12:30:01
| Show all posts
I mean how to make the program binding and design state binding achieve the same effect.
Reply

Use magic Report

0

Threads

10

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-4-28 10:15:01
| Show all posts
Try to bind
Reply

Use magic Report

0

Threads

6

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-7-1 17:30:01
| Show all posts
Put
GridView1. DataSource = SqlDataSource1;
GridView1. DataBind();
Put it in IsPostBack.

You give it a try, after other events are executed, you can rebind the GridView.
Reply

Use magic Report

2

Threads

11

Posts

11.00

Credits

Newbie

Rank: 1

Credits
11.00

 China

 Author| Post time: 2020-7-2 15:00:02
| Show all posts
Reply:一桶姜山
GridView1. DataSource = SqlDataSource1;
Bind is the value of sqldatasource design state. For example, my sqldatasource1.selectcommand has changed. Then when the page refreshes, it is bound to the original sqldatasource.selectommand. .
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list