提交 fd325722 编写于 作者: leaky114's avatar leaky114

22.5.27新增新建序号时颜色指示

上级 2b610981
...@@ -28,5 +28,5 @@ Imports System.Runtime.InteropServices ...@@ -28,5 +28,5 @@ Imports System.Runtime.InteropServices
' You can specify all the values or you can default the Build and Revision Numbers ' You can specify all the values or you can default the Build and Revision Numbers
' by using the '*' as shown below: ' by using the '*' as shown below:
<Assembly: AssemblyVersion("1.22.5.11")> <Assembly: AssemblyVersion("1.22.5.27")>
<Assembly: AssemblyFileVersionAttribute("1.22.5.11")> <Assembly: AssemblyFileVersionAttribute("1.22.5.27")>
\ No newline at end of file \ No newline at end of file
B 更新日志 B 更新日志
......
Imports FSLib.App.SimpleUpdater 'Imports FSLib.App.SimpleUpdater
Public NotInheritable Class frmAbout Public NotInheritable Class frmAbout
...@@ -26,9 +26,19 @@ Public NotInheritable Class frmAbout ...@@ -26,9 +26,19 @@ Public NotInheritable Class frmAbout
My.Application.Info.DirectoryPath & "\" & My.Application.Info.AssemblyName & ".dll" My.Application.Info.DirectoryPath & "\" & My.Application.Info.AssemblyName & ".dll"
'释放更新程序 '释放更新程序
NewUpdater.CreateUpdate() NewUpdater.CreateUpdateExe()
NewUpdater.UpDater2(btnCheckUpdate) '检查释放有新版本
Select Case NewUpdater.CheckNewVesion()
Case "New"
With btnCheckUpdate
.Text = "当前为最新版"
.Visible = False
End With
Case Else
btnCheckUpdate.Text = "检查到新版" & NewVersion
End Select
End Sub End Sub
......
...@@ -102,8 +102,8 @@ Partial Class frmAutoPartNumber ...@@ -102,8 +102,8 @@ Partial Class frmAutoPartNumber
' '
Me.lvwFile.AllowDrop = True Me.lvwFile.AllowDrop = True
Me.lvwFile.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _ Me.lvwFile.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
Or System.Windows.Forms.AnchorStyles.Left) _ Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.lvwFile.Columns.AddRange(New System.Windows.Forms.ColumnHeader() {Me.chOriginalFileName, Me.chType, Me.chNewFileName, Me.chFolder}) Me.lvwFile.Columns.AddRange(New System.Windows.Forms.ColumnHeader() {Me.chOriginalFileName, Me.chType, Me.chNewFileName, Me.chFolder})
Me.lvwFile.FullRowSelect = True Me.lvwFile.FullRowSelect = True
Me.lvwFile.Location = New System.Drawing.Point(13, 12) Me.lvwFile.Location = New System.Drawing.Point(13, 12)
......
...@@ -75,7 +75,8 @@ Public Class frmAutoPartNumber ...@@ -75,7 +75,8 @@ Public Class frmAutoPartNumber
999: 999:
Next Next
MsgBox("自动命名图号完成", MsgBoxStyle.Information + MsgBoxStyle.OkOnly, "自动命名图号") SetStatusBarText("自动命名图号完成!")
'MsgBox("自动命名图号完成", MsgBoxStyle.Information + MsgBoxStyle.OkOnly, "自动命名图号")
btnStart.Enabled = True btnStart.Enabled = True
Catch ex As Exception Catch ex As Exception
......
...@@ -4,10 +4,10 @@ Imports Inventor.SelectTypeEnum ...@@ -4,10 +4,10 @@ Imports Inventor.SelectTypeEnum
Imports Inventor.DocumentTypeEnum Imports Inventor.DocumentTypeEnum
Imports Inventor Imports Inventor
Imports Microsoft.Office.Interop Imports Microsoft.Office.Interop
Imports stdole
Public Class frmInventoryCoding Public Class frmInventoryCoding
Private Sub btnLoadFile_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnLoadFile.Click Private Sub btnLoadFile_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnLoadFile.Click
btnLoadFile.Enabled = False btnLoadFile.Enabled = False
......
...@@ -31,7 +31,7 @@ Partial Class frmQuitOpen ...@@ -31,7 +31,7 @@ Partial Class frmQuitOpen
'OK_Button 'OK_Button
' '
Me.OK_Button.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.OK_Button.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.OK_Button.Location = New System.Drawing.Point(520, 136) Me.OK_Button.Location = New System.Drawing.Point(667, 296)
Me.OK_Button.Name = "OK_Button" Me.OK_Button.Name = "OK_Button"
Me.OK_Button.Size = New System.Drawing.Size(75, 28) Me.OK_Button.Size = New System.Drawing.Size(75, 28)
Me.OK_Button.TabIndex = 2 Me.OK_Button.TabIndex = 2
...@@ -41,7 +41,7 @@ Partial Class frmQuitOpen ...@@ -41,7 +41,7 @@ Partial Class frmQuitOpen
' '
Me.Cancel_Button.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.Cancel_Button.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.Cancel_Button.DialogResult = System.Windows.Forms.DialogResult.Cancel Me.Cancel_Button.DialogResult = System.Windows.Forms.DialogResult.Cancel
Me.Cancel_Button.Location = New System.Drawing.Point(600, 136) Me.Cancel_Button.Location = New System.Drawing.Point(747, 296)
Me.Cancel_Button.Name = "Cancel_Button" Me.Cancel_Button.Name = "Cancel_Button"
Me.Cancel_Button.Size = New System.Drawing.Size(75, 28) Me.Cancel_Button.Size = New System.Drawing.Size(75, 28)
Me.Cancel_Button.TabIndex = 3 Me.Cancel_Button.TabIndex = 3
...@@ -50,7 +50,8 @@ Partial Class frmQuitOpen ...@@ -50,7 +50,8 @@ Partial Class frmQuitOpen
'lvwFileListView 'lvwFileListView
' '
Me.lvwFileListView.AllowColumnReorder = True Me.lvwFileListView.AllowColumnReorder = True
Me.lvwFileListView.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _ Me.lvwFileListView.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.lvwFileListView.AutoArrange = False Me.lvwFileListView.AutoArrange = False
Me.lvwFileListView.Columns.AddRange(New System.Windows.Forms.ColumnHeader() {Me.ColumnHeader1}) Me.lvwFileListView.Columns.AddRange(New System.Windows.Forms.ColumnHeader() {Me.ColumnHeader1})
...@@ -58,7 +59,7 @@ Partial Class frmQuitOpen ...@@ -58,7 +59,7 @@ Partial Class frmQuitOpen
Me.lvwFileListView.Location = New System.Drawing.Point(12, 12) Me.lvwFileListView.Location = New System.Drawing.Point(12, 12)
Me.lvwFileListView.MultiSelect = False Me.lvwFileListView.MultiSelect = False
Me.lvwFileListView.Name = "lvwFileListView" Me.lvwFileListView.Name = "lvwFileListView"
Me.lvwFileListView.Size = New System.Drawing.Size(663, 118) Me.lvwFileListView.Size = New System.Drawing.Size(810, 266)
Me.lvwFileListView.Sorting = System.Windows.Forms.SortOrder.Ascending Me.lvwFileListView.Sorting = System.Windows.Forms.SortOrder.Ascending
Me.lvwFileListView.TabIndex = 37 Me.lvwFileListView.TabIndex = 37
Me.lvwFileListView.UseCompatibleStateImageBehavior = False Me.lvwFileListView.UseCompatibleStateImageBehavior = False
...@@ -73,11 +74,10 @@ Partial Class frmQuitOpen ...@@ -73,11 +74,10 @@ Partial Class frmQuitOpen
' '
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 12.0!) Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 12.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(687, 176) Me.ClientSize = New System.Drawing.Size(834, 336)
Me.Controls.Add(Me.lvwFileListView) Me.Controls.Add(Me.lvwFileListView)
Me.Controls.Add(Me.OK_Button) Me.Controls.Add(Me.OK_Button)
Me.Controls.Add(Me.Cancel_Button) Me.Controls.Add(Me.Cancel_Button)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog
Me.MaximizeBox = False Me.MaximizeBox = False
Me.MinimizeBox = False Me.MinimizeBox = False
Me.Name = "frmQuitOpen" Me.Name = "frmQuitOpen"
......
...@@ -9,9 +9,18 @@ Public Class frmQuitOpen ...@@ -9,9 +9,18 @@ Public Class frmQuitOpen
Private Sub OK_Button_Click(sender As System.Object, e As System.EventArgs) Handles OK_Button.Click Private Sub OK_Button_Click(sender As System.Object, e As System.EventArgs) Handles OK_Button.Click
If lvwFileListView.SelectedItems.Count <> 0 Then If lvwFileListView.SelectedItems.Count <> 0 Then
ThisApplication.Documents.Open(lvwFileListView.SelectedItems(0).Text) 'ThisApplication.Documents.Open(lvwFileListView.SelectedItems(0).Text)
Process.Start(lvwFileListView.SelectedItems(0).Text)
End If End If
Me.DialogResult = System.Windows.Forms.DialogResult.OK Me.DialogResult = System.Windows.Forms.DialogResult.OK
me.close Me.Close()
End Sub
Private Sub lvwFileListView_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles lvwFileListView.SelectedIndexChanged
If lvwFileListView.SelectedItems.Count <> 0 Then
'ThisApplication.Documents.Open(lvwFileListView.SelectedItems(0).Text)
Process.Start(lvwFileListView.SelectedItems(0).Text)
End If
Me.Close()
End Sub End Sub
End Class End Class
Imports System.Windows.Forms Imports System.Windows.Forms
Imports FSLib.App.SimpleUpdater 'Imports FSLib.App.SimpleUpdater
Imports System.IO Imports System.IO
Public Class frmUpdate Public Class frmUpdate
......
...@@ -1351,37 +1351,66 @@ Module InventorBasic ...@@ -1351,37 +1351,66 @@ Module InventorBasic
partslistrow.Item(1).Value = 0 partslistrow.Item(1).Value = 0
End If End If
Next Next
'
' '点击每个序号组 '获取当前balloon的textstyle
' Dim oBalloon As Balloon Dim OldBalloonTextStyl As String = oDrawingDocument.StylesManager.ActiveStandardStyle.ActiveObjectDefaults.BalloonStyle.TextStyle.Name
' For i = 1 To oActiveSheet.PartsLists.Item(1).PartsListRows.Count
' oBalloon = ThisApplication.CommandManager.Pick(kDrawingBalloonFilter, "选择引出序号") '获取当前balloonstyle
' '遍历序号组中的序号,不为0就设置序号,并加1,设置下一个,有序号则跳过 Dim oActiveBalloonStyle As BalloonStyle = oDrawingDocument.StylesManager.ActiveStandardStyle.ActiveObjectDefaults.BalloonStyle
' For Each oBalloonValueSet As BalloonValueSet In oBalloon.BalloonValueSets
' If oBalloonValueSet.Value = 0 Then '新建 ZeroBalloonText
' oBalloonValueSet.Value = i Try
' i = i + 1 If oDrawingDocument.StylesManager.TextStyles.Item("ZeroBalloonText") Is Nothing Then
' End If
' Next End If
' '多加的1要减去 Catch ex As Exception
' i = i - 1 Dim oZeroBalloonText As TextStyle
' Next oZeroBalloonText = oDrawingDocument.StylesManager.TextStyles.Item(OldBalloonTextStyl).Copy("ZeroBalloonText")
Dim oZeroBalloonTextColor As Color = ThisApplication.TransientObjects.CreateColor(255, 0, 128)
oZeroBalloonText.Color = oZeroBalloonTextColor
End Try
'设置当前balloon style 为新的 zeroballoonstyle
oActiveBalloonStyle.TextStyle = oDrawingDocument.StylesManager.TextStyles.Item("ZeroBalloonText")
' '' ''
' '' '' '点击每个序号组
' '' '' Dim oBalloon As Balloon
' '' '' For i = 1 To oActiveSheet.PartsLists.Item(1).PartsListRows.Count
' '' '' oBalloon = ThisApplication.CommandManager.Pick(kDrawingBalloonFilter, "选择引出序号")
' '' '' '遍历序号组中的序号,不为0就设置序号,并加1,设置下一个,有序号则跳过
' '' '' For Each oBalloonValueSet As BalloonValueSet In oBalloon.BalloonValueSets
' '' '' If oBalloonValueSet.Value = 0 Then
' '' '' oBalloonValueSet.Value = i
' '' '' i = i + 1
' '' '' End If
' '' '' Next
' '' '' '多加的1要减去
' '' '' i = i - 1
' '' '' Next
'点击每个序号组 '点击每个序号组
Dim oBalloon As Balloon Try
Do Dim oBalloon As Balloon
oBalloon = ThisApplication.CommandManager.Pick(kDrawingBalloonFilter, "选择引出序号") Do
oBalloon = ThisApplication.CommandManager.Pick(kDrawingBalloonFilter, "选择引出序号")
For Each oBalloonValueSet As BalloonValueSet In oBalloon.BalloonValueSets
'If (oBalloonValueSet.Value >= FirstBalloonNumber) Then
If oBalloonValueSet.Value = 0 Then
oBalloonValueSet.Value = BalloonNumber
BalloonNumber = BalloonNumber + 1
End If
Next
Loop While True
Catch ex As Exception
For Each oBalloonValueSet As BalloonValueSet In oBalloon.BalloonValueSets 'esc 退出后,还原balloon style
'If (oBalloonValueSet.Value >= FirstBalloonNumber) Then oActiveBalloonStyle.TextStyle = oDrawingDocument.StylesManager.TextStyles.Item(OldBalloonTextStyl)
If oBalloonValueSet.Value = 0 Then
oBalloonValueSet.Value = BalloonNumber
BalloonNumber = BalloonNumber + 1
End If
Next
Loop While True
Return True Return True
End Try
End Function End Function
'检查序号完整性 '检查序号完整性
......
Imports FSLib.App.SimpleUpdater 'Imports FSLib.App.SimpleUpdater
Imports System.Windows.Forms Imports System.Windows.Forms
Module NewUpdater Module NewUpdater
...@@ -30,7 +30,7 @@ Module NewUpdater ...@@ -30,7 +30,7 @@ Module NewUpdater
' End Try ' End Try
'End Sub 'End Sub
Public Sub UpDater2(ByVal btnCheckUpDate As Button) Public Function CheckNewVesion() As String
Try Try
Dim NewVersionInfo As String = "\\Likai-pc\发行版\2011\NewVersion.txt" Dim NewVersionInfo As String = "\\Likai-pc\发行版\2011\NewVersion.txt"
...@@ -62,21 +62,22 @@ Module NewUpdater ...@@ -62,21 +62,22 @@ Module NewUpdater
'simupdate = My.Application.Info.DirectoryPath & "\simupdater.exe" 'simupdate = My.Application.Info.DirectoryPath & "\simupdater.exe"
'Process.Start(simupdate) 'Process.Start(simupdate)
btnCheckUpDate.Text = "检查到新版" & NewVersion 'btnCheckUpDate.Text = "检查到新版" & NewVersion
Return NewVersion
Else Else
With btnCheckUpDate
.Text = "当前为最新版"
.Visible = False
End With
Return "New"
End If End If
Else
Return "Null"
End If End If
Catch ex As Exception Catch ex As Exception
'MsgBox(ex.Message) 'MsgBox(ex.Message)
Return "Null"
End Try End Try
End Sub End Function
Public Function ShortVersion(ByVal LongVesion As String) As Long Public Function ShortVersion(ByVal LongVesion As String) As Long
...@@ -109,7 +110,7 @@ Module NewUpdater ...@@ -109,7 +110,7 @@ Module NewUpdater
End Try End Try
End Sub End Sub
Public Function CreateUpdate() As Boolean Public Function CreateUpdateExe() As Boolean
Try Try
Dim path As String = ThisApplication.InstallPath & "Bin\SimpleUpdater.exe" '文件释放路径 Dim path As String = ThisApplication.InstallPath & "Bin\SimpleUpdater.exe" '文件释放路径
......
B'设置为一个动作,可一次撤销 B'设置为一个动作,可一次撤销
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册