.net 任务管理器

时间:2012-12-30 18:46:29
【文件属性】:

文件名称:.net 任务管理器

文件大小:59KB

文件格式:RAR

更新时间:2012-12-30 18:46:29

net 任务管理器

.net 任Imports System Imports System.Windows.Forms Imports System.Collections Namespace ListViewItemComparer ' Implements the manual sorting of items by column. Public Class IComparer Private col As Int32 Private order As SortOrder Public Sub new() col = 0 order = SortOrder.Ascending End Sub Public Sub New(ByVal column As Int32, ByVal _order As SortOrder) col = column order = _order End Sub Public Function Compare(ByVal x As Object, ByVal y As Object) As Int32 Dim returnVal As Int32 ' Determine whether the type being compared is a date type. Try ' Parse the two objects passed as a parameter as a DateTime. Dim firstDate As Date = DateTime.Parse((x.SubItems(col).Text)) Dim secondDate As Date = DateTime.Parse((y.SubItems(col).Text)) 'Compare the two dates. returnVal = DateTime.Compare(firstDate, secondDate) ' If neither compared object has a valid date format, compare 'as a string. Catch ' ' Compare the two items as a string. returnVal = String.Compare((x).SubItems(col).Text, ((y.SubItems(col).Text))) End Try 'Determine whether the sort order is descending. If order = SortOrder.Descending Then ' Invert the value returned by String.Compare. returnVal *= -1 End If Return returnVal End Function End Class End Namespace 务管理器


【文件预览】:
任务管理器
----任务管理器.sln(934B)
----任务管理器.suo(22KB)
----任务管理器()
--------任务管理器.vbproj(4KB)
--------Form1.vb(4KB)
--------obj()
--------任务管理器.vbproj.user(168B)
--------Class1.vb(2KB)
--------My Project()
--------Form1.resx(6KB)
--------Form1.Designer.vb(6KB)

网友评论

  • 不错,借鉴了一下