Results 1 to 10 of 19
Threaded View
-
28th Dec 2010, 10:55 PM #1OPMember
Need a simple AutoComment Script
EDIT 29-12-2010: Searching on the net, I?ve found this script. It says that is an Auto Comment Script. I don?t know if it will work (I know that I have to modify some things to make it work, but basically I want to know it it will work?)
Code:'Attribute VB_Name = "Module1" Sub Main() Dim buttonval As Integer Dim StrLen As Integer Dim App As Object Set App = CreateObject("PCDLRN.Application") Dim Part As Object Set Part = App.ActivePartProgram Dim Cmds As Object Set Cmds = Part.Commands Dim PartProg As Object Set PartProg = App.ActivePartProgram Dim Pname As String Pname = PartProg.PartName StrLen = Len(Pname) Pname = Right(Pname, StrLen - 3) Dim Rnum As String Rnum = PartProg.RevisionNumber Dim Snum As String Snum = PartProg.SerialNumber StrLen = Len(Snum) Snum = Right(Snum, StrLen - 4) Dim MyDate As String MyDate = Date 'MsgBox MyDate Dim MyTime As String MyTime = Time() 'MsgBox MyTime 'Dim Fname As String 'Fname = PartProg.Name 'MsgBox Fname 'On Error 'GoTo label1 Dim Cmd As Object Begin Dialog DLG_REPORT_COMMENT 50, 32, 150, 150, "What Comments Do You Need?" OKButton 90, 8, 40, 14 CancelButton 90, 32, 40, 14 CheckBox 12, 8, 50, 8, "Points", .CheckBox1 CheckBox 12, 24, 50, 8, "Align Bowls", .CheckBox2 CheckBox 12, 40, 50, 8, "Sqr Corner", .CheckBox3 CheckBox 12, 56, 50, 8, "Tube Dia's", .CheckBox4 CheckBox 12, 72, 50, 8, "Pin Dia's", .CheckBox5 CheckBox 12, 88, 35, 8, "Custom", .CheckBox6 TextBox 50, 85, 80, 12, .EditBox1 TextBox 50, 100, 80, 12, .EditBox2 CheckBox 12, 116, 50, 8, "Footer", .CheckBox7 CheckBox 30, 132, 120, 8, "Double Space Comments?",.CheckBox8 End Dialog Dim dlg1 As DLG_REPORT_COMMENT buttonval = Dialog(dlg1) Dim customstr As String customstr = dlg1.EditBox1 Dim customstr2 As String customstr2 = dlg1.EditBox2 Dim lenstr As Integer lenstr = Len(dlg1.EditBox2) 'first command If dlg1.CheckBox1 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) If dlg1.CheckBox8 = 1 Then retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText("Verification Of Intersection Points", COMMENT_FIELD, 2) Else retvaltype = Cmd.PutText("Verification Of Intersection Points", COMMENT_FIELD, 1) End If Cmd.ReDraw End If 'second command If dlg1.CheckBox2 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) If dlg1.CheckBox8 = 1 Then retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText("Verification Of Alignment Points", COMMENT_FIELD, 2) Else retvaltype = Cmd.PutText("Verification Of Alignment Points", COMMENT_FIELD, 1) End If Cmd.ReDraw End If 'third command If dlg1.CheckBox3 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) If dlg1.CheckBox8 = 1 Then retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText("Verification Of Square Corner", COMMENT_FIELD, 2) Else retvaltype = Cmd.PutText("Verification Of Square Corner", COMMENT_FIELD, 1) End If Cmd.ReDraw End If 'forth command If dlg1.CheckBox4 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) If dlg1.CheckBox8 = 1 Then retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText("Verification Of Tube Cavity Diameters", COMMENT_FIELD, 2) Else retvaltype = Cmd.PutText("Verification Of Tube Cavity Diameters", COMMENT_FIELD, 1) End If Cmd.ReDraw End If 'fifth command If dlg1.CheckBox5 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) If dlg1.CheckBox8 = 1 Then retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText("Verification Of Pin Diameters", COMMENT_FIELD, 2) Else retvaltype = Cmd.PutText("Verification Of Pin Diameters", COMMENT_FIELD, 1) End If Cmd.ReDraw End If 'sixth command If dlg1.CheckBox6 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) 'retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText(customstr, COMMENT_FIELD, 1) If lenstr > 0 Then retvaltype = Cmd.PutText(customstr2, COMMENT_FIELD, 2) End If Cmd.ReDraw End If 'seventh command If dlg1.CheckBox7 = 1 Then Set Cmd = Cmds.Add(SET_COMMENT, True) retvaltype = Cmd.PutText("REPT", COMMENT_TYPE, 0) 'retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText(" ", COMMENT_FIELD, 1) retvaltype = Cmd.PutText(" End Of Report:", COMMENT_FIELD, 2) retvaltype = Cmd.PutText("CMM Number: " & Pname & " Part Number: " & Rnum, COMMENT_FIELD, 3) retvaltype = Cmd.PutText("TRC Number: " & Snum & " " & MyDate & " " & MyTime, COMMENT_FIELD, 4) Cmd.ReDraw End If End Sub 'label1: 'End Sub
--------------------------------Original Message---------------------------
Hi to everyone, I have recently found this amazing forum, and I?ve completelly fallen inwith it! jeje
Well, I have a "friend" that knows a lot about PHP, Scripting, and else. And he made a "Auto Comment Script" (it automatically makes comments in a web called Taringa.net, as soon as a new thread is created)
But the problem is that he is selling it, and I don?t have virtual money in order to buy it.
So I was wondering if you could help me with this, I?d be really pleased
Thanks for readingscrewu Reviewed by screwu on . Need a simple AutoComment Script EDIT 29-12-2010: Searching on the net, I?ve found this script. It says that is an Auto Comment Script. I don?t know if it will work (I know that I have to modify some things to make it work, but basically I want to know it it will work?) 'Attribute VB_Name = "Module1" Sub Main() Dim buttonval As Integer Dim StrLen As Integer Dim App As Object Set App = CreateObject("PCDLRN.Application") Rating: 5
Sponsored Links
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
Help me with simple VB Script
By Xeon in forum Web Development AreaReplies: 0Last Post: 16th Sep 2012, 10:06 AM -
[Hiring] Simple web script
By Thrill in forum Marketplace (Buy, Sell and Trade)Replies: 1Last Post: 9th Sep 2012, 05:22 AM -
[Hiring] Need php developer for simple script.
By pisoj1 in forum ServicesReplies: 7Last Post: 7th Jun 2012, 12:45 PM -
Need Simple PHP/JS Script
By Netguy in forum Web Development AreaReplies: 0Last Post: 22nd Jan 2011, 03:30 PM -
Simple PHP Shell script
By litewarez in forum Webmaster ResourcesReplies: 8Last Post: 30th Mar 2009, 11:16 PM
themaLeecher - leech and manage...
Version 5.03 released. Open older version (or...