I like to reuse tablefiles/charts/methods from one model to another.
How can I export these from one model and import to another model ?
I did not find anything in help ....
I like to right-click on these objects and export them to file to import ....
Yes, is feasible for methods and tablefiles, however need to create new object in the destination, then import the exported object and finally rename it.
.... but for charts they is no way to do this.
Sure, creating a method object in the class library is no problem.
So I should not have individual methods on the frame, but create them as classes in the library.
I want to export the chart setup, the inputs table, font settings etc...
...not the result.
Same here, need to copy the chart in the class library, setup and export this template.
OK, thanks I will change the way I work in PlantSim.
Charts on the other hand only display results (as far as I know at least), so i don't see the point of exporting them. If you want to save the charts, look up how to use the 'HTMLReport' object.
A note on that, even though apparently not relevant to the OP: charts also (can) collect the data they display > Chart.CollectData. And you could save those results by either putting them into a tablefile first (Chart.PutValuesIntoTable) or by saving the displayed chart (Chart.CopyBitmapToFile). And saving them as an object should also export the results data, but of course that doesn't make sense
I have implemented a chart template in the class library where I do the basic setups as type of chart, fonts of legends, title etc....
I create a few instances in the frame and rename them to reflect the type of worker (tool tester, parts verificator etc...)
During the resetting the inputs table is updated just by reading the
param objTable : object <<< as input
var tInputChannels : table
tInputChannels := objChart.inputChannels
for iWorker := 1 to NrWorkers
tInputChannels[iWorker,0] := sWorkerType + " " + iWorker
tInputChannels [iWorker, iIndex] := <WorkerType + "Chart[" + to_str(iCol) + "," + iIndex + "]"
iCol += 2
I just had to give you Kudos, because I finally found someone on this forum that uses a nomenclature for local variables (adding the datatype as first letter)
for reusability from one model to other u can try the below option
1) in user objects create a folder
2) Drag and drop tablefiles/charts/methods in to this folder
3) right click on the folder and save as object.
4) open the new model, create a folder in user objects
5) right click on the folder>>>save/load>>load object onto the folder( same object which u saved in Step 3)
6) Now this folder will have all the tablefiles/charts/methods of the previous model
7) Drag and drop to the new model frame.