|
Post by mueh on Apr 20, 2021 2:51:21 GMT -5
George: Did ALL MEDIT for spflite src with STATE ON for bas and inc extension . ( required if you continue VIEW Session with x lines ) If no STATE info exists it loads properly . If you end MEDIT and do it again you get the msg STATE file line count does not match the file ( state file line count is count of all previously loadedd files ) and only first two files where loaded . I feel that for MEDIT session STATELOAD and STATESAVE should not be done . CRCMV: Delete STATE info manualy .
Thanks for MCheck macro .
|
|
|
Post by George on Apr 20, 2021 9:00:15 GMT -5
MUEH: If you had asked me, I would have said that STATE was already crippled for MEdit sessions. Obviously not, I'll go kill it.
George
On second thought, I'll check again. MEdit does load STATE data, so it should handle saving as well. Yes, a lot more complicated but ...
George
|
|
|
Post by George on Apr 20, 2021 11:21:06 GMT -5
MUEH: In reviewing this, I think I have stumbled on at least one cause of the STATE errors. The error would only affect users who also use MEdit. (So there may still be un-found errors out there)
Basically, when making the chanes to support adding the saving of STATE data on an END command, where previously it was done only by SAVE, I mucked up the handling of creating STATE data for files in an MEdit sessions. (Which BTW, STATE is supposed to handle, both saving and loading.)
I've (hopefully) corrected this and in the process improved all the STATE error messages to provide more details on just what the errors are, rather than just saying "something went wrong".
I think I will put out a Beta for this. Also since it includes all the MEntry/MExit fixes.
George
|
|
|
Post by mueh on Apr 21, 2021 2:35:19 GMT -5
George: Thanks for Beta 2.4.21110 Made test with color lines and X lines in state data with SPFLite source bas and inc files .
No Problem with MENTRY/MEXIT code and Medit Invalid State data creation is solved .
Just for info when i made some odd MEdit test . Set STATE OFF in Profile for bas ( 1'st file in MEdit ) Load of State Data works perfect . If State is ON in Profile State data is applied to this file . Save of State Data works different . It depends on STATE ON/OFF in Profile of first MEdit File . IF ON State files are created for all MEdit files . (Even Profile has State OFF) If OFF State files are changed only when State File Exists and Profile has STATE ON . ( bas STATE OFF. inc STATE ON) I think this is an odd test and it isn't worth to change something . Just to remember how code works . Thanks
|
|
|
Post by George on Apr 21, 2021 8:23:21 GMT -5
MUEH: Yes, END/SAVE of MEdit can be weird.
It's all timing.
e.g. take an END command. It has to look at each MEdit fle to see if it's modified, then based on the Profile AUTOSAVE decide on Yes/No/Ask the user, then if a SAVE=YES, it has to see if a specific Profile is needed, or whether it can use the one loaded for the 1st file.
And if it turns out SAVE=NO, then it has to examine STATE, and I've chosen to just use the 1st files Profile, otherwise it means loading all the the Profile data in order to look at STATE. It's not perfect, but that routine is now even more complicated with the latest fix. I'll have a look at improving it, but all the Profile swapping is painful.
Many thanks for helping test this.
George
|
|
|
Post by George on Apr 21, 2021 9:35:21 GMT -5
MUEH: OK, added fetching the proper Profile to the END handling of STATE.
George
|
|