Click here to Skip to main content
15,915,508 members
Home / Discussions / C#
   

C#

 
GeneralRe: to produce full exe Pin
Dan Neely26-Jan-09 2:14
Dan Neely26-Jan-09 2:14 
Questioncan any body tell,how to add a table in a column of c#.net datagrid. Pin
s_aslam9825-Jan-09 19:55
s_aslam9825-Jan-09 19:55 
AnswerRe: can any body tell,how to add a table in a column of c#.net datagrid. Pin
Not Active25-Jan-09 20:34
mentorNot Active25-Jan-09 20:34 
GeneralRe: can any body tell,how to add a table in a column of c#.net datagrid. Pin
s_aslam9825-Jan-09 21:29
s_aslam9825-Jan-09 21:29 
GeneralRe: can any body tell,how to add a table in a column of c#.net datagrid. Pin
Not Active25-Jan-09 21:54
mentorNot Active25-Jan-09 21:54 
GeneralRe: can any body tell,how to add a table in a column of c#.net datagrid. [modified] Pin
s_aslam9825-Jan-09 22:09
s_aslam9825-Jan-09 22:09 
QuestionDataGridView to XLS/CSV Pin
Vandretta25-Jan-09 19:52
Vandretta25-Jan-09 19:52 
AnswerRe: DataGridView to XLS/CSV Pin
SeMartens25-Jan-09 23:57
SeMartens25-Jan-09 23:57 
GeneralRe: DataGridView to XLS/CSV Pin
Vandretta26-Jan-09 9:23
Vandretta26-Jan-09 9:23 
QuestionHow to save listview data to database? Pin
Tuntgerhuu25-Jan-09 16:08
Tuntgerhuu25-Jan-09 16:08 
AnswerRe: How to save listview data to database? Pin
N a v a n e e t h25-Jan-09 17:27
N a v a n e e t h25-Jan-09 17:27 
GeneralRe: How to save listview data to database? Pin
CooperWu25-Jan-09 17:48
CooperWu25-Jan-09 17:48 
GeneralRe: How to save listview data to database? Pin
N a v a n e e t h25-Jan-09 18:02
N a v a n e e t h25-Jan-09 18:02 
GeneralRe: How to save listview data to database? Pin
Tuntgerhuu25-Jan-09 18:30
Tuntgerhuu25-Jan-09 18:30 
QuestionCalling a stored procedure with a return value help please Pin
stored25-Jan-09 15:08
stored25-Jan-09 15:08 
AnswerRe: Calling a stored procedure with a return value help please Pin
ToddHileHoffer25-Jan-09 16:07
ToddHileHoffer25-Jan-09 16:07 
GeneralRe: Calling a stored procedure with a return value help please Pin
stored25-Jan-09 16:23
stored25-Jan-09 16:23 
the -1 is just an intercept if i cannot create a connection.

the return code from the stored proc will be a distinct value and never a -1 thus the -1 for the connection.

Can I use the ExecuteNonQuery() - Since i am only interested in the return code supplied.
Also it is my understanding the params need to be in a distinct order and defined?
I have changed the code around a little to...

For brevity i left the connection part out. Also i am 100% confimred the stored proc is working.
Another wrote that, but we tested extensively prior to implementing within this section of code.
And yes, if the DB cannot be connected this is ok.

SqlCommand command = new SqlCommand("the_storedProc", con);
command.CommandType = CommandType.StoredProcedure;

SqlParameter param = new SqlParameter();
param = command.Parameters.Add(new SqlParameter("@FilePath", SqlDbType.VarChar, 120));
param.Direction = ParameterDirection.Input;
param.Value = fullPath;  // this is a string i pass in with the full path

param = command.Parameters.Add(new SqlParameter("@FileType", SqlDbType.VarChar, 120));
param.Direction = ParameterDirection.Input;
param.Value = type; // string i pass in with the type

param = command.Parameters.Add(new SqlParameter("@Return_cd", SqlDbType.Int, 8));
param.Direction = ParameterDirection.Output;

command.ExecuteNonQuery();

GeneralRe: Calling a stored procedure with a return value help please Pin
stored25-Jan-09 17:33
stored25-Jan-09 17:33 
QuestionC# Reporting.. Application settings Pin
Jacob D Dixon25-Jan-09 13:10
Jacob D Dixon25-Jan-09 13:10 
AnswerRe: C# Reporting.. Application settings Pin
Not Active25-Jan-09 13:52
mentorNot Active25-Jan-09 13:52 
QuestionLoad corrupted HTML into XML document Pin
Lutosław25-Jan-09 12:39
Lutosław25-Jan-09 12:39 
AnswerRe: Load corrupted HTML into XML document Pin
Ravi Bhavnani25-Jan-09 15:19
professionalRavi Bhavnani25-Jan-09 15:19 
GeneralRe: Load corrupted HTML into XML document Pin
Lutosław26-Jan-09 7:18
Lutosław26-Jan-09 7:18 
AnswerRe: Load corrupted HTML into XML document Pin
Bruce Duncan25-Jan-09 18:59
Bruce Duncan25-Jan-09 18:59 
QuestionRe: Load corrupted HTML into XML document Pin
Lutosław26-Jan-09 7:14
Lutosław26-Jan-09 7:14 

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.