Click here to Skip to main content
15,910,210 members
Home / Discussions / C#
   

C#

 
GeneralRe: Intercept incoming html Pin
Dmitriy Kostovetskiy31-Jan-04 9:23
Dmitriy Kostovetskiy31-Jan-04 9:23 
GeneralRe: Intercept incoming html Pin
Anonymous31-Jan-04 23:34
Anonymous31-Jan-04 23:34 
GeneralRe: Intercept incoming html Pin
Nick Parker1-Feb-04 7:28
protectorNick Parker1-Feb-04 7:28 
GeneralRe: Intercept incoming html Pin
Anonymous1-Feb-04 10:40
Anonymous1-Feb-04 10:40 
GeneralSearch pdf contents Pin
Mahesh Varma30-Jan-04 19:47
Mahesh Varma30-Jan-04 19:47 
GeneralTextbox.lines[] Pin
gsrajput30-Jan-04 17:03
gsrajput30-Jan-04 17:03 
GeneralRe: Textbox.lines[] Pin
Kentamanos30-Jan-04 20:15
Kentamanos30-Jan-04 20:15 
GeneralRe: Textbox.lines[] Pin
Colin Angus Mackay31-Jan-04 1:36
Colin Angus Mackay31-Jan-04 1:36 
GeneralRe: Textbox.lines[] Pin
gsrajput31-Jan-04 4:38
gsrajput31-Jan-04 4:38 
GeneralHiding WinForm app from ALT-TAB Pin
gordingin30-Jan-04 15:47
gordingin30-Jan-04 15:47 
GeneralTypeInitializationException Pin
pahluwalia30-Jan-04 11:30
pahluwalia30-Jan-04 11:30 
GeneralRe: TypeInitializationException Pin
Broken God1-Feb-04 18:58
Broken God1-Feb-04 18:58 
GeneralRe: TypeInitializationException Pin
pahluwalia2-Feb-04 4:04
pahluwalia2-Feb-04 4:04 
QuestionHow to make print preview maximized? Pin
blakeb_130-Jan-04 10:51
blakeb_130-Jan-04 10:51 
AnswerRe: How to make print preview maximized? Pin
Heath Stewart30-Jan-04 10:58
protectorHeath Stewart30-Jan-04 10:58 
GeneralRe: How to make print preview maximized? Pin
blakeb_130-Jan-04 11:02
blakeb_130-Jan-04 11:02 
GeneralRe: How to make print preview maximized? Pin
Heath Stewart30-Jan-04 11:08
protectorHeath Stewart30-Jan-04 11:08 
GeneralRe: How to make print preview maximized? Pin
blakeb_130-Jan-04 11:11
blakeb_130-Jan-04 11:11 
GeneralRe: How to make print preview maximized? Pin
Tom Larsen30-Jan-04 11:31
Tom Larsen30-Jan-04 11:31 
GeneralMaximum value of an array Pin
crushinghellhammer30-Jan-04 9:37
crushinghellhammer30-Jan-04 9:37 
GeneralRe: Maximum value of an array Pin
Heath Stewart30-Jan-04 10:05
protectorHeath Stewart30-Jan-04 10:05 
GeneralRe: Maximum value of an array Pin
crushinghellhammer30-Jan-04 11:19
crushinghellhammer30-Jan-04 11:19 
GeneralRe: Maximum value of an array Pin
Heath Stewart30-Jan-04 11:36
protectorHeath Stewart30-Jan-04 11:36 
Shouldn't 125 be 127? I'm not sure what PosCtr is either, but you could probably just hardcode 0 to start at the beginning of the sub-array. You also shouldn't reset MaxVal each time. Just do something like this:
for (int i=0; i < 17; i++)
{
  int max = 0;
  for (int j=0; j < 127; j++)
    max = Math.Max(max, arr[i, j]);
 
  peekValues[i] = max;
}
If you reset MaxVal (or max in my example), then the value will always be the max because it's greater than 0. This means that AutocorrArray[i, 126] will be the max value whether or not it is.

 

Microsoft MVP, Visual C#
My Articles
GeneralRe: Maximum value of an array Pin
crushinghellhammer30-Jan-04 11:59
crushinghellhammer30-Jan-04 11:59 
GeneralRe: Maximum value of an array Pin
Heath Stewart30-Jan-04 12:03
protectorHeath Stewart30-Jan-04 12:03 

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.