Thursday, January 31, 2013

E-Prime 2 Context Logging Bug

Just found another weird issue with E-Prime 2.

The help file (and logic dictates) that if you call c.Log,  the context object should log the variables in that Level to the data file.

However, not only have I figured out how to not get that to work... I have figured out how to get a perfectly good TextDisplay object to not log keystrokes as it should.

The interesting thing is that the information is being correctly logged to the E-Recovery text file that E-prime generates but is not being converted to the .edat2 file.  I do not yet understand why.


Ok, the situation is this; I have in the SessionProc set up a loop using a couple of in-line script objects and a Label object to loop through some movie files and capture responses to them.  A bit hackish.

I have run the E-Recovery file through E-Recover and it gave me a hint that a "Complete Record" is surrounded by a "logframe start" and a "logframe end" tags in the text file.  Makes sense.

My problem is that there are 20-odd logframe start and logframe end tag pairs and it only seems to convert the first one.


Edit:

Ok, as usual there are a couple of "undocumented" features that you need to do to get this working.

You need to call the c.PushNewFrame before your objects and c.PopFrame after the objects have run to get the correct logging levels to appear and be processed by E-Recover.

For instance


c.PushNewFrame

'manually manipulate the objects using script files

c.Log
c.PopFrame

'Loop until exit


Easy once you know the solution.



No comments:

Post a Comment