Javascript Diagnostic Output?
All  1-2  3-8

Previous
Next
 From:  Michael Gibson
7161.3 In reply to 7161.1 
Hi Samuel, you can use either moi.ui.alert( 'msg' ) to pop up an alert dialog, or yes moi.log( 'msg' ); will put it in the diagnostic log which is not saved to disk though but can be shown in a pop up MoI window by putting in the following script on a shortcut key:

script: /* show log window */ moi.ui.createDialog( 'ShowLog.htm' );

moi.ui.alert() can be good for individual messages, the log is good if you want to output a whole bunch of stuff and look at it all at once later rather than as individual pop up messages.

Hope this helps!

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  libelle
7161.4 In reply to 7161.3 
Hi Michael,

The "alert" popups eventually showed me that I'd had an error in my regular expression, so I'd solved my initial problem. But using the log will be much better as I continue to do other work!

I read somewhere in these forums where you mentioned that there might one day be an ini file setting to bypass caching of Javascript files. I know that the scripting API is (and probably should be) a relatively low priority, but I would vote for that feature if it were not too difficult to implement.

Thank you,
___Samuel___
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
7161.5 In reply to 7161.4 
Hi Samuel, I'm glad you've got the initial problem solved!

re: file caching - that did get implemented in Moi v3, go to Options > General and push the "Edit .ini file" button, and inside there set DisableFileCaching=y . That will make MoI freshly reload the file every time a command is run rather than caching them in memory like it will do by default. More info here:
http://moi3d.com/forum/index.php?webtag=MOI&msg=6727.2

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  libelle
7161.6 In reply to 7161.5 
You seem to anticipate every feature I think I want :)

Thanks!
___Samuel___
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Max Smirnov (SMIRNOV)
7161.7 
I use moi.log and modified ShowLog.htm with autoupdate and autoscroll.
And a text labels placed in the scene.


P.S. Michael, is there any possibility to clear the log?

EDITED: 7 Mar 2022 by SMIRNOV

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  Michael Gibson
7161.8 In reply to 7161.7 
Hi Max, sorry no there's not currently any way to clear the log.

I can add something for that for v4, and also probably can add something to make the log get dynamically shown a system debug output viewer.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All

 

 
 
Show messages: All  1-2  3-8