Author Topic: ListofShort.Min() Not working  (Read 165 times)

Nick_W

  • Full Member
  • ***
  • Posts: 215
    • View Profile
Re: ListofShort.Min() Not working
« on: February 02, 2017, 06:52:08 am »
You're right, the For loop now works. Must have been doing something else wrong.

This is the actual code I was running:

Code: [Select]
        For count As Integer = 0 To TotalBytes.Count- 1 Step 2
            //Dim val As Short = (TotalBytes.ExtractShort(count, Endianness.Big) & RESULT_MASK) >> 2 //optional endian
            Dim val As Short = ((TotalBytes(count) << 8 | TotalBytes(count + 1)) & RESULT_MASK) >> 2
            result.Add(val)
        Next

Which now works correctly, before it was returning a list of 1 entry.

Never mind...