Skip to content

Commit

Permalink
Fixed build errors and issue mikecel79#5 on 3.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
DariusHutchison committed Mar 17, 2022
1 parent b6810ab commit 4dec80e
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 25 deletions.
24 changes: 13 additions & 11 deletions 3.1.1/DISM GUI.sln
Original file line number Diff line number Diff line change
@@ -1,29 +1,31 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.1.32228.430
MinimumVisualStudioVersion = 10.0.40219.1
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "DISM GUI", "DISM GUI\DISM GUI.vbproj", "{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}"
EndProject
Global
GlobalSection(TeamFoundationVersionControl) = preSolution
SccNumberOfProjects = 2
SccEnterpriseProvider = {4CA58AB2-18FA-4F8D-95D4-32DDF27D184C}
SccTeamFoundationServer = http://us-mertfs02:8080/tfs/defaultcollection
SccLocalPath0 = .
SccProjectUniqueName1 = DISM\u0020GUI\\DISM\u0020GUI.vbproj
SccProjectName1 = DISM\u0020GUI
SccLocalPath1 = DISM\u0020GUI
EndGlobalSection
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Debug|x64.ActiveCfg = Debug|x64
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Debug|x64.Build.0 = Debug|x64
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Debug|x86.ActiveCfg = Debug|x86
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Debug|x86.Build.0 = Debug|x86
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Release|x64.ActiveCfg = Release|x64
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Release|x64.Build.0 = Release|x64
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Release|x86.ActiveCfg = Release|x86
{D3E5BCD3-DED9-48F3-B457-70F561E54A1A}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {9076E518-54FD-4A8E-A2FC-AF33A696D7DC}
EndGlobalSection
EndGlobal
8 changes: 8 additions & 0 deletions 3.1.1/DISM GUI/DISM GUI.vbproj
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,14 @@
<PropertyGroup>
<ApplicationManifest>My Project\app.manifest</ApplicationManifest>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
<PlatformTarget>x64</PlatformTarget>
<OutputPath>bin\x64\Debug\</OutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
<PlatformTarget>x64</PlatformTarget>
<OutputPath>bin\x64\Release\</OutputPath>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Data" />
Expand Down
28 changes: 14 additions & 14 deletions 3.1.1/DISM GUI/frmMain.vb
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ Public Class frmMain
strOutput = strOutput & vbCr & vbCr & DISM.StandardOutput.ReadToEnd()
DISM.WaitForExit()
'txtOutput.Text = output
strDISMExitCode = DISM.ExitCode
strDISMExitCode = DISM.ExitCode.ToString()
End Sub

Private Sub BackgroundWorkerMount_RunWorkerCompleted(ByVal sender As Object, ByVal e As System.ComponentModel.RunWorkerCompletedEventArgs) Handles BackgroundWorkerMount.RunWorkerCompleted
Expand Down Expand Up @@ -212,7 +212,7 @@ Public Class frmMain

strOutput = strOutput & vbCr & vbCr & DISM.StandardOutput.ReadToEnd()
DISM.WaitForExit()
strDISMExitCode = DISM.ExitCode
strDISMExitCode = DISM.ExitCode.ToString()
End Sub

Private Sub BackgroundWorkerDisMount_RunWorkerCompleted(ByVal sender As Object, ByVal e As System.ComponentModel.RunWorkerCompletedEventArgs) Handles BackgroundWorkerDisMount.RunWorkerCompleted
Expand All @@ -229,7 +229,7 @@ Public Class frmMain
End Sub

Private Sub btnOpnDriverFolder_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnOpnDriverFolder.Click
txtDriverLocation.Text = OpenFolder()
txtDriverLocation.Text = OpenFolder().ToString()
End Sub

Private Sub btnAddDriver_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnAddDriver.Click
Expand Down Expand Up @@ -267,7 +267,7 @@ Public Class frmMain
End Sub

Private Sub BackgroundWorkerDISMCommand_DoWork(ByVal sender As System.Object, ByVal e As System.ComponentModel.DoWorkEventArgs) Handles BackgroundWorkerDISMCommand.DoWork
Dim strInput As String = e.Argument
Dim strInput As String = e.Argument.ToString()
strDISMExitCode = ""
Dim DISM As New Process()
DISM.StartInfo.RedirectStandardOutput = True
Expand All @@ -280,7 +280,7 @@ Public Class frmMain
DISM.Start()
strOutput = strOutput & vbCr & vbCr & DISM.StandardOutput.ReadToEnd()
DISM.WaitForExit()
strDISMExitCode = DISM.ExitCode
strDISMExitCode = DISM.ExitCode.ToString()
End Sub

Private Sub BackgroundWorkerDISMCommand_RunWorkerCompleted(ByVal sender As Object, ByVal e As System.ComponentModel.RunWorkerCompletedEventArgs) Handles BackgroundWorkerDISMCommand.RunWorkerCompleted
Expand Down Expand Up @@ -315,16 +315,16 @@ Public Class frmMain
If WIMMounted = False Then
MessageBox.Show("No WIM is mounted. You must mount a WIM before running this command.")
Else
strDISMArguments = "/image:" & strMountedImageLocation & " /Get-Packages"
strDISMArguments = "/image:""" & strMountedImageLocation & """" & " /Get-Packages"
BackgroundWorkerDISMCommand.RunWorkerAsync(strDISMArguments)
frmProgress.ShowDialog()
txtOutput.Text = strOutput
End If
End Sub


Private Sub btnOpenPackageFile_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnOpenPackageFile.Click
txtPackageFile.Text = OpenFolder()
txtPackageFile.Text = OpenFolder().ToString()
End Sub

Private Sub btnAddPackages_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAddPackages.Click
Expand All @@ -349,7 +349,7 @@ Public Class frmMain
txtOutput.Text = strOutput
End Sub

Private Function OpenFolder()
Private Function OpenFolder() As Object
dlgOpenFolder.ShowNewFolderButton = False
dlgOpenFolder.RootFolder = Environment.SpecialFolder.MyComputer
Dim DidWork As Integer = dlgOpenFolder.ShowDialog
Expand All @@ -362,8 +362,8 @@ Public Class frmMain
End If
End Function



Private Sub btnGetAllDriverInfo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnGetAllDriverInfo.Click
If WIMMounted = False Then
MessageBox.Show("No WIM is mounted. You must mount a WIM before running this command.")
Expand All @@ -385,7 +385,7 @@ Public Class frmMain
MessageBox.Show("You must enter in a driver name before continuing. The Driver name must end with inf")
Else
strDelDriverLocation = txtDelDriverLocation.Text
strDISMArguments = "/image:""" & strMountedImageLocation & """" & " /Remove-Driver /driver:" & strDelDriverLocation
strDISMArguments = "/image:""" & strMountedImageLocation & """" & " /Remove-Driver /driver:""" & strDelDriverLocation & """"
BackgroundWorkerDISMCommand.RunWorkerAsync(strDISMArguments)
frmProgress.ShowDialog()
txtOutput.Text = strOutput
Expand Down Expand Up @@ -419,7 +419,7 @@ Public Class frmMain
MessageBox.Show("You must enter in a package path before continuing. The package path must point to a valid cab file.")
Else
strPackagePath = txtPackagePath.Text
strDISMArguments = "/image:""" & strMountedImageLocation & """" & " /Remove-Package /PackagePath:" & strPackagePath
strDISMArguments = "/image:""" & strMountedImageLocation & """" & " /Remove-Package /PackagePath:""" & strPackagePath & """"
BackgroundWorkerDISMCommand.RunWorkerAsync(strDISMArguments)
frmProgress.ShowDialog()
txtOutput.Text = strOutput
Expand All @@ -432,7 +432,7 @@ Public Class frmMain
If WIMMounted = False Then
MessageBox.Show("No WIM is mounted. You must mount a WIM before running this command.")
Else
strDISMArguments = "/image:" & strMountedImageLocation & " /Get-Features"
strDISMArguments = "/image:""" & strMountedImageLocation & """" & " /Get-Features"
BackgroundWorkerDISMCommand.RunWorkerAsync(strDISMArguments)
frmProgress.ShowDialog()
txtOutput.Text = strOutput
Expand Down

0 comments on commit 4dec80e

Please sign in to comment.