[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 557
  • Last Modified:

Stored procedure with mobile application

It is possible to use stored procedure on a pocket pc. I did not find any information about that. If yes where can I found documentation on that.

This is my code in c#:

                SqlCeConnection SqlCnx = new SqlCeConnection(GlobalVar.strConnexion);
                try
                {
                    SqlCeCommand myCommand = new SqlCeCommand("getAuction", SqlCnx);
                    myCommand.CommandType = CommandType.StoredProcedure;
                    SqlCeDataAdapter dataAdapterInfoAuctList = new SqlCeDataAdapter(myCommand);
                    dataAdapterInfoAuctList.Fill(dataSetInfosalvage, "auct");
                    dataTableAuct = dataSetInfosalvage.Tables["auct"];
                    dtgridAuction.DataSource = dataTableAuct;
                }
                catch (SqlCeException Ex)
                {
                    MessageBox.Show("Error 0002 :\n" + Ex.Message, "SQL Error", MessageBoxButtons.OK, MessageBoxIcon.Asterisk, MessageBoxDefaultButton.Button1);
                }
                finally
                {
                    SqlCnx.Dispose();
                }

But that gice me an error :

The CommandType enumeration value, 1, is invalid.

I need help
0
Maclosky
Asked:
Maclosky
1 Solution
 
Aneesh RetnakaranDatabase AdministratorCommented:
0
 
MacloskyAuthor Commented:
thanks
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now