hi friend,
 
i think but not sure
public bool AddLinkExchangeDetails(ArrayList LinkDetails)
{
'the opened connection may be here
ObjConn.OpenConnection(); 
try
{
'or put the connection to be opened here
ObjConn.OpenConnection(); 
SqlCommand SCommd=new SqlCommand("sp_AddLinkExchangeOffer",ObjConn.mysqlconn);
SCommd.CommandType=CommandType.StoredProcedure;

SCommd.Parameters.Add("@OrgName",LinkDetails[0].ToString()); 
SCommd.Parameters.Add("@OrgDetails",LinkDetails[1].ToString()); 
SCommd.Parameters.Add("@OrgEmail",LinkDetails[2].ToString()); 
SCommd.Parameters.Add("@OrgURL",LinkDetails[3].ToString()); 
SCommd.Parameters.Add("@LinkWord",LinkDetails[4].ToString()); 

SCommd.ExecuteNonQuery(); // problem at this point 
ObjConn.closeConnection(); 

return true;
}
catch
{
return false;
}

}

i hope that may help..
Thanks..
-------------------------------------------------------------------------------------------------------
Arindam <[EMAIL PROTECTED]> wrote:



Hello friend, 
I am trying to add something using "StoredProcedure" with 
SCommd.Parameters.Add. 
Pls have a look at the following code....., can u pls tell me where the prob is 
?




public bool AddLinkExchangeDetails(ArrayList LinkDetails)
{
try
{

SqlCommand SCommd=new SqlCommand("sp_AddLinkExchangeOffer",ObjConn.mysqlconn);
SCommd.CommandType=CommandType.StoredProcedure;

SCommd.Parameters.Add("@OrgName",LinkDetails[0].ToString()); 
SCommd.Parameters.Add("@OrgDetails",LinkDetails[1].ToString()); 
SCommd.Parameters.Add("@OrgEmail",LinkDetails[2].ToString()); 
SCommd.Parameters.Add("@OrgURL",LinkDetails[3].ToString()); 
SCommd.Parameters.Add("@LinkWord",LinkDetails[4].ToString()); 


ObjConn.OpenConnection(); 
SCommd.ExecuteNonQuery(); // problem at this point 
ObjConn.closeConnection(); 

return true;
}
catch
{
return false;
}

}



Thanks & Regards

Arindam 
Web Designer & Developer 




Yahoo! India Matrimony: Find your life partneronline.

[Non-text portions of this message have been removed]




Yahoo! Groups Links











Thanks & Regards

Arindam 
Web Designer & Developer  




Yahoo! India Matrimony: Find your life partneronline.

[Non-text portions of this message have been removed]


Yahoo! Groups SponsorADVERTISEMENT


---------------------------------
Yahoo! Groups Links

   To visit your group on the web, go to:
http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/
  
   To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
  
   Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service. 




---------------------------------
Post your free ad now! Yahoo! Canada Personals


[Non-text portions of this message have been removed]



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/AspNetAnyQuestionIsOk/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to