Click here to Skip to main content
15,501,294 members
Home / Discussions / C#
   

C#

 
AnswerRe: To copy listbox values into gridview column Pin
Abhinav S6-Jul-13 2:40
MemberAbhinav S6-Jul-13 2:40 
AnswerRe: To copy listbox values into gridview column Pin
Eddy Vluggen6-Jul-13 10:47
professionalEddy Vluggen6-Jul-13 10:47 
Questionc# error Pin
User34905-Jul-13 9:23
MemberUser34905-Jul-13 9:23 
AnswerRe: c# error Pin
jschell5-Jul-13 9:46
Memberjschell5-Jul-13 9:46 
AnswerRe: c# error Pin
User34905-Jul-13 10:07
MemberUser34905-Jul-13 10:07 
AnswerRe: c# error Pin
Emmanuel Medina5-Jul-13 11:01
professionalEmmanuel Medina5-Jul-13 11:01 
GeneralRe: c# error Pin
User34905-Jul-13 11:36
MemberUser34905-Jul-13 11:36 
GeneralRe: c# error Pin
Emmanuel Medina8-Jul-13 3:42
professionalEmmanuel Medina8-Jul-13 3:42 
For starters, you should validate the values both in the FileDialog and the TextBox (check that the file exists and check the textbox's text is actually a number, at the very least) then after building your query and preparing your command, store the result from ExecuteScalar in an object variable, then check that for null, if it is null, present an error message, if its not, then cast it to whatever its type should be.
If you think you can do a thing or think you can't do a thing, you're right - Henry Ford

Emmanuel Medina Lopez

GeneralRe: c# error Pin
User34908-Jul-13 4:34
MemberUser34908-Jul-13 4:34 
GeneralRe: c# error Pin
User34906-Jul-13 8:16
MemberUser34906-Jul-13 8:16 
AnswerRe: c# error Pin
Mycroft Holmes5-Jul-13 15:09
professionalMycroft Holmes5-Jul-13 15:09 
AnswerRe: c# error Pin
Richard MacCutchan5-Jul-13 23:28
mveRichard MacCutchan5-Jul-13 23:28 
GeneralRe: c# error Pin
User34906-Jul-13 11:25
MemberUser34906-Jul-13 11:25 
GeneralRe: c# error Pin
NotPolitcallyCorrect6-Jul-13 11:35
MemberNotPolitcallyCorrect6-Jul-13 11:35 
GeneralRe: c# error Pin
Eddy Vluggen6-Jul-13 12:35
professionalEddy Vluggen6-Jul-13 12:35 
GeneralRe: c# error Pin
User34906-Jul-13 13:15
MemberUser34906-Jul-13 13:15 
GeneralRe: c# error Pin
Eddy Vluggen9-Jul-13 9:55
professionalEddy Vluggen9-Jul-13 9:55 
GeneralRe: c# error Pin
Richard MacCutchan6-Jul-13 22:42
mveRichard MacCutchan6-Jul-13 22:42 
GeneralRe: c# error Pin
User34907-Jul-13 5:26
MemberUser34907-Jul-13 5:26 
GeneralRe: c# error Pin
Richard MacCutchan7-Jul-13 8:21
mveRichard MacCutchan7-Jul-13 8:21 
GeneralRe: c# error Pin
User34907-Jul-13 9:28
MemberUser34907-Jul-13 9:28 
GeneralRe: c# error Pin
Richard MacCutchan7-Jul-13 21:38
mveRichard MacCutchan7-Jul-13 21:38 
QuestionC# SQL SELECT query taking too long Pin
IceUK5-Jul-13 6:48
MemberIceUK5-Jul-13 6:48 
AnswerRe: C# SQL SELECT query taking too long Pin
fixthebugg5-Jul-13 7:00
Memberfixthebugg5-Jul-13 7:00 
AnswerRe: C# SQL SELECT query taking too long Pin
Simon_Whale5-Jul-13 7:14
professionalSimon_Whale5-Jul-13 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.