Click here to Skip to main content
15,895,084 members
Home / Discussions / C#
   

C#

 
GeneralRe: How to clean all the installers? Pin
_Q12_8-Jun-19 8:24
_Q12_8-Jun-19 8:24 
AnswerRe: How to clean all the installers? Pin
Gerry Schmitz7-Jun-19 6:31
mveGerry Schmitz7-Jun-19 6:31 
AnswerRe: How to clean all the installers? Pin
Eddy Vluggen7-Jun-19 8:38
professionalEddy Vluggen7-Jun-19 8:38 
AnswerRe: How to clean all the installers? Pin
Dave Kreskowiak7-Jun-19 14:39
mveDave Kreskowiak7-Jun-19 14:39 
AnswerRe: How to clean all the installers? Pin
#realJSOP10-Jun-19 2:26
mve#realJSOP10-Jun-19 2:26 
QuestionIndex was Outside the range of the Array in Cryptography App Pin
Member 140791596-Jun-19 2:15
Member 140791596-Jun-19 2:15 
QuestionRe: Index was Outside the range of the Array in Cryptography App Pin
Richard MacCutchan6-Jun-19 2:45
mveRichard MacCutchan6-Jun-19 2:45 
AnswerRe: Index was Outside the range of the Array in Cryptography App Pin
OriginalGriff6-Jun-19 2:57
mveOriginalGriff6-Jun-19 2:57 
We can't tell you "It's there!" because we would need your code running with your data to find out exactly where it is happening, and what values are causing the problem - and you need that before you can start looking at why it's wrong!

All we can do is explain why it's causing a problem. Arrays in C# are a sequence of values accessed via an index: and that index must be between zero and the "number of values minus one". So if you have an array containing five integers for example, then valid indexes are 0, 1, 2, 3, and 4. All other indexes will give an error because the value you are trying to deal with does not exist.
So you can say:
C#
i = arr[0];
i = arr[1];
i = arr[2];
i = arr[3];
i = arr[4];
But not:
C#
i = arr[-1];
i = arr[5];
i = arr[666];

And your code uses several arrays, any of which could be the source of the problem.

So, it's going to be up to you.
Fortunately, you have a tool available to you which will help you find out what is going on: the debugger. If you don't know how to use it, a quick Google for "Visual Studio debugger" should give you the info you need.

Put a breakpoint on the first line in the function, and run your code through the debugger. Then look at your code, and at your data and work out what should happen manually. Then single step each line checking that what you expected to happen is exactly what did. When it isn't, that's when you have a problem, and you can back-track (or run it again and look more closely) to find out why.

Sorry, but we can't do that for you - time for you to learn a new (and very, very useful) skill: debugging!
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!

AnswerRe: Index was Outside the range of the Array in Cryptography App Pin
Gerry Schmitz6-Jun-19 6:33
mveGerry Schmitz6-Jun-19 6:33 
QuestionVS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch5-Jun-19 3:40
mvahoney the codewitch5-Jun-19 3:40 
AnswerRe: VS2017/2019 VSIX broken - I need a favor Pin
Richard MacCutchan5-Jun-19 4:35
mveRichard MacCutchan5-Jun-19 4:35 
AnswerRe: VS2017/2019 VSIX broken - I need a favor Pin
Gerry Schmitz5-Jun-19 6:52
mveGerry Schmitz5-Jun-19 6:52 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch5-Jun-19 8:11
mvahoney the codewitch5-Jun-19 8:11 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
OriginalGriff5-Jun-19 8:20
mveOriginalGriff5-Jun-19 8:20 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch5-Jun-19 8:30
mvahoney the codewitch5-Jun-19 8:30 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
ZurdoDev5-Jun-19 9:09
professionalZurdoDev5-Jun-19 9:09 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch5-Jun-19 13:59
mvahoney the codewitch5-Jun-19 13:59 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
ZurdoDev6-Jun-19 1:54
professionalZurdoDev6-Jun-19 1:54 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch6-Jun-19 3:16
mvahoney the codewitch6-Jun-19 3:16 
JokeRe: VS2017/2019 VSIX broken - I need a favor Pin
ZurdoDev6-Jun-19 3:23
professionalZurdoDev6-Jun-19 3:23 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch6-Jun-19 3:32
mvahoney the codewitch6-Jun-19 3:32 
AnswerRe: VS2017/2019 VSIX broken - I need a favor Pin
CPallini5-Jun-19 10:01
mveCPallini5-Jun-19 10:01 
AnswerRe: VS2017/2019 VSIX broken - I need a favor Pin
jschell8-Jun-19 5:01
jschell8-Jun-19 5:01 
GeneralRe: VS2017/2019 VSIX broken - I need a favor Pin
honey the codewitch8-Jun-19 5:43
mvahoney the codewitch8-Jun-19 5:43 
QuestionC# mp4 stream reader Pin
nicko134-Jun-19 9:13
nicko134-Jun-19 9:13 

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.