From 74c9a3d36fcdbc3a3dd55c9759011399458cfc5c Mon Sep 17 00:00:00 2001 From: Syndamia Date: Fri, 19 Feb 2021 21:13:49 +0200 Subject: Renamed "Visual Basic Projects" folder to "VB.Net Projects" --- Visual Basic Projects/MaxMin/MaxMin.sln | 25 --- .../MaxMin/MaxMin/ApplicationEvents.vb | 22 --- .../MaxMin/MaxMin/Form1.Designer.vb | 177 --------------------- Visual Basic Projects/MaxMin/MaxMin/Form1.resx | 60 ------- Visual Basic Projects/MaxMin/MaxMin/Form1.vb | 59 ------- Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj | 33 ---- .../MaxMin/MaxMin/MaxMin.vbproj.user | 8 - .../My Project/Application.Designer.HighDpi.vb | 69 -------- .../MaxMin/My Project/Application.Designer.vb | 38 ----- .../MaxMin/MaxMin/My Project/Application.myapp | 10 -- 10 files changed, 501 deletions(-) delete mode 100644 Visual Basic Projects/MaxMin/MaxMin.sln delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/ApplicationEvents.vb delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/Form1.Designer.vb delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/Form1.resx delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/Form1.vb delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj.user delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.HighDpi.vb delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.vb delete mode 100644 Visual Basic Projects/MaxMin/MaxMin/My Project/Application.myapp (limited to 'Visual Basic Projects/MaxMin') diff --git a/Visual Basic Projects/MaxMin/MaxMin.sln b/Visual Basic Projects/MaxMin/MaxMin.sln deleted file mode 100644 index ea19ec3..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin.sln +++ /dev/null @@ -1,25 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.31005.135 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "MaxMin", "MaxMin\MaxMin.vbproj", "{1570AFEB-28D9-4713-BDC7-02ABEB6A1D30}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {1570AFEB-28D9-4713-BDC7-02ABEB6A1D30}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {1570AFEB-28D9-4713-BDC7-02ABEB6A1D30}.Debug|Any CPU.Build.0 = Debug|Any CPU - {1570AFEB-28D9-4713-BDC7-02ABEB6A1D30}.Release|Any CPU.ActiveCfg = Release|Any CPU - {1570AFEB-28D9-4713-BDC7-02ABEB6A1D30}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {08ABFB58-FFEA-4FC3-9C39-1023385CA647} - EndGlobalSection -EndGlobal diff --git a/Visual Basic Projects/MaxMin/MaxMin/ApplicationEvents.vb b/Visual Basic Projects/MaxMin/MaxMin/ApplicationEvents.vb deleted file mode 100644 index b892537..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/ApplicationEvents.vb +++ /dev/null @@ -1,22 +0,0 @@ -Imports Microsoft.VisualBasic.ApplicationServices - -Namespace My - ' The following events are available for MyApplication: - ' Startup: Raised when the application starts, before the startup form is created. - ' Shutdown: Raised after all application forms are closed. This event is not raised if the application terminates abnormally. - ' UnhandledException: Raised if the application encounters an unhandled exception. - ' StartupNextInstance: Raised when launching a single-instance application and the application is already active. - ' NetworkAvailabilityChanged: Raised when the network connection is connected or disconnected. - - ' **NEW** ApplyHighDpiMode: Raised when the application queries the HighDpiMode to set it for the application. - - ' Example: - - ' Private Sub MyApplication_ApplyHighDpiMode(sender As Object, e As ApplyHighDpiModeEventArgs) Handles Me.ApplyHighDpiMode - ' e.HighDpiMode = HighDpiMode.PerMonitorV2 - ' End Sub - - Partial Friend Class MyApplication - - End Class -End Namespace diff --git a/Visual Basic Projects/MaxMin/MaxMin/Form1.Designer.vb b/Visual Basic Projects/MaxMin/MaxMin/Form1.Designer.vb deleted file mode 100644 index e7c4ed3..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/Form1.Designer.vb +++ /dev/null @@ -1,177 +0,0 @@ - _ -Partial Class Form1 - Inherits System.Windows.Forms.Form - - 'Form overrides dispose to clean up the component list. - _ - Protected Overrides Sub Dispose(ByVal disposing As Boolean) - Try - If disposing AndAlso components IsNot Nothing Then - components.Dispose() - End If - Finally - MyBase.Dispose(disposing) - End Try - End Sub - - 'Required by the Windows Form Designer - Private components As System.ComponentModel.IContainer - - 'NOTE: The following procedure is required by the Windows Form Designer - 'It can be modified using the Windows Form Designer. - 'Do not modify it using the code editor. - - Private Sub InitializeComponent() - Me.Label1 = New System.Windows.Forms.Label() - Me.lblNumbers = New System.Windows.Forms.Label() - Me.Label3 = New System.Windows.Forms.Label() - Me.Label4 = New System.Windows.Forms.Label() - Me.Label5 = New System.Windows.Forms.Label() - Me.lblMin = New System.Windows.Forms.Label() - Me.lblMax = New System.Windows.Forms.Label() - Me.txtMin = New System.Windows.Forms.TextBox() - Me.txtMax = New System.Windows.Forms.TextBox() - Me.btnNew = New System.Windows.Forms.Button() - Me.btnCheck = New System.Windows.Forms.Button() - Me.SuspendLayout() - ' - 'Label1 - ' - Me.Label1.AutoSize = True - Me.Label1.Location = New System.Drawing.Point(11, 20) - Me.Label1.Name = "Label1" - Me.Label1.Size = New System.Drawing.Size(112, 15) - Me.Label1.TabIndex = 0 - Me.Label1.Text = "За следните числа:" - ' - 'lblNumbers - ' - Me.lblNumbers.AutoSize = True - Me.lblNumbers.ForeColor = System.Drawing.Color.Red - Me.lblNumbers.Location = New System.Drawing.Point(12, 54) - Me.lblNumbers.Name = "lblNumbers" - Me.lblNumbers.Size = New System.Drawing.Size(27, 15) - Me.lblNumbers.TabIndex = 1 - Me.lblNumbers.Text = "ERR" - ' - 'Label3 - ' - Me.Label3.AutoSize = True - Me.Label3.Location = New System.Drawing.Point(12, 82) - Me.Label3.Name = "Label3" - Me.Label3.Size = New System.Drawing.Size(70, 15) - Me.Label3.TabIndex = 2 - Me.Label3.Text = "определете" - ' - 'Label4 - ' - Me.Label4.AutoSize = True - Me.Label4.ForeColor = System.Drawing.Color.Navy - Me.Label4.Location = New System.Drawing.Point(11, 119) - Me.Label4.Name = "Label4" - Me.Label4.Size = New System.Drawing.Size(79, 15) - Me.Label4.TabIndex = 3 - Me.Label4.Text = "най-малкото" - ' - 'Label5 - ' - Me.Label5.AutoSize = True - Me.Label5.ForeColor = System.Drawing.Color.Navy - Me.Label5.Location = New System.Drawing.Point(11, 153) - Me.Label5.Name = "Label5" - Me.Label5.Size = New System.Drawing.Size(85, 15) - Me.Label5.TabIndex = 4 - Me.Label5.Text = "най-голямото" - ' - 'lblMin - ' - Me.lblMin.AutoSize = True - Me.lblMin.ForeColor = System.Drawing.Color.Red - Me.lblMin.Location = New System.Drawing.Point(203, 122) - Me.lblMin.Name = "lblMin" - Me.lblMin.Size = New System.Drawing.Size(27, 15) - Me.lblMin.TabIndex = 5 - Me.lblMin.Text = "ERR" - ' - 'lblMax - ' - Me.lblMax.AutoSize = True - Me.lblMax.ForeColor = System.Drawing.Color.Red - Me.lblMax.Location = New System.Drawing.Point(203, 153) - Me.lblMax.Name = "lblMax" - Me.lblMax.Size = New System.Drawing.Size(27, 15) - Me.lblMax.TabIndex = 6 - Me.lblMax.Text = "ERR" - ' - 'txtMin - ' - Me.txtMin.Location = New System.Drawing.Point(111, 119) - Me.txtMin.Name = "txtMin" - Me.txtMin.Size = New System.Drawing.Size(86, 23) - Me.txtMin.TabIndex = 7 - ' - 'txtMax - ' - Me.txtMax.Location = New System.Drawing.Point(111, 150) - Me.txtMax.Name = "txtMax" - Me.txtMax.Size = New System.Drawing.Size(86, 23) - Me.txtMax.TabIndex = 8 - ' - 'btnNew - ' - Me.btnNew.Enabled = False - Me.btnNew.ForeColor = System.Drawing.Color.Black - Me.btnNew.Location = New System.Drawing.Point(12, 196) - Me.btnNew.Name = "btnNew" - Me.btnNew.Size = New System.Drawing.Size(112, 58) - Me.btnNew.TabIndex = 9 - Me.btnNew.Text = "Нови числа" - Me.btnNew.UseVisualStyleBackColor = True - ' - 'btnCheck - ' - Me.btnCheck.Enabled = False - Me.btnCheck.Location = New System.Drawing.Point(143, 196) - Me.btnCheck.Name = "btnCheck" - Me.btnCheck.Size = New System.Drawing.Size(111, 58) - Me.btnCheck.TabIndex = 10 - Me.btnCheck.Text = "Провери" - Me.btnCheck.UseVisualStyleBackColor = True - ' - 'Form1 - ' - Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 15.0!) - Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(266, 266) - Me.Controls.Add(Me.btnCheck) - Me.Controls.Add(Me.btnNew) - Me.Controls.Add(Me.txtMax) - Me.Controls.Add(Me.txtMin) - Me.Controls.Add(Me.lblMax) - Me.Controls.Add(Me.lblMin) - Me.Controls.Add(Me.Label5) - Me.Controls.Add(Me.Label4) - Me.Controls.Add(Me.Label3) - Me.Controls.Add(Me.lblNumbers) - Me.Controls.Add(Me.Label1) - Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog - Me.MaximizeBox = False - Me.Name = "Form1" - Me.Text = "Кой е най...?" - Me.ResumeLayout(False) - Me.PerformLayout() - - End Sub - - Friend WithEvents Label1 As Label - Friend WithEvents lblNumbers As Label - Friend WithEvents Label3 As Label - Friend WithEvents Label4 As Label - Friend WithEvents Label5 As Label - Friend WithEvents lblMin As Label - Friend WithEvents lblMax As Label - Friend WithEvents txtMin As TextBox - Friend WithEvents txtMax As TextBox - Friend WithEvents btnNew As Button - Friend WithEvents btnCheck As Button -End Class diff --git a/Visual Basic Projects/MaxMin/MaxMin/Form1.resx b/Visual Basic Projects/MaxMin/MaxMin/Form1.resx deleted file mode 100644 index b5ae26c..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/Form1.resx +++ /dev/null @@ -1,60 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/Visual Basic Projects/MaxMin/MaxMin/Form1.vb b/Visual Basic Projects/MaxMin/MaxMin/Form1.vb deleted file mode 100644 index 7c054c4..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/Form1.vb +++ /dev/null @@ -1,59 +0,0 @@ -Public Class Form1 - Const numberCount = 10, minimumPossible = 1, maxiumPossible = 100 - - Dim numbers(numberCount) As Integer - Dim rng As Random = New Random - - Private Sub btnNew_Click(sender As Object, e As EventArgs) Handles btnNew.Click, MyBase.Load - ClearAnswer() - - RefreshNumbers() - lblNumbers.Text = String.Join(" ", numbers) - End Sub - - Private Sub btnCheck_Click(sender As Object, e As EventArgs) Handles btnCheck.Click - UpdateCorrectness(lblMin, txtMin.Text.Trim() = numbers.Min()) ' Somehow it handles this comparison - UpdateCorrectness(lblMax, txtMax.Text.Trim() = numbers.Max()) ' Somehow it handles this comparison - - btnNew.Enabled = True - btnCheck.Enabled = False - txtMax.Enabled = False - txtMin.Enabled = False - - lblNumbers.Text = String.Join(" ", numbers.OrderBy(Function(x) x)) - End Sub - - Private Sub txtMinOrtxtMax_TextChanged(sender As Object, e As EventArgs) Handles txtMin.TextChanged, txtMax.TextChanged - ' If both text inputs aren't empty, enable the "Check" button - btnCheck.Enabled = Not String.IsNullOrEmpty(txtMin.Text) And Not String.IsNullOrEmpty(txtMax.Text) - End Sub - - Private Sub RefreshNumbers() - For index = 0 To numberCount Step 1 - numbers(index) = rng.Next(minimumPossible, maxiumPossible + 1) ' Exclusive upper bound - index -= numbers.Count(Function(x) x = numbers(index)) - 1 ' numbers.Count(...) is always between 1 and 2 - Next - End Sub - - Private Sub ClearAnswer() - lblMin.Text = String.Empty - txtMin.Text = String.Empty - txtMin.Enabled = True - - lblMax.Text = String.Empty - txtMax.Text = String.Empty - txtMax.Enabled = True - - btnNew.Enabled = False - End Sub - - Private Sub UpdateCorrectness(control As Control, isCorrect As Boolean) - If isCorrect Then - control.Text = "OK" - control.ForeColor = Color.Green - Else - control.Text = "X" - control.ForeColor = Color.Red - End If - End Sub -End Class \ No newline at end of file diff --git a/Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj b/Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj deleted file mode 100644 index 2b0e1ca..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj +++ /dev/null @@ -1,33 +0,0 @@ - - - - WinExe - net5.0-windows - MaxMin - Sub Main - true - WindowsForms - - - - - - - - - - - True - True - Application.myapp - - - - - - MyApplicationCodeGenerator - Application.Designer.vb - - - - \ No newline at end of file diff --git a/Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj.user b/Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj.user deleted file mode 100644 index c392cf0..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/MaxMin.vbproj.user +++ /dev/null @@ -1,8 +0,0 @@ - - - - - Form - - - diff --git a/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.HighDpi.vb b/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.HighDpi.vb deleted file mode 100644 index a3576c4..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.HighDpi.vb +++ /dev/null @@ -1,69 +0,0 @@ -Option Strict On -Option Explicit On - -'This constant indicates whether the Application Framework is in use. -#Const APPLICATION_FRAMEWORK = True - -#If APPLICATION_FRAMEWORK Then - -#If NET5_0 And Not NET6_0 Then - -Imports System.Collections.ObjectModel - -Namespace My - - Partial Friend Class MyApplication - - Public Event ApplyHighDpiMode(sender As Object, e As ApplyHighDpiModeEventArgs) - - Private _highDpiMode As HighDpiMode? - - Friend Shadows Property HighDpiMode As HighDpiMode - Get - Return If( - _highDpiMode Is Nothing, - Application.HighDpiMode, - _highDpiMode.Value) - End Get - Set(value As HighDpiMode) - _highDpiMode = value - End Set - End Property - - ' IMPORTANT: - ' If this method causes an compilation error after you've unchecked 'Application Framework' - ' in the project properties, go to the top of this file and change the value to 'False' in this line: - ' #Const APPLICATION_FRAMEWORK = False - - ' For more about using WinForms without the Application Framework - ' see: https://aka.ms/visualbasic-appframework-net5 - Protected Overrides Function OnInitialize(commandLineArgs As ReadOnlyCollection(Of String)) As Boolean - Dim eventArgs = New ApplyHighDpiModeEventArgs( - If( - _highDpiMode Is Nothing, - HighDpiMode.SystemAware, - _highDpiMode.Value)) - - RaiseEvent ApplyHighDpiMode(Me, eventArgs) - - Windows.Forms.Application.SetHighDpiMode(eventArgs.HighDpiMode) - - Return MyBase.OnInitialize(commandLineArgs) - End Function - End Class - - Public Class ApplyHighDpiModeEventArgs - Inherits EventArgs - - Public Sub New(highDpiMode As HighDpiMode) - Me.HighDpiMode = highDpiMode - End Sub - - Public Property HighDpiMode As HighDpiMode - - End Class - -End Namespace - -#End If ' #If NET5_0 And Not NET6_0 -#End If ' #If APPLICATION_FRAMEWORK diff --git a/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.vb b/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.vb deleted file mode 100644 index 8b8d4fc..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.Designer.vb +++ /dev/null @@ -1,38 +0,0 @@ -'------------------------------------------------------------------------------ -' -' This code was generated by a tool. -' Runtime Version:4.0.30319.42000 -' -' Changes to this file may cause incorrect behavior and will be lost if -' the code is regenerated. -' -'------------------------------------------------------------------------------ - -Option Strict On -Option Explicit On - - -Namespace My - - 'NOTE: This file is auto-generated; do not modify it directly. To make changes, - ' or if you encounter build errors in this file, go to the Project Designer - ' (go to Project Properties or double-click the My Project node in - ' Solution Explorer), and make changes on the Application tab. - ' - Partial Friend Class MyApplication - - - Public Sub New() - MyBase.New(Global.Microsoft.VisualBasic.ApplicationServices.AuthenticationMode.Windows) - Me.IsSingleInstance = False - Me.EnableVisualStyles = True - Me.SaveMySettingsOnExit = True - Me.ShutDownStyle = Global.Microsoft.VisualBasic.ApplicationServices.ShutdownMode.AfterMainFormCloses - End Sub - - - Protected Overrides Sub OnCreateMainForm() - Me.MainForm = Form1 - End Sub - End Class -End Namespace diff --git a/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.myapp b/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.myapp deleted file mode 100644 index fbb5858..0000000 --- a/Visual Basic Projects/MaxMin/MaxMin/My Project/Application.myapp +++ /dev/null @@ -1,10 +0,0 @@ - - - true - Form1 - false - 0 - true - 0 - true - \ No newline at end of file -- cgit v1.2.3