Click here to Skip to main content
15,889,116 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionReading data from Excel Pin
indian14310-Aug-12 7:15
indian14310-Aug-12 7:15 
AnswerRe: Reading data from Excel Pin
jkirkerx10-Aug-12 10:33
professionaljkirkerx10-Aug-12 10:33 
GeneralRe: Reading data from Excel Pin
indian14310-Aug-12 12:28
indian14310-Aug-12 12:28 
GeneralRe: Reading data from Excel Pin
jkirkerx10-Aug-12 19:12
professionaljkirkerx10-Aug-12 19:12 
Question(Input string was not in a correct format) with ExecuteReader Pin
Jassim Rahma10-Aug-12 2:33
Jassim Rahma10-Aug-12 2:33 
AnswerRe: (Input string was not in a correct format) with ExecuteReader Pin
WebMaster10-Aug-12 2:52
WebMaster10-Aug-12 2:52 
AnswerRe: (Input string was not in a correct format) with ExecuteReader Pin
Parthi Bun10-Aug-12 3:06
Parthi Bun10-Aug-12 3:06 
AnswerRe: (Input string was not in a correct format) with ExecuteReader Pin
StianSandberg10-Aug-12 3:26
StianSandberg10-Aug-12 3:26 
SqlCommand.Parameters.AddWithValue() does not take datatype as an parameter. You should add the parameter name and value (not datatype)
C#
sql_command.Parameters.AddWithValue("param_member_id", Request.QueryString["id"]);

http://derekreynolds.wordpress.com/2011/05/16/using-sqlcommand-and-addwithvalue-parameters-to-execute-sql-insert/[^]

But your error "Input string was not in a correct format" is because some convert's did not succeed. When converting strings-->int etc you should use TryParse


C#
private static void TryToParse(string value)
 {
    int number;
    bool result = Int32.TryParse(value, out number);
    if (result)
    {
       Console.WriteLine("Converted '{0}' to {1}.", value, number);
    }
    else
    {
       if (value == null) value = "";
       Console.WriteLine("Attempted conversion of '{0}' failed.", value);
    }
 }

--------------------
When Chuck Norris' dreams come true, your worst nightmares begin.

GeneralRe: (Input string was not in a correct format) with ExecuteReader Pin
Jassim Rahma10-Aug-12 4:03
Jassim Rahma10-Aug-12 4:03 
GeneralRe: (Input string was not in a correct format) with ExecuteReader Pin
Jassim Rahma11-Aug-12 9:11
Jassim Rahma11-Aug-12 9:11 
AnswerRe: (Input string was not in a correct format) with ExecuteReader Pin
Shameel14-Aug-12 0:46
professionalShameel14-Aug-12 0:46 
Questionasp.net Pin
Rajesh.paka10-Aug-12 2:08
Rajesh.paka10-Aug-12 2:08 
AnswerRe: asp.net Pin
Wes Aday10-Aug-12 4:00
professionalWes Aday10-Aug-12 4:00 
Questionstrange issue with cache application block (ENT LIB 5) Pin
Luca Dominici9-Aug-12 23:23
Luca Dominici9-Aug-12 23:23 
AnswerRe: strange issue with cache application block (ENT LIB 5) Pin
Pete O'Hanlon10-Aug-12 0:42
mvePete O'Hanlon10-Aug-12 0:42 
AnswerRe: strange issue with cache application block (ENT LIB 5) Pin
jkirkerx10-Aug-12 10:12
professionaljkirkerx10-Aug-12 10:12 
Questiondebug javascript Pin
dcof9-Aug-12 18:44
dcof9-Aug-12 18:44 
AnswerRe: debug javascript Pin
AnnieCalvert9-Aug-12 20:09
AnnieCalvert9-Aug-12 20:09 
GeneralRe: debug javascript Pin
dcof10-Aug-12 4:31
dcof10-Aug-12 4:31 
GeneralRe: debug javascript Pin
enhzflep10-Aug-12 4:59
enhzflep10-Aug-12 4:59 
Generalwindow open Pin
dcof9-Aug-12 12:16
dcof9-Aug-12 12:16 
QuestionRe: window open Pin
CodeHawkz9-Aug-12 20:57
CodeHawkz9-Aug-12 20:57 
AnswerRe: window open Pin
dcof10-Aug-12 4:30
dcof10-Aug-12 4:30 
GeneralRe: window open Pin
CodeHawkz12-Aug-12 8:36
CodeHawkz12-Aug-12 8:36 
GeneralRe: window open Pin
jkirkerx10-Aug-12 11:33
professionaljkirkerx10-Aug-12 11:33 

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.