Your Products have been synced, click here to refresh
Sub[SIZE=2][COLOR=#000000] Main [/COLOR] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00]'PCDMIS COMMANDS assignment [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] App, Part, Cmds, Cmd [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Object Set[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] App = CreateObject("PCDLRN.Application")[/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Set[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Part = App.ActivePartProgram[/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Set[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmds = Part.Commands [/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[SIZE=2][COLOR=#000000] Oper [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Job [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Samp [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Shift [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Fixture [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Probe [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String [/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]For[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Each[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]In[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmds[/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] Cmd.[/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Type[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = ASSIGNMENT Then [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "CMMPROGRAM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Prognam=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PRINTNUM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Printnum=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PRINTREV" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Printrev=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PARTNAM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Partnam=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PARTNUM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Partnum=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] Cmd.GetText(DEST_EXPR, 0) = "OPERATOR" [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Opera=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "JOB" [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Jo=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR,0) = "SAMP" [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Sam=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If Next[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd [/COLOR] Printnam = Printnum & " , Rev : " & Printrev [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00]'Opens Dialog For Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Begin[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dialog[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] DIALOG_1 50,10, 300, 125, oOPERATORINPUT [/COLOR] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00]'Display text For Program Information [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 160,10,80,12, "Program Name :" Textbox 160,20,120,12, .Text1, &h0800& ' Readonly Text 160,32,80,12, "Print Information :" Textbox 160,42,120,12, .Text2[SIZE=2], &h0800& ' Readonly[/SIZE] Text 160,54,80,12, "Part Name :" Textbox 160,64,120,12, .Text3[SIZE=2], &h0800& ' Readonly[/SIZE] Text 160,76,80,12, "Part Number :" Textbox 160,86,120,12, .Text4[SIZE=2], &h0800& ' Readonly[/SIZE] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text For Operator Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,15,85,12, "Enter Operator :" TextBox 65,13,50,12, .Text5 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text For Job # Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,35,85,12, "Enter Job # :" TextBox 65,33,50,12, .Text6 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text For Sample # Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,55,85,12, "Enter Sample # :" TextBox 65,53,20,12, .Text7 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Buttons & Text For Shift Selection [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]GroupBox 5,65,150,25 Text 10,75,25,12, "Shift # :" OptionGroup .grp1 OptionButton 50,74,22,12, "1st", .option1 OptionButton 75,74,22,12, "2nd", .option2 OptionButton 100,74,22,12, "3rd", .option3 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text & Buttons For Help Request [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,95,50,24, "Notes :" Text 35,95,85,12, "(Check what you need)" Text 10,105,35,12, "Fixturing?" CheckBox 45,104,20,12, .CheckBox_4 Text 70,105,25,12,"Probe?" CheckBox 95,104,20,12, .CheckBox_5 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Ok And Cancel Buttons [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]OKButton 160,100,57,15 CancelButton 225,100,57,15 [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dialog [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Code Begins [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Dialg [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] DIALOG_1[/COLOR] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Dimension Text Boxes To show Variables [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Dialg.Text1=Prognam Dialg.Text2=Printnam Dialg.Text3=Partnam Dialg.Text4=Partnum Dialg.Text5=Opera Dialg.Text6=Jo Dialg.Text7=Sam [/SIZE]
Sub[SIZE=2][COLOR=#000000] Main [/COLOR] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00]'PCDMIS COMMANDS assignment [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] App, Part, Cmds, Cmd [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Object Set[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] App = CreateObject("PCDLRN.Application")[/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Set[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Part = App.ActivePartProgram[/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Set[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmds = Part.Commands [/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[SIZE=2][COLOR=#000000] Oper [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Job [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Samp [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Shift [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Fixture [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Probe [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]String [/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]For[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Each[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]In[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmds[/COLOR] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] Cmd.[/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Type[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] = ASSIGNMENT Then [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "CMMPROGRAM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Prognam=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PRINTNUM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Printnum=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PRINTREV" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Printrev=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PARTNAM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Partnam=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "PARTNUM" Then[/COLOR] blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Partnum=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] Cmd.GetText(DEST_EXPR, 0) = "OPERATOR" [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Opera=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR, 0) = "JOB" [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Jo=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd.GetText(DEST_EXPR,0) = "SAMP" [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Then [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]blr= Cmd.GetText( SRC_EXPR, 0) bll= Len(blr) Sam=Mid(blr,2,bll-2) Cmd.ReDraw [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2] [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]If Next[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Cmd [/COLOR] Printnam = Printnum & " , Rev : " & Printrev [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00]'Opens Dialog For Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Begin[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dialog[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] DIALOG_1 50,10, 300, 125, oOPERATORINPUT [/COLOR] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00]'Display text For Program Information [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 160,10,80,12, "Program Name :" Textbox 160,20,120,12, .Text1, &h0800& ' Readonly Text 160,32,80,12, "Print Information :" Textbox 160,42,120,12, .Text2[SIZE=2], &h0800& ' Readonly[/SIZE] Text 160,54,80,12, "Part Name :" Textbox 160,64,120,12, .Text3[SIZE=2], &h0800& ' Readonly[/SIZE] Text 160,76,80,12, "Part Number :" Textbox 160,86,120,12, .Text4[SIZE=2], &h0800& ' Readonly[/SIZE] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text For Operator Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,15,85,12, "Enter Operator :" TextBox 65,13,50,12, .Text5 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text For Job # Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,35,85,12, "Enter Job # :" TextBox 65,33,50,12, .Text6 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text For Sample # Input [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,55,85,12, "Enter Sample # :" TextBox 65,53,20,12, .Text7 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Buttons & Text For Shift Selection [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]GroupBox 5,65,150,25 Text 10,75,25,12, "Shift # :" OptionGroup .grp1 OptionButton 50,74,22,12, "1st", .option1 OptionButton 75,74,22,12, "2nd", .option2 OptionButton 100,74,22,12, "3rd", .option3 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Box & Text & Buttons For Help Request [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Text 10,95,50,24, "Notes :" Text 35,95,85,12, "(Check what you need)" Text 10,105,35,12, "Fixturing?" CheckBox 45,104,20,12, .CheckBox_4 Text 70,105,25,12,"Probe?" CheckBox 95,104,20,12, .CheckBox_5 [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Ok And Cancel Buttons [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]OKButton 160,100,57,15 CancelButton 225,100,57,15 [/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]End[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dialog [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Code Begins [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]Dim[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] Dialg [/COLOR][/SIZE][SIZE=2][COLOR=#0000ff][SIZE=2][COLOR=#0000ff]As[/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2][COLOR=#000000] DIALOG_1[/COLOR] [/SIZE][SIZE=2][COLOR=#007f00][SIZE=2][COLOR=#007f00] 'Dimension Text Boxes To show Variables [/COLOR][/SIZE][/COLOR][/SIZE][SIZE=2]Dialg.Text1=Prognam Dialg.Text2=Printnam Dialg.Text3=Partnam Dialg.Text4=Partnum Dialg.Text5=Opera Dialg.Text6=Jo Dialg.Text7=Sam [/SIZE]
© 2024 Hexagon AB and/or its subsidiaries. | Privacy Policy | Cloud Services Agreement |