[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[TCML] Javatc to Version 11.6



Hi All,

Javatc has a new function added. The new function is for saving your design inputs in a JavaScript file to your hard drive which can then be reloaded using the "Load Demo Coil" button at the top of the form.

Adam contacted me looking for a way to do this so that he didn't have to keep typing in all the data fields. There is of course is a way to do this but it was very cumbersome (the loading script file data had to be edited).

JavaScript is "client" side code. In other words, once it's loaded from a server (classictesla.com), it is totally in your computers memory. Everything you do is done by your computer. JavaScript cannot access your hard drive to save files or anything like that (this is part of the limitation of JavaScript and for good reason regarding security). But it's good as you can run Javatc on your pc without the need of a server. I can't open a Save File dialog for you, but there is a way to get around this.

At the bottom of Javatc there is a text area. I've added a second button "Make Load File" which writes your current design inputs in a JavaScript format. If you copy and paste this file in a text editor like Notepad and save it as JTC_load.js inside the "/script" folder of Javatc on your hard drive, your design will be the data that loads when you click the "Load Demo Coil" button at the top of the form. Down by the "Make Load File" button there is a little help question mark box which will open up a help window for details on how to do this.

After you save the file as "JTC_load.js" you will need to refresh your browser and reload the page (all scripts are loaded during the initial page loading event). Then just click the "Load Demo Coil" button and your data will be loaded.

Although the web version will have the same functionality of saving the file (via your text editor), you can't load it unless your running the pc version from your hard drive (server side files are on the server and you can't write to the server).

Anyway, this makes it possible to save several designs and reload them simply by renaming the load file you desire to "JTC_load.js". Depending on how you use Javatc, this may or may not be of value, but for some it might come in handy.

Javatc is now at version 11.6 due to this addition.
Server version: http://www.classictesla.com/java/javatc.html

PC Download version: http://www.classictesla.com/java/javatc.zip

Take care,
Bart


_______________________________________________
Tesla mailing list
Tesla@xxxxxxxxxxxxxx
http://www.pupman.com/mailman/listinfo/tesla