RE: lingo-l fileIO changes T to t ?!?!?
#thanksEveryOneForAnsweringMySymbolQuestion #THANKSEVERYONEFORANSWERINGMYSYMBOLQUESTION - Michael M. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
All, I wanted to put a final note on this thread for I have been to the mountain and I have spoken with the wise one himself. I asked JHT (John Henry Thompson, father of Lingo, coder extraordinare) a few questions about this topic: 1. Where is that lookup table stored? The symbol table is stored in RAM as a global data structure. 2. Is it persistent with a given movie or the application? The symbol table is persistent with the application. 3. How would I go about clearing that? There is no mechanism for clearing the global symbol table, short of quitting and re-launching the app. Folks had been asking about where this information is stored, when if at all it gets cleared, etc., so I thought I'd share what I heard back from JHT. Hope that helps. Cheers, Tom Higgins Product Manager - Director Team Macromedia ... [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
lingo-l fileIO changes T to t ?!?!?
Hi list... Here's a weird one. The lingo below generates a preferences file if it doesn't previously exist. The default prefs file (a prop list) is theHeaderString. All well and good until it is read back in by FileIO where property pT morphs from pT in the first list to pt in the second list. [#pEnabled:all, #pEmail:, #pMgrEmail:, #pLastAt:[#pC:, #pM:, #pS:, #pT:], #pBeenTo:[:]] [#pEnabled: all, #pEmail: , #pMgrEmail: , #pLastAt: [#pC: , #pM: , #pS: , #pt: ], #pBeenTo: [:]] Why did property pT become pt? Below is my lingo at that point. Thanks, Michael M. theHeaderString = [#pEnabled: QUOTE all QUOTE , #pEmail: QUOTE QUOTE , #pMgrEmail: QUOTE QUOTE , #pLastAt:[#pC: QUOTE QUOTE , #pM: QUOTE QUOTE , #pS: QUOTE QUOTE , #pT: QUOTE QUOTE ], #pBeenTo:[:]] gFileIO.writeString(theHeaderString) theError = gFileIO.status() if theError 0 then alert(X) else gFileIO.openFile(pSavedFiles.pProgressPath, 0) gFileIO.setPosition(0) pProgress = value(gFileIO.readFile()) -- morphs to pt from pT end if [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
That's in the category of just the way Director works. The symbol table stores the case of the first occurrence of any new symbol. Any future use/lookup is case-insensitive, but the original case will always be returned. So you evidently had a preexisting #pt. Now you get... put symbol ( PT ) -- #pt put symbol ( pT ) -- #pt put symbol ( Pt ) -- #pt and so on. At 1353 -0400 05/13/2004, Mendelsohn, Michael wrote: Hi list... Here's a weird one. The lingo below generates a preferences file if it doesn't previously exist. The default prefs file (a prop list) is theHeaderString. All well and good until it is read back in by FileIO where property pT morphs from pT in the first list to pt in the second list. [#pEnabled:all, #pEmail:, #pMgrEmail:, #pLastAt:[#pC:, #pM:, #pS:, #pT:], #pBeenTo:[:]] [#pEnabled: all, #pEmail: , #pMgrEmail: , #pLastAt: [#pC: , #pM: , #pS: , #pt: ], #pBeenTo: [:]] Why did property pT become pt? Below is my lingo at that point. Thanks, Michael M. theHeaderString = [#pEnabled: QUOTE all QUOTE , #pEmail: QUOTE QUOTE , #pMgrEmail: QUOTE QUOTE , #pLastAt:[#pC: QUOTE QUOTE , #pM: QUOTE QUOTE , #pS: QUOTE QUOTE , #pT: QUOTE QUOTE ], #pBeenTo:[:]] gFileIO.writeString(theHeaderString) theError = gFileIO.status() if theError 0 then alert(X) else gFileIO.openFile(pSavedFiles.pProgressPath, 0) gFileIO.setPosition(0) pProgress = value(gFileIO.readFile()) -- morphs to pt from pT end if ... [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
And symbols which exist in Director already are always going to be the way they instantiate them. #member, never #Member put #Member -- #member put #SpriTE -- #sprite At 02:40 PM 5/13/2004, you wrote: That's in the category of just the way Director works. The symbol table stores the case of the first occurrence of any new symbol. Any future use/lookup is case-insensitive, but the original case will always be returned. So you evidently had a preexisting #pt. Now you get... put symbol ( PT ) -- #pt put symbol ( pT ) -- #pt put symbol ( Pt ) -- #pt and so on. At 1353 -0400 05/13/2004, Mendelsohn, Michael wrote: Hi list... Here's a weird one. The lingo below generates a preferences file if it doesn't previously exist. The default prefs file (a prop list) is theHeaderString. All well and good until it is read back in by FileIO where property pT morphs from pT in the first list to pt in the second list. [#pEnabled:all, #pEmail:, #pMgrEmail:, #pLastAt:[#pC:, #pM:, #pS:, #pT:], #pBeenTo:[:]] [#pEnabled: all, #pEmail: , #pMgrEmail: , #pLastAt: [#pC: , #pM: , #pS: , #pt: ], #pBeenTo: [:]] Why did property pT become pt? Below is my lingo at that point. Thanks, Michael M. theHeaderString = [#pEnabled: QUOTE all QUOTE , #pEmail: QUOTE QUOTE , #pMgrEmail: QUOTE QUOTE , #pLastAt:[#pC: QUOTE QUOTE , #pM: QUOTE QUOTE , #pS: QUOTE QUOTE , #pT: QUOTE QUOTE ], #pBeenTo:[:]] gFileIO.writeString(theHeaderString) theError = gFileIO.status() if theError 0 then alert(X) else gFileIO.openFile(pSavedFiles.pProgressPath, 0) gFileIO.setPosition(0) pProgress = value(gFileIO.readFile()) -- morphs to pt from pT end if ... [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!] - roymeo(AT)brokenoffcarantenna.com - i used to love you back when you wrote poetry [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
That's in the category of just the way Director works. The symbol table stores the case of the first occurrence of any new symbol. Yup. This is easy to test using any new arbitrary symbol. Here's what I just did in my Message window: x = #USEALLUPPERCASEFORTHISTEST put symbol(usealluppercaseforthistest) -- #USEALLUPPERCASEFORTHISTEST put symbol(butwhataboutlowercase) -- #butwhataboutlowercase y = #BUTWHATABOUTLOWERCASE put y -- #butwhataboutlowercase So the first entry in the symbol table sticks and so your letter casing may not match expectations. Cheers, Tom Higgins Product Manager - Director Team Macromedia ... [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
Well, thanks for the feedback everyone! Regarding the case following the case of the first occurrence, I went through all of my code and nowhere do I have pt (my Lingo only has pT). So why might this still happen when my first occurrence of this symbol is in fact pT? Thanks, Michael M. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
Just as an addendum to what I previously posted: Clearglobals Showglobals -- Global Variables -- version = 10.0 put symbol(PT) -- #pt put symbol(PK) -- #PK put symbol(Po) -- #Po put symbol(mm) -- #mm put symbol(MM) -- #mm It seems the combination of letters pt/PT/pT/Pt always renders #pt. Hmm...it's as if Director has #pt reserved for something already. Anyone (umm...Tom Higgins?) got any thoughts on this anomaly? - Michael M. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
1) It could be something Director already has in place. 2) It could be something you typed by mistake once, and now it has persisted from session to session because of your continued use of #pT. Many things are stored as symbols besides the things we directly declare as symbols, including variable names and handler names. At 1519 -0400 05/13/2004, Mendelsohn, Michael wrote: Well, thanks for the feedback everyone! Regarding the case following the case of the first occurrence, I went through all of my code and nowhere do I have pt (my Lingo only has pT). So why might this still happen when my first occurrence of this symbol is in fact pT? ... [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
On May 13, 2004, at 3:45 PM, Mendelsohn, Michael wrote: put symbol(PT) -- #pt put symbol(PK) -- #PK put symbol(Po) -- #Po put symbol(mm) -- #mm put symbol(MM) -- #mm It seems the combination of letters pt/PT/pT/Pt always renders #pt. Hmm...it's as if Director has #pt reserved for something already. Anyone (umm...Tom Higgins?) got any thoughts on this anomaly? I think you do somewhere in your code. PUT symbol(PT) -- #PT At least on DMX2004 under Panther. -- Troy RPSystems, Ltd. http://www.rpsystems.net [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
The important idea here is that since you cannot guarantee the case of a symbol, do not rely on the symbols to have the case you want them to be. I BELIEVE these may be persistent with the movie, or something...so once you use #booGERhead in a certain dir file, it stays in there somewhere and no amounts of closing and rebooting will make it go away. Yep, just tested. Director file kept the case after closing. New Director file did not. The important idea here is that since you cannot guarantee the case of a symbol, do not rely on the symbols to have the case you want them to be. roymeo At 03:45 PM 5/13/2004, you wrote: Just as an addendum to what I previously posted: Clearglobals Showglobals -- Global Variables -- version = 10.0 put symbol(PT) -- #pt put symbol(PK) -- #PK put symbol(Po) -- #Po put symbol(mm) -- #mm put symbol(MM) -- #mm It seems the combination of letters pt/PT/pT/Pt always renders #pt. Hmm...it's as if Director has #pt reserved for something already. Anyone (umm...Tom Higgins?) got any thoughts on this anomaly? - Michael M. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!] - roymeo(AT)brokenoffcarantenna.com - i used to love you back when you wrote poetry [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
On May 13, 2004, at 3:59 PM, Troy Rollins wrote: I think you do somewhere in your code. PUT symbol(PT) -- #PT And don't forget, once you've done this, even once, it is registered in the symbol table that way. You would need to close Director and restart to be sure. For instance, now that I have done the above in the message window... PUT symbol(pt) -- #PT -- Troy RPSystems, Ltd. http://www.rpsystems.net [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
Actually, the symbol table follows the .dir (and cst's?) around. They are more persistent than global variables. Closing Director will not make it go away, unless you're only talking playing in Director and not actual director files. roymeo At 04:27 PM 5/13/2004, you wrote: On May 13, 2004, at 3:59 PM, Troy Rollins wrote: I think you do somewhere in your code. PUT symbol(PT) -- #PT And don't forget, once you've done this, even once, it is registered in the symbol table that way. You would need to close Director and restart to be sure. For instance, now that I have done the above in the message window... PUT symbol(pt) -- #PT -- Troy RPSystems, Ltd. http://www.rpsystems.net [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!] --- Roy Crisman Macromedia Director Programmer, Lingo Guru, Multimedia Producer Greater Rochester Macromedia User Group (GRMMUG.org) Coordinator 277 N. Goodman St. Rochester, NY 14607-1162 (585)473-3492 home (585)615-2873 cell roymeo(AT)brokenoffcarantenna.com [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
On May 13, 2004, at 4:27 PM, Troy Rollins wrote: You would need to close Director and restart to be sure. Or, as Roy tested... even that doesn't work. You'd also have to open a different or new project file. -- Troy RPSystems, Ltd. http://www.rpsystems.net [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
If that's the case, how can I edit the symbol table? Actually, the symbol table follows the .dir (and cst's?) around. They are more persistent than global variables. Closing Director will not make it go away, unless you're only talking playing in Director and not actual director files. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
Don't think there's any way to do that. Re-installing Director would probably reset the symbol table to its original state. As mentioned previously, you shouldn't ever rely on the case of a symbol name. Rob From: Mendelsohn, Michael [EMAIL PROTECTED] Date: 2004/05/13 Thu PM 04:55:22 EDT To: [EMAIL PROTECTED] Subject: RE: lingo-l fileIO changes T to t ?!?!? If that's the case, how can I edit the symbol table? Actually, the symbol table follows the .dir (and cst's?) around. They are more persistent than global variables. Closing Director will not make it go away, unless you're only talking playing in Director and not actual director files. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!] [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
Re: lingo-l fileIO changes T to t ?!?!?
And don't forget, once you've done this, even once, it is registered in the symbol table that way. You would need to close Director and restart to be sure. For instance, now that I have done the above in the message window... I think it is stored in the compiled script. So Recompile All Scripts might clear it. John Mathis [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
The important idea here is that since you cannot guarantee the case of a symbol, do not rely on the symbols to have the case you want them to be. You cannot edit the symbol table. That symbol #pt is stuck that way. You could make a new Director movie and copy everything over there. You can NEVER get a symbol #member to be #MEMBER, though, because those are hardwired into director. What you need to do is realize that because symbols are like this, programmers should not try to get capitalization results from symbols. If you require a certain capitalization, you should have a look up table, or use strings instead of symbols. case thisSymbol of #pt: x = pT #px: x = pX etc or instead of [#pt:1,#py:3...] use [pT:1, pY:3 ...] roymeo At 04:55 PM 5/13/2004, you wrote: If that's the case, how can I edit the symbol table? Actually, the symbol table follows the .dir (and cst's?) around. They are more persistent than global variables. Closing Director will not make it go away, unless you're only talking playing in Director and not actual director files. [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!] --- Roy Crisman Macromedia Director Programmer, Lingo Guru, Multimedia Producer Greater Rochester Macromedia User Group (GRMMUG.org) Coordinator 277 N. Goodman St. Rochester, NY 14607-1162 (585)473-3492 home (585)615-2873 cell roymeo(AT)brokenoffcarantenna.com [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
RE: lingo-l fileIO changes T to t ?!?!?
At 16:18 13.05.2004 -0400, roymeo wrote: The important idea here is that since you cannot guarantee the case of a symbol, do not rely on the symbols to have the case you want them to be. I BELIEVE these may be persistent with the movie, or something...so once you use #booGERhead in a certain dir file, it stays in there somewhere and no amounts of closing and rebooting will make it go away. I KNOW this is the case. I once saw a file where some student tried the symbol-string thing on the beatles and while John, Ringo and George all came out as expected, paul would not. And there was no *visible* mentioning of #Paul or #paul in the scripts of that .dir file, still, once you had opened it, that director instance would always convert #Paul to paul. It took a hex editor and some scanning of the .dir file to discover that the .dir contained parts of a *deleted* script text with [#John, #paul, #George, #Ringo] in it. And for some obscure reason director seemed to scan that cached bit of invisible scripttext on opening the file, update the symbol table accordingly and thusly frustrate said student and his lecturer as well. Save As and Save and compact : one of them cleaned the snippet away, the other didn't. I'm too lazy to search which was which. So, if in doubt, do them both. All this was with d5 or d6 so things may have changed, though I doubt they have. Anyway, just don't do it. In those (rare) cases where I find myself to actually need both the thing as symbol (for speed and elegance) and String (for propper case) I usually trade RAM for (complicated coding // speed) and build me some sort of lookup table. to summarize: The important idea here is that since you cannot guarantee the case of a symbol, do not rely on the symbols to have the case you want them to be. ;-) daniel plaenitz [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]