标题:如何实现通过窗体来修改双引号内的表达式的参数?
取消只看楼主
淡若清风①
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2018-4-17
结帖率:0
已结贴  问题点数:20 回复次数:0 
如何实现通过窗体来修改双引号内的表达式的参数?

a = TextBox1.Text
b = TextBox2.Text
c = TextBox3.Text
d = TextBox4.Text
e = TextBox5.Text
k = a * Sin(X / b) + c
Set swApp = _
Application.SldWorks

Set Part = swApp.ActiveDoc
boolstatus = Part.Extension.SelectByID2("草图1", "SKETCH", 0, 0, 0, False, 0, Nothing, 0)
Part.EditSketch
Part.ClearSelection2 True
boolstatus = Part.Extension.SelectByID2("Spline2", "SKETCHSEGMENT", 1.88304242471792E-02, 8.09688949697063E-03, -0.012484411658199, False, 0, Nothing, 0)
Dim equationCurve As Object
boolstatus = Part.Extension.SelectByID2("Spline2", "SKETCHSEGMENT", 1.88304242471792E-02, 8.09688949697063E-03, -0.012484411658199, False, 0, Nothing, 0)
Set equationCurve = Part.SelectionManager.GetSelectedObject5(1)
   boolstatus = equationCurve.SetEquationParameters2("", k, "", d, e, False, 0, 0, 0, True, True)
Part.ClearSelection2 True
Part.SketchManager.InsertSketch True
搜索更多相关主题的帖子: 窗体 Text Set False Nothing 
2018-04-17 19:16



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-486147-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.308234 second(s), 9 queries.
Copyright©2004-2025, BCCN.NET, All Rights Reserved