Author Topic: TFE - Resurrection (TI-File Editor)  (Read 26200 times)

0 Members and 1 Guest are viewing this topic.

Offline cooliojazz

  • Support Staff
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 619
  • Rating: +66/-9
  • I omnoms on your soul
    • View Profile
    • Unreal Phantasies
TFE - Resurrection (TI-File Editor)
« on: May 20, 2010, 12:07:22 am »
After umpteen-months, I finally finished a semi-functional version of TI-File Editor.  Right now, it can finally open and save programs.  I finally found my error after such a long time of searching (it was very stupid :P) But anyways, i do not have most mdi things working, so just be alert...  Oh, and yes, I know there's no easy way to write things like -> yet... ill work on that next... For now, just copy from an existing file... or wait, did I fix those? idk, oh well... :P  Oh, and encounter any errors? Please tell me :D
« Last Edit: May 20, 2010, 12:18:54 am by cooliojazz »
Spoiler For Random signess:
You can not beat my skills.
Trust me.
So don't even try.
And remember never to trust someone who says, "Trust me."

TI File Editor Progress: Remade in java like a boss. 50% we'll call it? IDK =P
Java Libraries: JIRC - 90% JTIF - 5%
TI Projects: Unreal Notator - -5000%
Nomcraft, a Bukkit mod
Some of the music I write can be found here | The Rest Should Be Here (Bandcamp)

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: TFE - Resurrection
« Reply #1 on: May 20, 2010, 12:16:05 am »
I'm glad this didn't died, I was worried a few months ago. It looks nice so far. One bug I found tho is when saving as. I got to use the regular save option otherwise I get an error. But it opens files fine and the regular save option saves fine too.

This should be a good offline alternative to the 16 bits TI-Graph Link software. Are you planning to add a command menu at one point?
« Last Edit: May 20, 2010, 12:16:47 am by DJ Omnimaga »

Offline cooliojazz

  • Support Staff
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 619
  • Rating: +66/-9
  • I omnoms on your soul
    • View Profile
    • Unreal Phantasies
Re: TFE - Resurrection (TI-File Editor)
« Reply #2 on: May 20, 2010, 12:20:07 am »
Mk, I'll look into that.  And definitely.  That's one of the things i'll be working on next...
Spoiler For Random signess:
You can not beat my skills.
Trust me.
So don't even try.
And remember never to trust someone who says, "Trust me."

TI File Editor Progress: Remade in java like a boss. 50% we'll call it? IDK =P
Java Libraries: JIRC - 90% JTIF - 5%
TI Projects: Unreal Notator - -5000%
Nomcraft, a Bukkit mod
Some of the music I write can be found here | The Rest Should Be Here (Bandcamp)

Offline meishe91

  • Super Ninja
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2946
  • Rating: +115/-11
    • View Profile
    • DeviantArt
Re: TFE - Resurrection (TI-File Editor)
« Reply #3 on: May 20, 2010, 12:28:59 am »
Ya, same thing as DJ really. Only the saving issue I saw. Opens files great as far as I can tell.

As for the "" though would alt+26 work the same since it displays a "→?" I mean you can type it in fine, I just don't know if it will save correctly.

Great job on this :)
Spoiler For Spoiler:



For the 51st time, that is not my card! (Magic Joke)

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: TFE - Resurrection (TI-File Editor)
« Reply #4 on: May 20, 2010, 04:51:00 pm »
This sounds awesome!  I'm glad it didn't die. :)

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: TFE - Resurrection (TI-File Editor)
« Reply #5 on: May 20, 2010, 07:00:58 pm »
Mk, I'll look into that.  And definitely.  That's one of the things i'll be working on next...
Glad to hear!

Hopefully this will come handy for people like Juju or Eeems who don't have access to a working calc. Typing programs in WabbitEmu is not always convenient.

For Juju2143, one issue tho is that he uses Linux, but IIRC he has dual-booting

Offline cooliojazz

  • Support Staff
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 619
  • Rating: +66/-9
  • I omnoms on your soul
    • View Profile
    • Unreal Phantasies
Re: TFE - Resurrection (TI-File Editor)
« Reply #6 on: May 20, 2010, 07:09:22 pm »
Hey, you guys, when getting the error, were you trying to save a new file?
Spoiler For Random signess:
You can not beat my skills.
Trust me.
So don't even try.
And remember never to trust someone who says, "Trust me."

TI File Editor Progress: Remade in java like a boss. 50% we'll call it? IDK =P
Java Libraries: JIRC - 90% JTIF - 5%
TI Projects: Unreal Notator - -5000%
Nomcraft, a Bukkit mod
Some of the music I write can be found here | The Rest Should Be Here (Bandcamp)

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: TFE - Resurrection (TI-File Editor)
« Reply #7 on: May 20, 2010, 07:24:41 pm »
Yeah, using the save as option, I tried saving under a new file name

Windows 7 64 bit on my side

Offline cooliojazz

  • Support Staff
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 619
  • Rating: +66/-9
  • I omnoms on your soul
    • View Profile
    • Unreal Phantasies
Re: TFE - Resurrection (TI-File Editor)
« Reply #8 on: May 20, 2010, 07:27:32 pm »
Err, i mean like did you click new file to get a blank one, then try to save it? tho it doesnt sound like you did... which means thats another error x.x Till i update it, (which should be soon) (not like last time's "soon"!) please dont save new files =P
Spoiler For Random signess:
You can not beat my skills.
Trust me.
So don't even try.
And remember never to trust someone who says, "Trust me."

TI File Editor Progress: Remade in java like a boss. 50% we'll call it? IDK =P
Java Libraries: JIRC - 90% JTIF - 5%
TI Projects: Unreal Notator - -5000%
Nomcraft, a Bukkit mod
Some of the music I write can be found here | The Rest Should Be Here (Bandcamp)

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: TFE - Resurrection (TI-File Editor)
« Reply #9 on: May 20, 2010, 08:02:00 pm »
oh, no, I opened an existing file, edited it a bit, then saved as, under a new name. I did not try with a new file

Offline meishe91

  • Super Ninja
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2946
  • Rating: +115/-11
    • View Profile
    • DeviantArt
Re: TFE - Resurrection (TI-File Editor)
« Reply #10 on: May 20, 2010, 11:20:18 pm »
I think I tried both with an existing (re-saving it with "Save-as") and a new one. Got the same message both times.
Spoiler For Spoiler:



For the 51st time, that is not my card! (Magic Joke)

Offline Geekboy1011

  • The Oneironaut
  • Donator
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2031
  • Rating: +119/-2
  • Dream that Awakening dream
    • View Profile
Re: TFE - Resurrection (TI-File Editor)
« Reply #11 on: May 21, 2010, 12:31:17 am »
awsome ive been wondering how this has been progressing great to see ^_^

Offline cooliojazz

  • Support Staff
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 619
  • Rating: +66/-9
  • I omnoms on your soul
    • View Profile
    • Unreal Phantasies
Re: TFE - Resurrection (TI-File Editor)
« Reply #12 on: May 23, 2010, 02:13:27 am »
Ok, so i seem to have an issue...  People have tried to save files and just gotten random errors that seem to be generated from a mid() somewhere, but ONLY WHEN SAVING AS, not just plain save. So...
1.  Can more people try this and tell me whether they get the error?  Note that i personally have not as of yet been able to recreate it (otherwise i would just be trying to debug this myself all the rest of the night =P)
2.  Does a VB programmer want to look at it and tell me if the see anything?...
Code: [Select]
    Private Sub SaveFile() Handles SaveToolStripButton.Click, SaveToolStripMenuItem.Click
        If Not String.IsNullOrEmpty(CurrentFilePath) Then
            SaveFileRoutine(CurrentFilePath)
        Else
            If SaveTIFile.ShowDialog = DialogResult.OK Then
                SaveFileRoutine(SaveTIFile.FileName)
                UpdateInfo(1) = SaveTIFile.FileName
                UpdateInfo(2) = "1"
            End If
        End If
    End Sub

    Private Sub SaveAsToolStripMenuItem_Click() Handles SaveAsToolStripMenuItem.Click
        If SaveTIFile.ShowDialog = DialogResult.OK Then
            SaveFileRoutine(SaveTIFile.FileName)
            UpdateInfo(1) = SaveTIFile.FileName
            UpdateInfo(2) = "1"
        End If
    End Sub
    Private Function SaveFileRoutine(ByVal FilePath As String)
        Dim FileBytes(1048576) As Byte
        Dim FileBytesCounter1 As Integer = 0
        Dim y As Integer
        Dim CurrentByte As String
        Dim CurrentString As String = ""
        Dim SecondByte As String
        Dim TempContents As String = ProgramContents(CurrentFileNumber)
        While True
            If InStr(TempContents, vbCrLf) Then
                TempContents = Mid(TempContents, 1, InStr(TempContents, vbCrLf) - 1) + "{vbCrLf}" + Mid(TempContents, InStr(TempContents, vbCrLf) + 2, TempContents.Length - InStr(TempContents, vbCrLf))
            Else
                Exit While
            End If
        End While
        For x As Integer = 1 To TempContents.Length
            y = 15
            SecondByte = ""
            CurrentHex = Mid(TempContents, x, y)
            CurrentByte = myTITools.TokenToHex(CurrentHex, SecondByte)
            While CurrentByte = ""
                SecondByte = ""
                CurrentHex = Mid(TempContents, x, y)
                CurrentByte = myTITools.TokenToHex(CurrentHex, SecondByte)
                If y < 1 Then
                    MsgBox("Invalid Character Detected!" & vbCrLf & """" & CurrentHex & """" & vbCrLf & "is not recognized as a usable token for the TI 83+/84+ Series of calculators.")
                    FileBytesCounter1 -= 1
                    GoTo Skip
                End If
                y -= 1
            End While
            If SecondByte = "" Then
                FileBytes(74 + FileBytesCounter1) = cInteger(CurrentByte)
            Else
                FileBytes(74 + FileBytesCounter1) = cInteger(CurrentByte)
                FileBytes(75 + FileBytesCounter1) = cInteger(SecondByte)
                FileBytesCounter1 += 1
            End If
Skip:
            FileBytesCounter1 += 1
            x += y
        Next
        '**TI83F*
        FileBytes(0) = 42
        FileBytes(1) = 42
        FileBytes(2) = 84
        FileBytes(3) = 73
        FileBytes(4) = 56
        FileBytes(5) = 51
        FileBytes(6) = 70
        FileBytes(7) = 42
        '1A,0A,00
        FileBytes(8) = 26
        FileBytes(9) = 10
        FileBytes(10) = 0
        'Comment
        FileComment(CurrentFileNumber).PadRight(42)
        For x As Integer = 0 To 41
            FileBytes(x + 11) = AscW(FileComment(CurrentFileNumber).Chars(x))
        Next
        'Data Size
        If FileBytesCounter1 + 19 > 255 Then
            Dim TempHex = cHex(FileBytesCounter1 + 19, 4)
            FileBytes(54) = cInteger(Mid(TempHex, 1, 2))
            FileBytes(53) = cInteger(Mid(TempHex, 3, 2))
        Else
            FileBytes(54) = 0
            FileBytes(53) = FileBytesCounter1 + 19
        End If
        'Random Flag (either B or D)
        FileBytes(55) = 13
        FileBytes(56) = 0
        'Variable Size
        If FileBytesCounter1 + 2 > 255 Then
            Dim TempHex = cHex(FileBytesCounter1 + 2, 4)
            FileBytes(58) = cInteger(Mid(TempHex, 1, 2))
            FileBytes(57) = cInteger(Mid(TempHex, 3, 2))
        Else
            FileBytes(58) = 0
            FileBytes(57) = FileBytesCounter1 + 2
        End If
        'Type ID
        FileBytes(59) = 5
        'Name
        FileName(CurrentFileNumber).PadRight(8)
        For x As Integer = 0 To 7
            FileBytes(60 + x) = AscW(FileName(CurrentFileNumber).Chars(x))
        Next
        'Version
        FileBytes(68) = 0
        'Archived
        FileBytes(69) = 0
        'Variable Size Again
        If FileBytesCounter1 + 2 > 255 Then
            Dim TempHex = cHex(FileBytesCounter1 + 2, 4)
            FileBytes(71) = cInteger(Mid(TempHex, 1, 2))
            FileBytes(70) = cInteger(Mid(TempHex, 3, 2))
        Else
            FileBytes(71) = 0
            FileBytes(70) = FileBytesCounter1 + 2
        End If
        'Total Token Count
        If FileBytesCounter1 > 255 Then
            Dim TempHex = cHex(FileBytesCounter1, 4)
            FileBytes(73) = cInteger(Mid(TempHex, 1, 2))
            FileBytes(72) = cInteger(Mid(TempHex, 3, 2))
        Else
            FileBytes(73) = 0
            FileBytes(72) = FileBytesCounter1
        End If
        'Totals data
        Dim Counter = 0
        For x As Integer = 0 To FileBytesCounter1 + 19
            Counter += FileBytes(x + 55)
        Next
        'Lower 16 bits of data totalled together
        If Hex(Counter).Length > 4 Then Counter = cInteger(Mid(cHex(Counter, 4), cHex(Counter, 4).Length - 4, 4))
        If Counter > 255 Then
            FileBytes(FileBytesCounter1 + 75) = cInteger(Mid(cHex(Counter, 4), 1, 2))
            FileBytes(FileBytesCounter1 + 74) = cInteger(Mid(cHex(Counter, 4), 3, 2))
        Else
            FileBytes(FileBytesCounter1 + 75) = 0
            FileBytes(FileBytesCounter1 + 74) = Counter
        End If
        Dim FinalBytes(FileBytesCounter1 + 75) As Byte
        For x As Integer = 0 To FileBytesCounter1 + 75
            FinalBytes(x) = FileBytes(x)
        Next
        File.WriteAllBytes(FilePath, FinalBytes)
        CurrentBytes = FileBytes
    End Function
Spoiler For Random signess:
You can not beat my skills.
Trust me.
So don't even try.
And remember never to trust someone who says, "Trust me."

TI File Editor Progress: Remade in java like a boss. 50% we'll call it? IDK =P
Java Libraries: JIRC - 90% JTIF - 5%
TI Projects: Unreal Notator - -5000%
Nomcraft, a Bukkit mod
Some of the music I write can be found here | The Rest Should Be Here (Bandcamp)

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: TFE - Resurrection (TI-File Editor)
« Reply #13 on: May 23, 2010, 07:30:56 am »
I kinda wish I could help, I haven't done VB in 7 years :(

Offline meishe91

  • Super Ninja
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2946
  • Rating: +115/-11
    • View Profile
    • DeviantArt
Re: TFE - Resurrection (TI-File Editor)
« Reply #14 on: May 23, 2010, 04:13:56 pm »
I just tried it again. I get the error whether I use Save, Save-As, or the Save button.
Spoiler For Spoiler:



For the 51st time, that is not my card! (Magic Joke)