|
本帖最后由 tqtgmm163com 于 2020-1-17 17:13 编辑
5 @6 t. S' ]) x9 v {% i2 U
+ |# m6 x" U7 k: F'==============================================================================
6 J; _$ U# L" Y6 N; `9 H' e/ u' WARNING!! This file is overwritten by the Block UI Styler while generating0 Z# F0 q% s( i6 l
' the automation code. Any modifications to this file will be lost after. j) ^) A8 }) c" P+ X1 o6 t* |; u
' generating the code again.1 q9 D6 @# K& u
' g2 y- H2 Q8 A" ? K
' Filename: C:\dlx\press.vb
0 g: |9 b( X5 e9 z/ q: P5 y7 u. a" v'0 I' u6 D9 M: n/ O
' This file was generated by the NX Block UI Styler4 o8 K6 ~8 Z9 @0 k1 P7 Y* {$ \
' Created by: Administrator
% Z& x8 d; H" Z' Version: NX 8.5
^: n! Z4 b3 X5 o% |# a' P- ?' Date: 01-06-2020 (Format: mm-dd-yyyy): k- B1 M. N; s" P# }- U: N3 t
' Time: 16:31 (Format: hh-mm)2 P; [6 B7 v+ @: J e
'
3 A8 m8 v3 \8 ^$ S'==============================================================================$ P! s9 Q' a# S
7 ]2 _; M" `8 g, W- m
'==============================================================================4 K/ x) C; N- \8 f! \* x
'==============================================================================) @; c7 B' t$ C8 i3 G) L
1 v) w1 t! D9 I5 n. F/ x'------------------------------------------------------------------------------8 R7 X3 P9 V- L4 {4 c0 U" t
'These imports are needed for the following template code
* E5 X. W* p) i, f0 G'------------------------------------------------------------------------------
; p) Y( `" ~% jOption Strict Off
& \# j" \9 W! {9 Z2 k; U$ i! dImports System
9 h, g0 X" i7 K" |( P3 l5 p( pImports NXOpen- T' z% F, p' q6 G* ~2 T3 k7 z, H
Imports NXOpen.BlockStyler H% ~6 U" p8 _
) \- t2 m5 L, g0 s+ D: t9 l0 Q'------------------------------------------------------------------------------5 L8 O& s, X9 a Z: y2 t+ j" w1 Y
'Represents Block Styler application class
( e3 \ t2 [( T. S'------------------------------------------------------------------------------1 h9 a4 [% C8 k9 N! p: q2 @$ s
Public Class press6 k6 I" s$ @% H- c( S8 N+ C5 b! `
'class members
X) d3 V/ K8 _! o$ @+ [( l6 P9 q Private Shared theSession As Session" S5 D# B4 N+ Y6 @; a8 A" d, l
Private Shared theUI As UI
( L9 s8 z5 F9 r( ?1 v! k Private theDlxFileName As String
) K: L6 B, @# Y! i Private theDialog As NXOpen.BlockStyler.BlockDialog
+ [6 i. Z5 B- V5 u+ e8 p4 M' A) D Private group0 As NXOpen.BlockStyler.Group ' Block type: Group
$ m) \ ]5 V4 v# Q3 O, ]: `3 C) b* u Private linear As NXOpen.BlockStyler.LinearDimension ' Block type: Linear Dim# q* J0 h- U6 i3 j: M
Private string01 As NXOpen.BlockStyler.StringBlock ' Block type: String h$ T! g! m+ S6 J4 x& L6 T
Private string02 As NXOpen.BlockStyler.StringBlock ' Block type: String: [6 h0 _$ S; |
Private string03 As NXOpen.BlockStyler.StringBlock ' Block type: String
+ I- M) s' o2 H( `" y Private string06 As NXOpen.BlockStyler.StringBlock ' Block type: String& ]) v( U- @$ u
Private string04 As NXOpen.BlockStyler.StringBlock ' Block type: String
9 m0 J8 U3 E0 V7 R) I4 B4 F6 F Private string05 As NXOpen.BlockStyler.StringBlock ' Block type: String5 C& M3 a/ v; F* K( c
Private string07 As NXOpen.BlockStyler.StringBlock ' Block type: String
- ]. L$ [) W# b- ?) W* \ Private string09 As NXOpen.BlockStyler.StringBlock ' Block type: String
. `! T2 T; ]1 k @/ A9 Y( { Private string010 As NXOpen.BlockStyler.StringBlock ' Block type: String
2 Z+ N, m- @5 P& p4 j* [5 G Private string011 As NXOpen.BlockStyler.StringBlock ' Block type: String
4 x, e6 b. m/ U: q0 ^ Private string012 As NXOpen.BlockStyler.StringBlock ' Block type: String
. A, N! w2 n p) e Private list_box0 As NXOpen.BlockStyler.ListBox ' Block type: List Box
+ i; H% U5 U0 g* D" _0 d/ G Public Shared ReadOnly SnapPointTypesOnByDefault_UserDefined As Integer = 12 V1 D$ E4 F) t+ ^! ^5 b' @
Public Shared ReadOnly SnapPointTypesOnByDefault_Inferred As Integer = 2
. H. a1 M0 f( p* @4 \6 F Public Shared ReadOnly SnapPointTypesOnByDefault_ScreenPosition As Integer = 4
5 A% G$ U) N& [6 _' D4 I1 _ Public Shared ReadOnly SnapPointTypesOnByDefault_EndPoint As Integer = 8
I& M, J. Q' N( X' @ ? Public Shared ReadOnly SnapPointTypesOnByDefault_MidPoint As Integer = 16
/ I. T8 U( Y5 P! o( v Public Shared ReadOnly SnapPointTypesOnByDefault_ControlPoint As Integer = 32
) z6 \# f& B+ I/ R, k Public Shared ReadOnly SnapPointTypesOnByDefault_Intersection As Integer = 64
" ]* i9 A) W, s& @, t Public Shared ReadOnly SnapPointTypesOnByDefault_ArcCenter As Integer = 1286 f% O/ P# w+ R j: x$ ?) I
Public Shared ReadOnly SnapPointTypesOnByDefault_QuadrantPoint As Integer = 256
& t& v/ B. d+ g, `, u6 e Public Shared ReadOnly SnapPointTypesOnByDefault_ExistingPoint As Integer = 512' N+ e/ [! W( ?, S- [
Public Shared ReadOnly SnapPointTypesOnByDefault_PointonCurve As Integer = 1024 q2 I, H: a+ B! S% a/ D- @
Public Shared ReadOnly SnapPointTypesOnByDefault_PointonSurface As Integer = 2048, u( `- T$ a- B7 S5 o) S( o% H
Public Shared ReadOnly SnapPointTypesOnByDefault_PointConstructor As Integer = 4096
% D+ y2 K/ Y8 U) B. ^/ w, p: j Public Shared ReadOnly SnapPointTypesOnByDefault_TwocurveIntersection As Integer = 8192* @& r0 B0 J# |+ F. j5 u1 s
Public Shared ReadOnly SnapPointTypesOnByDefault_TangentPoint As Integer = 16384
6 I9 S3 |. X9 a" a: l Public Shared ReadOnly SnapPointTypesOnByDefault_Poles As Integer = 32768% |1 I5 ?3 S! A3 Y" z+ r
Public Shared ReadOnly SnapPointTypesOnByDefault_BoundedGridPoint As Integer = 65536' G! w/ s5 {; B9 Z
- b! F r+ ]+ l* b. @0 k#Region "Block Styler Dialog Designer generator code"3 p% n- F# Y9 Z, l5 @8 u
'------------------------------------------------------------------------------
6 f L$ a; V4 {, Y 'Constructor for NX Styler class
* N6 I' G8 G8 f. | '------------------------------------------------------------------------------
1 s6 X! A* |* l8 V+ {9 I0 A. l4 a3 s Public Sub New()# K% A l1 ?5 p5 N) J
Try* g/ b4 o, c& G
! w" b; m4 [3 h2 j1 M
theSession = Session.GetSession()7 s# N- l1 n+ ?. c; t% A; J
theUI = UI.GetUI()8 T# u( Y9 J3 s1 f4 k$ ~
theDlxFileName = "D:\LIS_ug\TOOL1\PRESS-A01.dlx", O | F2 j: B p
theDialog = theUI.CreateDialog(theDlxFileName)
" M3 ~9 n+ e) s& h: @( o theDialog.AddApplyHandler(AddressOf apply_cb)
9 p/ d6 C5 j( ~' T, g theDialog.AddOkHandler(AddressOf ok_cb)
" R9 k, k9 h5 b! Y5 I theDialog.AddUpdateHandler(AddressOf update_cb)* X! U+ n; C" ^5 j. O! \; M
theDialog.AddInitializeHandler(AddressOf initialize_cb)
" X9 A: ^- y- y1 ?$ b$ m5 B9 L theDialog.AddEnableOKButtonHandler(AddressOf enableOKButton_cb)
6 m' \* T( N% }. K0 u9 S theDialog.AddDialogShownHandler(AddressOf dialogShown_cb)
' ]7 ?- Z" H7 k, Y+ e$ {9 l# X5 ~, `
Catch ex As Exception$ P) _' l2 W. A1 j
/ W5 b5 V9 `! S5 `
Throw ex
5 u3 c, q7 c9 M/ g: Z End Try
: _- I& M. n( S End Sub D0 g/ g% j# w
#End Region M3 d2 m2 Y$ T" N Q, }
p" l, L" f$ G# g Public Shared Sub Main()
+ b0 M2 ~' ? f# d- u0 D Dim thepress As press = Nothing
! \6 \% h) q4 c9 ? Try. x0 B9 d1 r/ Y5 W: l! V+ y7 c
8 Q' j0 C2 D7 {& v( G9 X8 a
thepress = New press()
: U0 a. A# z5 | thepress.Show(). E+ B1 V, C" ~
4 g; M! I+ u; j* U" R: }% ^/ X Catch ex As Exception
. P; K0 z) k" O! Y2 [: G- V
7 t$ [( M1 w# D theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)$ N& j! _) a8 { q& F# X
Finally
8 f: F7 D) Y+ f" m: c7 u If thepress IsNot Nothing Then. D; Z( y6 u: q7 i6 L
thepress.Dispose()
o, A; m8 o7 J/ C% I; y thepress = Nothing/ i( }' b" G9 O5 y" ~0 R
End If
" t* i. n6 w) L; L; E- H) ] End Try$ J a9 y9 {* w2 U G
End Sub6 m( x; W% U2 R' D. Q
Public Shared Function GetUnloadOption(ByVal arg As String) As Integer
3 m8 I$ R+ i. V+ P: @) ^ 'Return CType(Session.LibraryUnloadOption.Explicitly, Integer)
, Z) [* |+ }) l( U# }- k) `1 x0 T Return CType(Session.LibraryUnloadOption.Immediately, Integer)
3 @1 e' @; A& u& Z o ' Return CType(Session.LibraryUnloadOption.AtTermination, Integer)* j$ _( I$ f( t- Q* o4 K/ d5 d
End Function8 _2 M Y! U7 b
Public Shared Sub UnloadLibrary(ByVal arg As String)
# o/ d+ ?* \7 h Try$ p' _+ ^$ R: s, k
6 d1 G: T4 | Z1 b: e0 o6 ]. q3 Y( y6 p3 |) b. y
Catch ex As Exception: I u+ Y1 `: T# a, W+ ?+ v0 V
% S! ]+ k: w) C0 q
theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
6 y8 L4 B/ W" @' Q: Z$ v) `3 } End Try
, {4 v9 y8 W9 e) _ End Sub& K/ q/ `% [8 h N# @+ r
5 U1 i7 I) ?2 S# l7 \; q
'------------------------------------------------------------------------------
2 G: s# B! W- x) v 'This method shows the dialog on the screen( P: e2 b2 d6 @; g6 g' @7 l
'------------------------------------------------------------------------------
, t0 K" z Z9 ?1 q, j G( g* h Public Sub Show()
- U k. p Y. j7 k; c2 ?" } Try
& j4 z( [4 C4 N+ C* W( l4 C" |1 }3 C5 h2 g7 h
theDialog.Show()
: \+ s7 u; R4 j# m6 S: ^7 N2 {( J& G# ~' A; U; ]8 D3 M
Catch ex As Exception j+ v: W1 b' z
! S. w- v1 ~8 Z1 ]- W K5 {$ S
theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
( w5 V( e9 Q% j5 Q End Try
& R* r3 }. I5 o, j$ Q/ H* b# K End Sub$ N! t) [" P% |3 S6 W4 e
; N& J' P# p/ ^& |9 H# }
'------------------------------------------------------------------------------! c6 I5 v& x t% R# z I
'Method Name: Dispose0 I$ T3 O7 s6 R6 z
'------------------------------------------------------------------------------
} |( S7 G' x0 k b! y* F Public Sub Dispose()! q' }# \" C4 C! K2 r2 b
If theDialog IsNot Nothing Then
( i- i4 S2 z7 Z0 v6 X- I theDialog.Dispose()
, u' ` u4 U. h6 r( T: K5 e5 C theDialog = Nothing
, k; g, Q) _( g5 w0 Y+ T End If1 m: v V8 p+ b2 w9 P! D$ N
End Sub
3 [4 f# D9 R; t, u0 h& D1 n/ L
+ C! L! ?( x# N, y+ n# v0 M: I! E2 H. S8 i n1 `. f
'------------------------------------------------------------------------------
$ S V7 e. K. R; V 'Callback Name: initialize_cb
) t* f* Q8 R6 c. Z '------------------------------------------------------------------------------
) B( ~3 R6 _- B% h$ J2 u Public Sub initialize_cb()
- |7 L" _9 j/ K2 s Try9 T" {. \! L0 O2 d6 X0 q# i
$ J, S( c) ~, y) d, b% L group0 = CType(theDialog.TopBlock.FindBlock("group0"), NXOpen.BlockStyler.Group)3 ?) t# [8 w6 }# _
linear = CType(theDialog.TopBlock.FindBlock("linear"), NXOpen.BlockStyler.LinearDimension): D+ U3 }4 x/ R( C( ]/ n7 @8 @( U
string01 = CType(theDialog.TopBlock.FindBlock("string01"), NXOpen.BlockStyler.StringBlock)& q4 d9 H- e0 M K, n. ]
string02 = CType(theDialog.TopBlock.FindBlock("string02"), NXOpen.BlockStyler.StringBlock)+ m& S( H9 C. P! D
string03 = CType(theDialog.TopBlock.FindBlock("string03"), NXOpen.BlockStyler.StringBlock)* e M. y _: N5 g/ B5 F. P
string06 = CType(theDialog.TopBlock.FindBlock("string06"), NXOpen.BlockStyler.StringBlock)
- Q4 \* i: l4 o2 \+ ^ string04 = CType(theDialog.TopBlock.FindBlock("string04"), NXOpen.BlockStyler.StringBlock)
I$ z0 A+ c4 K; Y4 J4 o: i string05 = CType(theDialog.TopBlock.FindBlock("string05"), NXOpen.BlockStyler.StringBlock)" \3 A5 n i& x0 o
string07 = CType(theDialog.TopBlock.FindBlock("string07"), NXOpen.BlockStyler.StringBlock)
; k- M M) [! Y$ U0 M string09 = CType(theDialog.TopBlock.FindBlock("string09"), NXOpen.BlockStyler.StringBlock)% c3 Q) A& ?3 w
string010 = CType(theDialog.TopBlock.FindBlock("string010"), NXOpen.BlockStyler.StringBlock): \' r* O! u- B, \( ^
string011 = CType(theDialog.TopBlock.FindBlock("string011"), NXOpen.BlockStyler.StringBlock)$ ~: c' \$ F0 i/ U
string012 = CType(theDialog.TopBlock.FindBlock("string012"), NXOpen.BlockStyler.StringBlock)/ E0 ~0 B6 G" |& W, _0 Y
list_box0 = CType(theDialog.TopBlock.FindBlock("list_box0"), NXOpen.BlockStyler.ListBox), a0 m$ t0 `$ ^, M7 t4 m0 c
$ K3 g- C8 K4 B6 Y1 H
. {1 W) E' {( _8 q8 j* S v$ G& _0 V- O7 j7 ^) c/ |
Catch ex As Exception
& _9 f/ {/ y+ S3 X: T- B/ e% s, y N6 j6 z/ R9 M0 j5 y$ B: N
theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString): ?% Y7 u! B X2 w
End Try
. c: R2 U8 h9 E( J& \) @% x0 E End Sub" s$ K. y! V7 _ D u/ h. c
) m& ?+ O# g+ k" q
'------------------------------------------------------------------------------
; q6 z( ~$ s$ H# r 'Callback Name: dialogShown_cb
5 T& U% v. h0 N0 P7 g3 { '------------------------------------------------------------------------------
7 } q4 A( c- k3 Q Public Sub dialogShown_cb()* v+ Y8 @1 T2 z$ l1 U" J2 w
Try
- z+ [' }( t6 ] m" l* Z) ]: H$ P9 e- p9 U5 O8 B; Y
h5 q1 p4 h" A) }5 [- g7 b Catch ex As Exception
8 f, ?- s" B- W; u. B" A# d# G; b9 h% A% f5 l2 N; N" l7 ^+ A
theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString), b7 X6 L2 K" L- G0 k/ d
End Try. `* _7 @9 P% }: K1 Q/ m( U
End Sub7 |/ a% z* z! k- f& c8 Y$ g2 M
% V* v) }' a$ q6 t3 P3 `2 l4 |
'------------------------------------------------------------------------------. P6 l" l" E; u( d1 R
'Callback Name: apply_cb
$ p% D2 C+ n8 r; o '------------------------------------------------------------------------------$ D3 x8 @1 F4 d5 _ Z( N
Public Function apply_cb() As Integer8 Y6 K8 Z s3 @: I( o
Dim errorCode As Integer = 0
0 n7 C: p* P4 t Try5 B/ v. ], A* J7 D5 g
) p& I8 ~3 r% D: m- ?% S
# k: N. S' c2 p5 f Catch ex As Exception- a' `2 h) o5 W5 b0 p0 q
$ f* C$ f, _3 v errorCode = 1
5 g8 d( K$ o5 f* C$ i theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString), g0 A9 l8 ^6 s6 m) u) H
End Try Z3 g' t* @* Z
apply_cb = errorCode
H# c1 M5 l9 C1 D3 U5 P1 y# _' z End Function; {! b8 l, h, W# i. L2 R; E( K* F
; b! w2 b1 F* ~2 M" f0 O
'------------------------------------------------------------------------------& K! r+ X& h( m/ Q& b5 I8 B
'Callback Name: update_cb4 u% S" W7 r7 `4 w8 d0 L+ y
'------------------------------------------------------------------------------
! [& x* U) s6 V6 q0 O1 {2 C6 [ Public Function update_cb(ByVal block As NXOpen.BlockStyler.UIBlock) As Integer% r% w1 _8 f. G; m! Y p7 P0 w" U
Try' E1 N/ b8 t% ~ @3 Q* ]
% }: Y+ u/ n! E. m2 x' D8 x4 ` Dim num As Single = CType(linear.Value, Single) '转浮点数: S6 `$ a; b; X2 d7 `0 Z; T7 K) t
Dim aa3 As Decimal = Math.Round((num * string01.Value * string02.Value * 0.001), 3) '3位小数: C) J% u: K) F, e8 v1 z$ X
string03.Value = aa3
' R: Z# b O* d; q Dim aa4 As Decimal = Math.Round((string03.Value * 0.8), 3) '3位小数
) a- o+ [0 |: E j) U% G4 [ string04.Value = aa4# \; q1 w, E+ M4 G% c" g2 E2 h. Q2 e
Dim aa5 As Decimal = Math.Round((string04.Value * 1 / 6), 3) '3位小数) x! C+ v3 `4 q" R( T7 c7 a5 Q0 {
string05.Value = aa5* K5 h4 N* L! g
Dim aa6 As Decimal = Math.Round((string03.Value * 0.06), 3) '3位小数
6 E6 \/ a E' l9 ?% z( u string06.Value = aa6; u+ q6 [4 Q# S: ^2 ? O9 y6 J
5 d, ~8 I: g! v' R+ d9 R
Dim a3 As Single = CType(string03.Value, Single) '转浮点数4 e% z3 c9 ^! e% N
Dim a4 As Single = CType(string04.Value, Single)
# j$ x0 ?+ X! j; j Dim a5 As Single = CType(string05.Value, Single); M' o/ c$ o' `9 u
Dim a6 As Single = CType(string06.Value, Single)6 J# f9 N9 r- z, ^* z Z
: z" L/ u8 `/ _. w1 c! ] Dim b3 As Decimal = Math.Round(a3, 3) '3位小数. W' ^/ B) `1 k5 z0 m
Dim b4 As Decimal = Math.Round(a4, 3)7 R+ n6 p7 ~! E1 ?" A
Dim b5 As Decimal = Math.Round(a5, 3)' }- P& K" i7 d& W' c+ p* u5 @! O
Dim b6 As Decimal = Math.Round(a6, 3)# ?# U2 P8 J5 ~. Q5 ]9 F
4 v b5 a y) N' r8 Y. o$ r
3 a' l( h* F) r; p0 c* l# ` Dim d1 As Decimal = Math.Round((b3 * 1.3 + b6 * 1.3), 3) '2位小数0 ^9 e# o U c% Z5 ]! D
Dim d2 As Decimal = Math.Round((b4 * 1.3 + b5 * 1.3), 3)( Q x/ u6 W( c/ d2 z. Z
) l" K1 a1 W6 b* U string07.Value = d1+ E% k. R/ z( s% ?
string09.Value = d2 w" Q# c" e" `% D; |
4 ]5 e7 N7 f2 u: |& q4 B7 {: t% v
3 d9 ]) m1 g4 n' \( r& I. ^2 z Dim a As Single = CType(string010.Value, Single) '转浮点数1 B: k( |6 q) W' H
Dim b As Single = CType(string011.Value, Single). Z" h5 o# E! h M1 d, U! b
string012.Value = a + b
( {) w3 \4 e4 R& d5 ]4 N
7 U, V/ N0 J4 w, P% T9 z7 i0 N( i5 \; s
+ P( }! Q5 j7 N8 W% B
/ D: n7 g& C2 L+ c$ \6 O' X# `5 i/ p0 ?, q9 [- _
Catch ex As Exception- D' r4 \$ r# i
& l' ?6 F. g. ?4 [) { H theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
3 H! d; U4 ^* \/ C/ K* d- @ End Try2 n& n' Z8 s8 U& c
update_cb = 0
3 k- I. k, `! K- W+ q" I End Function
6 R1 j4 u" ]( v' r9 h: c
( X/ Z, X# H# _- r* b% r7 V8 q% v '------------------------------------------------------------------------------1 h, X, E* b# u4 J. C4 w# X
'Callback Name: ok_cb1 O; y( N7 K8 K: Z+ O/ }# @
'------------------------------------------------------------------------------
1 z! }6 E2 L/ i4 W$ a Public Function ok_cb() As Integer
: y# g3 D3 ]7 c* ` Dim errorCode As Integer = 0
0 q* R' z1 ~% S0 k$ m Try4 `; s$ M8 {# O) ^9 b) n
2 m8 z/ x" e0 P+ A
errorCode = apply_cb()! B- P, N( b' k0 k8 g- Y
0 \; N0 E! A# T Catch ex As Exception
w: j5 {6 A8 t8 T* B! ^
+ a Q2 a' h( a4 }9 D errorCode = 1" t# H6 H" j0 q8 ]) [8 U
theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString), @3 v/ r1 L& L
End Try a& | D5 \* q9 Q
ok_cb = errorCode
& i, k# ~1 E) Q3 T) D, `" j3 s End Function
V! x) ^9 J s9 g" ~+ o$ \
9 J$ R: w4 ?% M$ Z '------------------------------------------------------------------------------+ i" k/ I. v4 U9 ?7 W
'Callback Name: enableOKButton_cb
' r) E% O, d; z' p( f$ ^ '------------------------------------------------------------------------------, T! N: X/ L: a2 A H6 d6 t
Public Function enableOKButton_cb() As Boolean" e( f0 A2 X8 d6 }# {6 y0 ]+ e
enableOKButton_cb = True
0 n$ Z5 Q! ], |' U) f Try, L; g" r% |8 \$ g5 g
7 g* k7 o4 M6 W$ e" m
x. V8 ~4 Z" U+ J3 i& l
Catch ex As Exception
z5 U6 v8 L- R% [9 D; N. d" T8 A' y" b
j3 _) I% r3 {% ]* i% a4 k theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
0 |1 j7 e+ O7 k1 g7 w End Try% h: m% J2 _7 ^ ?1 @8 e
End Function
2 ` \2 m$ i; o+ }9 f/ t
Z- O# e7 {5 Q' I* ` `- a* X. x4 k$ O/ g) C
3 S# O2 W2 p. v '------------------------------------------------------------------------------. w& R' L8 S$ l; t1 |3 N( Z! I
'Function Name: GetBlockProperties& V9 J; D6 W) K
'Returns the propertylist of the specified BlockID2 `1 G, l9 @4 a' R' ^ d R
'------------------------------------------------------------------------------
) ?: A# \+ t2 v- Y2 [ Public Function GetBlockProperties(ByVal blockID As String) As PropertyList7 R+ n0 y; n/ v& s( D
GetBlockProperties = Nothing
- X3 V) Q$ H3 i8 ], N Try
0 {( X$ [, V. G% {2 D/ j9 {$ u# N, |) a
GetBlockProperties = theDialog.GetBlockProperties(blockID)2 {$ E) D- z8 ?; I6 W& r0 C) {; G
3 t* w* O/ k" m; K Catch ex As Exception
4 y; ^, n7 O6 w9 a' c" F5 d& f! o0 o4 m& D. q! E+ ?/ \
theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
- a7 U1 ~0 {' P6 c! o End Try8 j6 V9 p3 b5 G# O
End Function8 J$ w( u) K) h+ Z- E
) x- M' m+ G5 h' wEnd Class
3 c! H& T' n( N
* G; J& V9 P; Y. V: ], F4 D* \3 N" n4 K- f; o1 w
|
|