Click here to Skip to main content
15,892,697 members
Home / Discussions / C#
   

C#

 
AnswerRe: Control Events Pin
jjansen22-Jun-06 20:40
jjansen22-Jun-06 20:40 
QuestionHow can I hide the caret of a RichTextBox control? [modified] Pin
AngryC21-Jun-06 15:03
AngryC21-Jun-06 15:03 
QuestionDatabindings Question Pin
Drew McGhie21-Jun-06 12:08
Drew McGhie21-Jun-06 12:08 
AnswerRe: Databindings Question Pin
Edbert P21-Jun-06 14:30
Edbert P21-Jun-06 14:30 
GeneralRe: Databindings Question Pin
Drew McGhie22-Jun-06 3:30
Drew McGhie22-Jun-06 3:30 
QuestionTreeNode image question Pin
likefood21-Jun-06 11:49
likefood21-Jun-06 11:49 
GeneralRe: TreeNode image question Pin
BoneSoft21-Jun-06 11:56
BoneSoft21-Jun-06 11:56 
QuestionIConvertible Error (part deux from previous post) Pin
leckey21-Jun-06 11:39
leckey21-Jun-06 11:39 
This is a continuation of my previous post which Josh was helping me with.

I have the following code:
private void BindData()<br />
		{<br />
			strPartNumberInputReference = txtSearchPart.Text;<br />
			ds = new DataSet();<br />
			//SqlParameter param = new SqlParameter("@PartID", strPartNumberInputReference);<br />
			ds=SqlHelper.ExecuteDataset(this.connectionString, "dbo.GetPartInfo", param);<br />
			Session["ds"]=ds;<br />
			dt = ds.Tables[0];<br />
			Session["dt"]=dt;<br />
			dgParts.DataSource=dt;<br />
			dgParts.DataBind();<br />
			txtSearchPart.Text = "";<br />
			<br />
		}


I am using the Microsoft SQLHelp.cs class. When it tries to fill the dataset I get the error "Object must implement IConvertible." The code is getting stuck in:

public static DataSet ExecuteDataset(SqlConnection connection, CommandType commandType, string commandText, params SqlParameter[] commandParameters)<br />
		{<br />
			SqlCommand cmd = new SqlCommand();<br />
			PrepareCommand(cmd, connection, (SqlTransaction)null, commandType, commandText, commandParameters);<br />
			SqlDataAdapter da = new SqlDataAdapter(cmd);<br />
			DataSet ds = new DataSet();<br />
			da.Fill(ds);			<br />
			// detach the SqlParameters from the command object, so they can be used again.			<br />
			cmd.Parameters.Clear();<br />
			<br />
			//return the dataset<br />
			return ds


I have tried the debugger (which I have little experience) and found that was the line it doesn't like. I've been trying to find some online resources but have not come any further in trying to figure out why I'm getting this error.
AnswerRe: IConvertible Error (part deux from previous post) Pin
led mike21-Jun-06 19:24
led mike21-Jun-06 19:24 
QuestionForm based post with file and data [modified] Pin
Green Goblin21-Jun-06 11:09
Green Goblin21-Jun-06 11:09 
QuestionGeneric class [modified] Pin
torontomouse21-Jun-06 10:46
torontomouse21-Jun-06 10:46 
AnswerRe: Generic class Pin
Josh Smith21-Jun-06 10:52
Josh Smith21-Jun-06 10:52 
GeneralRe: Generic class Pin
torontomouse21-Jun-06 16:43
torontomouse21-Jun-06 16:43 
GeneralRe: Generic class Pin
Josh Smith24-Jun-06 15:33
Josh Smith24-Jun-06 15:33 
AnswerRe: retrieving command line arguments from a file Pin
Judah Gabriel Himango21-Jun-06 11:57
sponsorJudah Gabriel Himango21-Jun-06 11:57 
QuestionHow can I send to back a mdi child window? Pin
User 309585921-Jun-06 10:43
User 309585921-Jun-06 10:43 
Questiondata unbinding relate...urgnt plzz Pin
r_e_h_a_n21-Jun-06 10:33
r_e_h_a_n21-Jun-06 10:33 
AnswerRe: data unbinding relate...urgnt plzz Pin
Edbert P21-Jun-06 14:50
Edbert P21-Jun-06 14:50 
QuestionBiztalk 2004: How to pass database facts from C# code? Pin
pankazmittal21-Jun-06 10:25
pankazmittal21-Jun-06 10:25 
QuestionSQL Express 2005 Dumper for SQL Server 2005 Pin
emran83421-Jun-06 10:14
emran83421-Jun-06 10:14 
AnswerRe: SQL Express 2005 Dumper for SQL Server 2005 Pin
Mark Tutt21-Jun-06 10:50
Mark Tutt21-Jun-06 10:50 
QuestionData Adapter passing by reference to stored procedure Pin
leckey21-Jun-06 9:07
leckey21-Jun-06 9:07 
AnswerRe: Data Adapter passing by reference to stored procedure Pin
Not Active21-Jun-06 9:25
mentorNot Active21-Jun-06 9:25 
GeneralRe: Data Adapter passing by reference to stored procedure [modified] Pin
leckey21-Jun-06 9:28
leckey21-Jun-06 9:28 
GeneralRe: Data Adapter passing by reference to stored procedure Pin
ashishinfra21-Jun-06 20:07
ashishinfra21-Jun-06 20:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.