Click here to Skip to main content
15,887,485 members
Home / Discussions / C#
   

C#

 
GeneralRe: C# Specified cast is not valid Pin
Pavlex422-Dec-16 21:33
Pavlex422-Dec-16 21:33 
GeneralRe: C# Specified cast is not valid Pin
Richard MacCutchan22-Dec-16 22:09
mveRichard MacCutchan22-Dec-16 22:09 
GeneralRe: C# Specified cast is not valid Pin
harold aptroot22-Dec-16 22:26
harold aptroot22-Dec-16 22:26 
GeneralRe: C# Specified cast is not valid Pin
Richard MacCutchan22-Dec-16 22:33
mveRichard MacCutchan22-Dec-16 22:33 
GeneralRe: C# Specified cast is not valid Pin
harold aptroot22-Dec-16 22:39
harold aptroot22-Dec-16 22:39 
GeneralRe: C# Specified cast is not valid Pin
Richard MacCutchan22-Dec-16 22:54
mveRichard MacCutchan22-Dec-16 22:54 
GeneralRe: C# Specified cast is not valid Pin
OriginalGriff22-Dec-16 22:12
mveOriginalGriff22-Dec-16 22:12 
AnswerRe: C# Specified cast is not valid Pin
OriginalGriff22-Dec-16 22:11
mveOriginalGriff22-Dec-16 22:11 
Please, start looking at your code, using the debugger, and thinking: your questions are showing increasing evidence that you are not doing any of these things.
If the error is in this line:
C#
this.pokusaj[0] = (int)button.Tag;

Then it obvious that whatever is stored in the Tag property of the button control is not an integer.
What is it? We can't tell.
Why isn't it an integer? Again, we can't tell - because we can't run your code and see what is going on.
So for the unpteenth time: USE THE DEBUGGER and look at what is happening. It's the only way you are going to find out.

Personally? I'd guess the Tag is null - which can't be cast to any value type.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...

AnswerRe: C# Specified cast is not valid Pin
Nelson Costa Inácio22-Dec-16 22:42
Nelson Costa Inácio22-Dec-16 22:42 
GeneralRe: C# Specified cast is not valid Pin
harold aptroot22-Dec-16 22:45
harold aptroot22-Dec-16 22:45 
GeneralRe: C# Specified cast is not valid Pin
OriginalGriff23-Dec-16 0:05
mveOriginalGriff23-Dec-16 0:05 
AnswerRe: C# Specified cast is not valid Pin
Pete O'Hanlon23-Dec-16 0:00
mvePete O'Hanlon23-Dec-16 0:00 
AnswerRe: C# Specified cast is not valid Pin
Gerry Schmitz23-Dec-16 6:50
mveGerry Schmitz23-Dec-16 6:50 
GeneralRe: C# Specified cast is not valid Pin
Richard MacCutchan23-Dec-16 6:59
mveRichard MacCutchan23-Dec-16 6:59 
QuestionWhat is this JWT Code Doing? Pin
TheOnlyRealTodd21-Dec-16 15:46
professionalTheOnlyRealTodd21-Dec-16 15:46 
GeneralRe: What is this JWT Code Doing? Pin
Richard MacCutchan21-Dec-16 21:54
mveRichard MacCutchan21-Dec-16 21:54 
GeneralRe: What is this JWT Code Doing? Pin
TheOnlyRealTodd21-Dec-16 22:35
professionalTheOnlyRealTodd21-Dec-16 22:35 
GeneralRe: What is this JWT Code Doing? Pin
OriginalGriff21-Dec-16 23:24
mveOriginalGriff21-Dec-16 23:24 
GeneralRe: What is this JWT Code Doing? Pin
Gerry Schmitz22-Dec-16 4:07
mveGerry Schmitz22-Dec-16 4:07 
AnswerRe: What is this JWT Code Doing? Pin
Richard Deeming22-Dec-16 2:35
mveRichard Deeming22-Dec-16 2:35 
QuestionNeed help on how to if record exists update else insert c# Pin
Bootzilla3321-Dec-16 7:56
Bootzilla3321-Dec-16 7:56 
AnswerRe: Need help on how to if record exists update else insert c# Pin
Michael_Davies21-Dec-16 8:04
Michael_Davies21-Dec-16 8:04 
AnswerRe: Need help on how to if record exists update else insert c# Pin
Richard Deeming21-Dec-16 8:06
mveRichard Deeming21-Dec-16 8:06 
AnswerRe: Need help on how to if record exists update else insert c# Pin
Nelson Costa Inácio21-Dec-16 23:34
Nelson Costa Inácio21-Dec-16 23:34 
QuestionC# PictureBox remove image Pin
Pavlex420-Dec-16 11:21
Pavlex420-Dec-16 11:21 

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.