Results 1 to 21 of 21

Thread: my program only reads four hex bytes x.X

Threaded View

  1. #1

    Thread Starter
    Member
    Join Date
    Mar 2006
    Posts
    38

    my program only reads four hex bytes x.X

    hi all, my program is acting very weird... im using vbe 2005 and when my program loads from the file and gets what its supposed to get, it only reads the first 4 bytes, adds a FF byte to the start and the end... when i clearly wrote it to load the 6 digits... and i would also like it so that i dont have to write the offset for every letter but make it so it reads From one offset to another, which displays about 385 words, but they all have FF's in between them... so i want it so that it loads the file, then it loads a word, adds it as an item in a dropdownbox, when it gets to the FF's skip the FF's and add the word after to the next item in the dropdownbox... here is the code so far... and i would like someone to edit it please... it would be much appreciated.

    VB Code:
    1. Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    2.         Dim one, two, three, four, five, six As Byte
    3.         Dim A, B, C, D, F, G As String
    4.         Dim bname As String
    5.  
    6.         FileOpen(1, Mainform.OpenFileDialog1.FileName, OpenMode.Binary)
    7.         FileGet(1, one, &H245EEB) ' loads first letter, a P
    8.         FileGet(1, two, &H245EEC) ' loads second letter, an A
    9.         FileGet(1, three, &H245EED) ' loads third letter, a J
    10.         FileGet(1, four, &H245EEE) ' loads fourth letter, an A
    11.         FileGet(1, five, &H245EEF) ' loads fifth letter, a R
    12.         FileGet(1, six, &H246EF0) ' loads sixth letter, an O
    13.         FileClose(1)
    14.         A = ConvertByte(one)
    15.         B = ConvertByte(two)
    16.         C = ConvertByte(three)
    17.         D = ConvertByte(four)
    18.         F = ConvertByte(five)
    19.         G = ConvertByte(six)
    20.         bname = A + B + C + D + F + G ' adds them together to make the word, PAJARO
    21.         ComboBox1.Items.Add(bname) ' adds it as an item
    22.  
    23.     End Sub

    but it only reads PAJA encased by // (which i set as the translation for FF)help would be EXTREMELY appreciated

    -Shaneypoo17
    Last edited by Shaneypoo17; Mar 10th, 2006 at 12:54 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width