MySqlDataSource SelectParameter

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
dooh
Posts: 30
Joined: Sun 14 Jan 2007 21:11

MySqlDataSource SelectParameter

Post by dooh » Thu 25 Dec 2008 18:45

Hi,

How can i conver and Parameter to a ControlParameter, i mean tha value it will be set from a control.

Now i can do that but with: ObjectDataSource.

It is possible with MySqlDataSource?

Thanks

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Fri 26 Dec 2008 12:13

Yes, this functionality is available in dotConnect for MySQL.
You can find the example of using the SqlDataSource component with ControlParameter here: http://msdn.microsoft.com/en-us/library ... meter.aspx . The usage of MySqlDataSource is similar. The only difference is the necessity of adding the following line in your *.aspx file to register our assembly:

Code: Select all


In this case you can use MySqlDataSource in the following way:

Code: Select all

      "
        selectcommand="SELECT * from dept WHERE deptno = :Title">
        
            
        
      
Fore more samples, please go to Start Menu | All Programs | Devart dotConnect for MySQL | Samples | Web. As an alternative, you can find our samples in the installation folder of our product.

dooh
Posts: 30
Joined: Sun 14 Jan 2007 21:11

Post by dooh » Fri 26 Dec 2008 16:40

Ok Alex,

But these steps we have to completly manually.

Is possible to do that in design time?

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Sat 27 Dec 2008 10:00

Registering our assembly occurs automatically when you drag and drop MySQLDataSource from Toolbox in design time. But you need to make settings with ControlParameter manually as you work with Microsoft's SQLDataSource.

Post Reply