Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by akitoguc

  1. Hi, PowerPoint can't identify the file path includeing slashes as separators. Try: $present Open [file nativename "D:/Presentation2.pptx"]
  2. Another solution you can try is the following: hm_createmark nodes 1 "by id only" $NodeList; hm_createmark nodes 1 advanced reverse; hm_createmark elems 1 "by nodes" [hm_getmark nodes 1]; hm_getmark elems 1;
  3. With -s option, you can start HyperWorks with the window of the specified dimension and location. For example, you can run hw.exe as following: hw.exe -s 800x600+0+0
  4. To get images of fixed dimension, you can use hwISession CaptureScreenToSize command. In addition, you should not run hw.exe in batch mode to create screen images. Though it might works, it depends on your hardware and driver conditions. Instead of running in batch mode, run hw.exe in GUI mode and close the session by hwISession Close in the end.
  5. In order to have user to specify direction, you can use hm_getdirectionpanel ?message? ?default?value? as well. In this panel, users don't have to select base point.
  6. That's because of mismatch of component names; names in the table has spaces taken away, but components actually has names with spaces. Sorry I'm not clear on what you wnat to do.
  7. You are right, Hao. Syntax to call a command/procedure with parameters is different between Tcl file and command file. Take parentheses and commans away from Tcl statements to port the code to command file. Regards,
  8. Hi, You have to pass parameters, separated by commas and enclosed in parentheses: *writefile("D:/Documents/temp.hm", 1)
  9. You can remove spaces from component name by: set lm [string map {" " ""} $lm] I think you can edit string in your hwtk::table widget by default. If you want to update the component name by editting its name in the table, you can do that by setting a callback procedure to a specific column as '-valueaccept' option: $w columncreate cname -text "Comp Name" -valueaccept "::SetCompName %V %P" The callback procedure can be something like below: proc ::SetCompName { table value prev } { # FIXME: add error handling code *renamecollector comps $prev $value return 1; } Hope it helps.
  10. Hi jouher, Try set values [list cid $CMP cthk {Not Assigned} cname $lm Mname {Not Assigned}]; so as to suppress variable expansion, instead of set values "cid $CMP cthk {Not Assigned} cname $lm Mname {Not Assigned}"; Regards,
  11. You have to initialize the iterator before getting data. Typically, the code becomes: qc$j GetIteratorHandle iter$j for {iter$j First} {[iter$j Valid]} {iter$j Next} { iter$j GetDataList } If you have only one node to query about value, the following code will also work: qc$j GetIteratorHandle iter$j iter$j First set datalist [iter$j GetDataList] Please give it a try.
  12. Hi Emil, One typical approach is to draw contour of the data type you want to get (e.g. Displacement) and query values with poIQueryCtrl and poIQueryIterator classes. You can find the following sample code in the user reference guide: hwi GetSessionHandle mySessionName mySessionName GetProjectHandle myProjectName set pageIndex [myProjectName GetActivePage] myProjectName GetPageHandle myPageName $pageIndex set windowIndex [myPageName GetActiveWindow] myPageName GetWindowHandle myWindowName $windowIndex myWindowName GetClientHandle myPostName set modelIndex [myPostName GetActiveModel] myPostName GetModelHandle myModelName $modelIndex myModelName GetSelectionSetHandle mySetName [myModelName AddSelectionSet element] myModelName GetQueryCtrlHandle myQueryName myQueryName SetSelectionSet [mySetName GetID] myQueryName SetQuery "node.id result.value" If you already have a set of target nodes, set its ID to the query ctrl handle. Another is to access result values directly with hwIDataFile class. Please find the sample code in the reference guide as well. Regards,
  13. Hi Vikas, In order to draw a curve on complex plot, you have to set fields of both three vectors: x, ym (magnitude) and yp (phase). Get handles of these vectors with pltICurveComplex_handle GetVectorHandle iVector which and set file and data type to each of them appropriately. Regards,
  14. Hi pohan, I'm afraid you have preserved nodes which can't be deleted as temp nodes. Try: *clearallpreservednodes Regards,
  15. Hi Jouher, You can get the location (coordinates) of the connector by hm_ce_detailget command as below: hm_ce_detailget id tripearray ce_cords Linked component IDs are obtained as: hm_ce_getlinkedentities id comps Regards,
  16. Hi Pandurang, How about using a hwtk::colorbutton widget? Regards,
  17. Hi Roshan, If you use SimLab 14.2 or later, you can create custom windows using Python and Tkinter. It is also possible to create your own buttons on the custom Ribbon with Python and XML in SimLab 2017.2.1 or a bit earlier ones. Sorry I'm not exactly sure of the version. Regards,
  18. Hi Toan, You can give multiple components, so the statement below is correct. build_plot SelectYComponents {"X" "Y" "Z" "MAG"} Please give it a try.
  19. Hi Toan, You need the following statement as well: client_handle SetDisplayOptions "legend" true
  20. Hi You can get the solid id in the variable 'id' as following: set id [lindex [hm_measureshortestdistance2 0 76 81 solids 2 0 0] 4] or lassign [hm_measureshortestdistance2 0 76 81 solids 2 0 0] d dx dy dz id Hope it helps.
  21. Hi Skull, Cmd window pops up even in batch mode with SimLab 14 or older. You can run your automation scripts without such pop up windows in SimLab 2017. Regards,
  22. Hi Saumya, The following is example code. You need to add a view "View 1" in advance. SetLookAt is available in HW v13 or later. Not sure with older versions as I don't have them anymore. hwi OpenStack hwi GetSessionHandle session_handle session_handle GetProjectHandle project_handle project_handle GetPageHandle page_handle [project_handle GetActivePage] page_handle GetWindowHandle window_handle [page_handle GetActiveWindow] window_handle GetViewControlHandle view_handle view_handle SetLookAt “0 0 0 1 1 1 0 0 1” “View 1” hwi CloseStack Regards,
  23. Hello, You can get element normal by querying with poIQueryCtrl class. If you want to get normal of solid face, you should do it with HyperMesh, not HyperView. Calculating the view matrix from the normal is indeed right approach you can take but I'm afraid it is a bit difficult and complicated. Another thing you can do is to use SetLookAt method provided by poI3DViewCtrl class, which I think is easier for your case. Regards
  24. Hi Toan, Undo/redo is not yet supported for Tcl even in HM 2017. Commands are available for future use, but they don't work. Regards, Oguchi
  • Create New...