Jump to content
  • Announcements

    • Rahul Ponginan

      Please click here for a short but important announcement   03/26/17

      Dear Users Our Commercial and Academic users around the world can use these same forums here as before i.e. the Altair Support Forum , Commercial users from India with solver queries can go to the Solver Forum for India Commercial Users , Academic Users from India and AOC India Participants are requested to go to the Forum for India Academic Users and AOC India Participants , We will be tending to all queries in all the forums promptly as before, thank you for your understanding. 
Aditya Palsule

calling tpl file in tcl script for using in hyperview

Recommended Posts

Hi,

it is my lazy way to look for wrapping gui commands

open a C:/sample.tpl file in hyperview:

rename tk_getOpenFile tk_getOpenFile_Old
proc tk_getOpenFile args {return C:/sample.tpl}
hw::ExecuteMenuItem 188
.guiMainWindow.statusbar.bbox.bapply invoke
.guiMainWindow.statusbar.bbox.bcancel invoke
rename tk_getOpenFile ""
rename tk_getOpenFile_Old tk_getOpenFile

 

Share this post


Link to post
Share on other sites
On 5/16/2017 at 0:07 PM, tinh said:

Hi,

it is my lazy way to look for wrapping gui commands

open a C:/sample.tpl file in hyperview:


rename tk_getOpenFile tk_getOpenFile_Old
proc tk_getOpenFile args {return C:/sample.tpl}
hw::ExecuteMenuItem 188
.guiMainWindow.statusbar.bbox.bapply invoke
.guiMainWindow.statusbar.bbox.bcancel invoke
rename tk_getOpenFile ""
rename tk_getOpenFile_Old tk_getOpenFile

 

Hello tinh,

Please can you help to get this tcl script to work on HW13.0

Currently unable to run this on HW13.0.

Currently using in .cmd file

pushd C:\Program Files\Altair\13.0.110\hw\bin\win64
start hw.exe -clientconfig hwplot.dat -tcl Z:\sample.tcl

 

and in sample.tcl this data:

 

rename tk_getOpenFile tk_getOpenFile_Old
proc tk_getOpenFile args {return Z:/TowingTpl.tpl}
hw::ExecuteMenuItem 188
.guiMainWindow.statusbar.bbox.bapply invoke
.guiMainWindow.statusbar.bbox.bcancel invoke
rename tk_getOpenFile ""
rename tk_getOpenFile_Old tk_getOpenFile

 

Please can you able to make this work.

Thanks

Share this post


Link to post
Share on other sites

Hi, 

I am sorry that it did not work. I will check it and inform you.

It may take a bit long time because I don't use hyperview much :ph34r:

Share this post


Link to post
Share on other sites
On 7/19/2017 at 7:38 PM, tinh said:

Hi, 

I am sorry that it did not work. I will check it and inform you.

It may take a bit long time because I don't use hyperview much :ph34r:

Thank you tinh for your reply.

No problem Tinh.

Share this post


Link to post
Share on other sites

Hi @Pradeep

I found it, 

You have to use an HW Desktop class named "hwIReportTemplate"

Looking for its usage in Reference Guide>Hyperworks Desktop,

You have to set parameter pointing to your *.tpl file then invoke hwIReportTemplateApply method

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×