VERSION 5.00 Begin VB.Form frm4 BorderStyle = 4 'Fixed ToolWindow ClientHeight = 3585 ClientLeft = 45 ClientTop = 315 ClientWidth = 8070 BeginProperty Font Name = "Tahoma" Size = 8.25 Charset = 178 Weight = 400 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty LinkTopic = "Form1" MaxButton = 0 'False MinButton = 0 'False ScaleHeight = 3585 ScaleWidth = 8070 ShowInTaskbar = 0 'False StartUpPosition = 3 'Windows Default Begin VB.Label Label10 BorderStyle = 1 'Fixed Single BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 2280 TabIndex = 9 Tag = "4048" Top = 2640 Width = 5295 End Begin VB.Label Label9 Caption = "حافظه رم:" BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 600 TabIndex = 8 Top = 2640 Width = 1695 End Begin VB.Label Label8 BorderStyle = 1 'Fixed Single BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 2280 TabIndex = 7 Tag = "133" Top = 2040 Width = 5295 End Begin VB.Label Label7 Caption = "فركانس كاري:" BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 600 TabIndex = 6 Top = 2160 Width = 1695 End Begin VB.Label Label6 BorderStyle = 1 'Fixed Single BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 2280 TabIndex = 5 Top = 960 Width = 5295 End Begin VB.Label Label5 Caption = "نوع پردازنده:" BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 600 TabIndex = 4 Top = 1080 Width = 1695 End Begin VB.Label Label4 BorderStyle = 1 'Fixed Single BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 2280 TabIndex = 3 Top = 1560 Width = 5295 End Begin VB.Label Label3 Caption = "تعداد هسته:" BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 600 TabIndex = 2 Top = 1560 Width = 1695 End Begin VB.Label Label2 BorderStyle = 1 'Fixed Single BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 2280 TabIndex = 1 Top = 480 Width = 5295 End Begin VB.Label Label1 Caption = "سيستم عامل:" BeginProperty Font Name = "Tahoma" Size = 12 Charset = 178 Weight = 700 Underline = 0 'False Italic = 0 'False Strikethrough = 0 'False EndProperty Height = 375 Left = 600 TabIndex = 0 Top = 480 Width = 1695 End End Attribute VB_Name = "frm4" Attribute VB_GlobalNameSpace = False Attribute VB_Creatable = False Attribute VB_PredeclaredId = True Attribute VB_Exposed = False Dim check, nowcputype, cputype, nowspeed, cpuspeed, pcram, nowram As Integer Private Sub Command1_Click() End Sub Private Sub Form_Load() check = Label2.Tag cputype = Val(Label4.Tag) cpuspeed = Val(Label8.Tag) pcram = Val(Label10.Tag) Open "c:\system.bat" For Output As #255 Print #255, "systeminfo /fo list >c:\SYSTEM.TXT" Print #255, "del system.bat" Close Shell "c:\system.bat" Open "c:\system.txt" For Input As #255 Do While Not EOF(255) Line Input #255, X If (X Like "OS Name:*") Then Label2.Caption = Mid(X, 27) End If If (X Like "Total Physical Memory:*") Then s = Mid(X, 28) s = Replace(s, "MB", "") Label10.Caption = s & "مگابايت" End If If (X Like "Processor(s):*") Then Label4.Caption = Mid(X, 28, 1) & "هسته" End If If (X Like "*Mhz*") Then Y = InStr(1, X, "Mhz") c = Mid(X, Y - 5, 4) c = Replace(c, "~", "") Label8.Caption = c & "MHZ" End If If (X Like "*AMD*") Then Label6.Caption = "AMD پردازنده " nowcputype = 2 End If If (X Like "*INTEL*") Then Label6.Caption = "Intel پردازنده " nowcputype = 1 End If Loop Close If check = True Then If cputype = nowcputype Then Label6.ForeColor = vbGreen Else Label6.ForeColor = vbRed End If End If If check = True Then nowspeed = Val(c) If cpuspeed <= nowspeed Then Label8.ForeColor = vbGreen Else Label8.ForeColor = vbRed End If End If If check = True Then If pcram <= nowram Then Label10.ForeColor = vbGreen Else Label10.ForeColor = vbRed End If End If End Sub