Click here to Skip to main content
15,897,891 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Change my IP with New IP Pin
vaghelabhavesh7-Feb-09 11:21
vaghelabhavesh7-Feb-09 11:21 
AnswerRe: Change my IP with New IP Pin
Ranjit Viswakumar8-Feb-09 6:02
Ranjit Viswakumar8-Feb-09 6:02 
GeneralRe: Change my IP with New IP Pin
ivo759-Feb-09 6:51
ivo759-Feb-09 6:51 
Questionenhancement Pin
mjrose7-Feb-09 7:18
mjrose7-Feb-09 7:18 
AnswerRe: enhancement Pin
vaghelabhavesh7-Feb-09 12:03
vaghelabhavesh7-Feb-09 12:03 
Questionmenu Pin
mjrose7-Feb-09 7:06
mjrose7-Feb-09 7:06 
AnswerRe: menu Pin
vaghelabhavesh7-Feb-09 11:28
vaghelabhavesh7-Feb-09 11:28 
QuestionCombine two CRC32 results Pin
vigylant7-Feb-09 3:27
vigylant7-Feb-09 3:27 
I have a CRC32 function for calculating the CRC32 checksum of a byte array:
Private CRC32Table(255) As Integer

Public Sub New()

    Dim dwPolynomial As Integer = &HEDB88320
    Dim j, dwCrc As Integer

    For i As Integer = 0 To 255
        dwCrc = i
        For j = 8 To 1 Step -1
            If (dwCrc And 1) Then
                dwCrc = ((dwCrc And &HFFFFFFFE) \ 2&) And &H7FFFFFFF
                dwCrc = dwCrc Xor dwPolynomial
            Else
                dwCrc = ((dwCrc And &HFFFFFFFE) \ 2&) And &H7FFFFFFF
            End If
        Next j
        CRC32Table(i) = dwCrc
    Next

End Sub

Public Function GetCRC32(ByRef bt() As Byte) As Integer

    Dim CRC32Result As Integer = -1
    Dim iLookup As Integer

    For Each b As Byte In bt

        iLookup = (CRC32Result And 255) Xor b
        CRC32Result = ((CRC32Result And -256) \ 256) And 16777215
        CRC32Result = CRC32Result Xor CRC32Table(iLookup)

    Next

    Return CRC32Result

End Function


The thing is, i want to combine two calculated CRC32's...

Example:

The CRC32 of GetCRC32(New Byte() {1}) is 1526341860
The CRC32 of GetCRC32(New Byte() {2}) is -1007455906

Now, say i do not have access to the bytes anymore, but i do have access to the CRC32 results (1526341860 and -1007455906).
Is it possible to combine these results as if the original calculation were GetCRC32(New Byte() {1, 2})?
AnswerRe: Combine two CRC32 results Pin
Dave Kreskowiak8-Feb-09 5:15
mveDave Kreskowiak8-Feb-09 5:15 
QuestionScreen capturing Pin
VeeKeyBee6-Feb-09 23:15
VeeKeyBee6-Feb-09 23:15 
AnswerRe: Screen capturing Pin
the fossil7-Feb-09 5:02
the fossil7-Feb-09 5:02 
GeneralRe: Screen capturing Pin
Luc Pattyn7-Feb-09 5:55
sitebuilderLuc Pattyn7-Feb-09 5:55 
AnswerRe: Screen capturing Pin
Samir Ibrahim7-Feb-09 7:05
Samir Ibrahim7-Feb-09 7:05 
QuestionImage printing problem Pin
Sipder6-Feb-09 18:50
Sipder6-Feb-09 18:50 
AnswerRe: Image printing problem Pin
Dave Kreskowiak6-Feb-09 19:09
mveDave Kreskowiak6-Feb-09 19:09 
GeneralRe: Image printing problem Pin
Sipder6-Feb-09 19:34
Sipder6-Feb-09 19:34 
GeneralRe: Image printing problem Pin
Dave Kreskowiak6-Feb-09 22:48
mveDave Kreskowiak6-Feb-09 22:48 
GeneralRe: Image printing problem Pin
Duncan Edwards Jones9-Feb-09 4:56
professionalDuncan Edwards Jones9-Feb-09 4:56 
GeneralRe: Image printing problem Pin
Dave Kreskowiak9-Feb-09 12:01
mveDave Kreskowiak9-Feb-09 12:01 
GeneralRe: Image printing problem Pin
Duncan Edwards Jones9-Feb-09 5:02
professionalDuncan Edwards Jones9-Feb-09 5:02 
QuestionSetup wizard. Installting package in other system the bellow error showing plz help me. Pin
Nanda_MR6-Feb-09 18:29
Nanda_MR6-Feb-09 18:29 
AnswerRe: Setup wizard. Installting package in other system the bellow error showing plz help me. Pin
Dave Kreskowiak6-Feb-09 19:07
mveDave Kreskowiak6-Feb-09 19:07 
GeneralRe: Setup wizard. Installting package in other system the bellow error showing plz help me. Pin
Nanda_MR8-Feb-09 18:32
Nanda_MR8-Feb-09 18:32 
GeneralRe: Setup wizard. Installting package in other system the bellow error showing plz help me. Pin
Dave Kreskowiak9-Feb-09 1:46
mveDave Kreskowiak9-Feb-09 1:46 
GeneralRe: Setup wizard. Installting package in other system the bellow error showing plz help me. Pin
Nanda_MR9-Feb-09 18:53
Nanda_MR9-Feb-09 18:53 

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.