mirror of
https://github.com/Orbmu2k/nvidiaProfileInspector.git
synced 2026-01-21 13:18:16 -05:00
Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
73dbbbd66c | ||
|
|
64f626e8a0 | ||
|
|
f62aa86ccc | ||
|
|
345444619c | ||
|
|
50006f114a | ||
|
|
a3b524e7d9 | ||
|
|
109fdd066a |
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Drawing;
|
||||
using System.IO;
|
||||
using System.Text.RegularExpressions;
|
||||
using System.Windows.Forms;
|
||||
|
||||
@@ -9,13 +10,14 @@ namespace nspector.Common.Helper
|
||||
internal class InputBox
|
||||
{
|
||||
|
||||
internal static DialogResult Show(string title, string promptText, ref string value, List<string> invalidInputs, string mandatoryFormatRegExPattern, int maxLength)
|
||||
internal static DialogResult Show(string title, string promptText, ref string value, List<string> invalidInputs, string mandatoryFormatRegExPattern, int maxLength, bool allowExeBrowse = false)
|
||||
{
|
||||
var form = new Form();
|
||||
var label = new Label();
|
||||
var textBox = new TextBox();
|
||||
var buttonOk = new Button();
|
||||
var buttonCancel = new Button();
|
||||
var buttonBrowse = new Button();
|
||||
var imageBox = new PictureBox();
|
||||
|
||||
EventHandler textchanged = delegate (object sender, EventArgs e)
|
||||
@@ -43,10 +45,23 @@ namespace nspector.Common.Helper
|
||||
buttonOk.Enabled = true;
|
||||
};
|
||||
|
||||
EventHandler buttonBrowse_Click = delegate (object sender, EventArgs e)
|
||||
{
|
||||
var openDialog = new OpenFileDialog();
|
||||
openDialog.DefaultExt = "*.exe";
|
||||
openDialog.Filter = "Application EXE Name|*.exe|Application Absolute Path|*.exe";
|
||||
|
||||
if (openDialog.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
string applicationName = new FileInfo(openDialog.FileName).Name;
|
||||
if (openDialog.FilterIndex == 2)
|
||||
applicationName = openDialog.FileName;
|
||||
textBox.Text = applicationName;
|
||||
}
|
||||
};
|
||||
|
||||
textBox.TextChanged += textchanged;
|
||||
|
||||
|
||||
form.Text = title;
|
||||
label.Text = promptText;
|
||||
textBox.Text = value;
|
||||
@@ -55,28 +70,47 @@ namespace nspector.Common.Helper
|
||||
|
||||
buttonOk.Text = "OK";
|
||||
buttonCancel.Text = "Cancel";
|
||||
buttonBrowse.Text = "Browse...";
|
||||
buttonOk.DialogResult = DialogResult.OK;
|
||||
buttonCancel.DialogResult = DialogResult.Cancel;
|
||||
|
||||
buttonOk.Enabled = false;
|
||||
|
||||
label.SetBounds(Dpi(9), Dpi(20), Dpi(372), Dpi(13));
|
||||
textBox.SetBounds(Dpi(12), Dpi(36), Dpi(352), Dpi(20));
|
||||
buttonOk.SetBounds(Dpi(228), Dpi(72), Dpi(75), Dpi(23));
|
||||
buttonCancel.SetBounds(Dpi(309), Dpi(72), Dpi(75), Dpi(23));
|
||||
textBox.SetBounds(Dpi(12), Dpi(44), Dpi(352), Dpi(20));
|
||||
buttonOk.SetBounds(Dpi(224), Dpi(72), Dpi(75), Dpi(23));
|
||||
buttonCancel.SetBounds(Dpi(305), Dpi(72), Dpi(75), Dpi(23));
|
||||
|
||||
imageBox.SetBounds(Dpi(368), Dpi(36), Dpi(16), Dpi(16));
|
||||
if (allowExeBrowse)
|
||||
{
|
||||
textBox.SetBounds(Dpi(12), Dpi(44), Dpi(286), Dpi(20));
|
||||
buttonBrowse.SetBounds(Dpi(305), Dpi(39), Dpi(75), Dpi(23));
|
||||
buttonBrowse.Click += buttonBrowse_Click;
|
||||
}
|
||||
|
||||
imageBox.SetBounds(Dpi(368), Dpi(44), Dpi(16), Dpi(16));
|
||||
|
||||
label.AutoSize = true;
|
||||
label.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
||||
imageBox.Anchor = AnchorStyles.Top | AnchorStyles.Right;
|
||||
textBox.Anchor = textBox.Anchor | AnchorStyles.Right;
|
||||
textBox.Anchor = AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right;
|
||||
buttonOk.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
|
||||
buttonCancel.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
|
||||
buttonBrowse.Anchor = AnchorStyles.Bottom | AnchorStyles.Right;
|
||||
|
||||
form.ClientSize = new Size(Dpi(396), Dpi(107));
|
||||
form.ClientSize = new Size(Math.Max(Dpi(300), label.Right + Dpi(10)), form.ClientSize.Height);
|
||||
form.Controls.AddRange(new Control[] { label, textBox, imageBox, buttonOk, buttonCancel });
|
||||
form.FormBorderStyle = FormBorderStyle.FixedDialog;
|
||||
form.MinimumSize = form.Size;
|
||||
form.MaximumSize = new Size(form.MinimumSize.Width * 2, form.MinimumSize.Height);
|
||||
|
||||
form.Controls.AddRange(new Control[] { label, textBox, buttonOk, buttonCancel });
|
||||
if (!allowExeBrowse)
|
||||
form.Controls.Add(imageBox);
|
||||
else
|
||||
form.Controls.Add(buttonBrowse);
|
||||
|
||||
form.ShowIcon = false;
|
||||
form.FormBorderStyle = FormBorderStyle.Sizable;
|
||||
form.StartPosition = FormStartPosition.CenterParent;
|
||||
form.MinimizeBox = false;
|
||||
form.MaximizeBox = false;
|
||||
|
||||
@@ -223,6 +223,43 @@
|
||||
</SettingValues>
|
||||
<SettingMasks/>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>DLSS-FG - Flags (0x104596A1)</UserfriendlyName>
|
||||
<HexSettingID>0x104596A1</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<DataType>DWORD</DataType>
|
||||
<!-- DLSSG checks for these three values and adjusts something based on them, but not sure what effect is -->
|
||||
<SettingValues>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>0</UserfriendlyName>
|
||||
<HexValue>0x00000000</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>1</UserfriendlyName>
|
||||
<HexValue>0x00000001</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>2</UserfriendlyName>
|
||||
<HexValue>0x00000002</HexValue>
|
||||
</CustomSettingValue>
|
||||
</SettingValues>
|
||||
<SettingMasks/>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>DLSS-FG - Flags (0x104596A2)</UserfriendlyName>
|
||||
<HexSettingID>0x104596A2</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<DataType>DWORD</DataType>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>DLSS-FG - Flags (0x104596A3)</UserfriendlyName>
|
||||
<HexSettingID>0x104596A3</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<DataType>DWORD</DataType>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>DLSS - Forced Quality Level</UserfriendlyName>
|
||||
<HexSettingID>0x10AFB768</HexSettingID>
|
||||
@@ -594,6 +631,40 @@
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<SettingMasks />
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>DLSS - Override Performance to be Ultra Performance</UserfriendlyName>
|
||||
<HexSettingID>0x10AFB76C</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<SettingValues>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>Off</UserfriendlyName>
|
||||
<HexValue>0x00000000</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>On</UserfriendlyName>
|
||||
<HexValue>0x00000001</HexValue>
|
||||
</CustomSettingValue>
|
||||
</SettingValues>
|
||||
<SettingMasks/>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>DLSS - Override DLSS modes to be DLAA</UserfriendlyName>
|
||||
<HexSettingID>0x10E41DF4</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<SettingValues>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>Off</UserfriendlyName>
|
||||
<HexValue>0x00000000</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>On</UserfriendlyName>
|
||||
<HexValue>0x00000001</HexValue>
|
||||
</CustomSettingValue>
|
||||
</SettingValues>
|
||||
<SettingMasks/>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Frame Rate Limiter - Background Application</UserfriendlyName>
|
||||
<HexSettingID>0x10835005</HexSettingID>
|
||||
@@ -831,7 +902,7 @@
|
||||
</CustomSetting>
|
||||
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Shadercache - Cachesize</UserfriendlyName>
|
||||
<UserfriendlyName>Shader Cache - Cache Size</UserfriendlyName>
|
||||
<HexSettingID>0x00AC8497</HexSettingID>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
<SettingValues>
|
||||
@@ -863,6 +934,10 @@
|
||||
<UserfriendlyName>5GB</UserfriendlyName>
|
||||
<HexValue>0x00001400</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>8GB</UserfriendlyName>
|
||||
<HexValue>0x00002000</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>10GB</UserfriendlyName>
|
||||
<HexValue>0x00002800</HexValue>
|
||||
@@ -879,8 +954,8 @@
|
||||
</CustomSetting>
|
||||
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>rBAR - Feature</UserfriendlyName>
|
||||
<HexSettingID>0X000F00BA</HexSettingID>
|
||||
<UserfriendlyName>rBAR - Enable</UserfriendlyName>
|
||||
<HexSettingID>0x000F00BA</HexSettingID>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
<SettingValues>
|
||||
<CustomSettingValue>
|
||||
@@ -893,23 +968,40 @@
|
||||
</CustomSettingValue>
|
||||
</SettingValues>
|
||||
</CustomSetting>
|
||||
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>rBAR - Options</UserfriendlyName>
|
||||
<HexSettingID>0X000F00BB</HexSettingID>
|
||||
<HexSettingID>0x000F00BB</HexSettingID>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
<DataType>DWORD</DataType>
|
||||
</CustomSetting>
|
||||
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>rBAR - Intel CPU Exclusion</UserfriendlyName>
|
||||
<HexSettingID>0x00E942FC</HexSettingID>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
<DataType>DWORD</DataType>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>rBAR - Size Limit</UserfriendlyName>
|
||||
<HexSettingID>0X000F00FF</HexSettingID>
|
||||
<HexSettingID>0x000F00FF</HexSettingID>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
<DataType>BINARY</DataType>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>rBAR - Flags (0x000F00BE)</UserfriendlyName>
|
||||
<HexSettingID>0x000F00BE</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<DataType>DWORD</DataType>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>rBAR - Flags (0x000F00BF)</UserfriendlyName>
|
||||
<HexSettingID>0x000F00BF</HexSettingID>
|
||||
<GroupName>8 - Extra</GroupName>
|
||||
<DataType>DWORD</DataType>
|
||||
</CustomSetting>
|
||||
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>GSYNC - Support Indicator Overlay</UserfriendlyName>
|
||||
<HexSettingID>0X008DF510</HexSettingID>
|
||||
<HexSettingID>0x008DF510</HexSettingID>
|
||||
<GroupName>2 - Sync and Refresh</GroupName>
|
||||
<SettingValues>
|
||||
<CustomSettingValue>
|
||||
@@ -925,7 +1017,7 @@
|
||||
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Raytracing - (DXR) Enabled</UserfriendlyName>
|
||||
<HexSettingID>0X00DE429A</HexSettingID>
|
||||
<HexSettingID>0x00DE429A</HexSettingID>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
<OverrideDefault>0x00000001</OverrideDefault>
|
||||
<SettingValues>
|
||||
@@ -6017,7 +6109,7 @@
|
||||
<SettingMasks />
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Shadercache - Enabled</UserfriendlyName>
|
||||
<UserfriendlyName>Shader Cache - Enabled</UserfriendlyName>
|
||||
<HexSettingID>0x00198FFF</HexSettingID>
|
||||
<MinRequiredDriverVersion>337.50</MinRequiredDriverVersion>
|
||||
<GroupName>5 - Common</GroupName>
|
||||
@@ -6035,7 +6127,7 @@
|
||||
<SettingMasks />
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Antialiasing Fix</UserfriendlyName>
|
||||
<UserfriendlyName>Antialiasing Fix (DX9)</UserfriendlyName>
|
||||
<HexSettingID>0x000858F7</HexSettingID>
|
||||
<MinRequiredDriverVersion>320.14</MinRequiredDriverVersion>
|
||||
<GroupName>1 - Compatibility</GroupName>
|
||||
@@ -6069,7 +6161,7 @@
|
||||
<SettingMasks />
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Texture Filtering - Driver Controlled LOD Bias</UserfriendlyName>
|
||||
<UserfriendlyName>Texture Filtering - LOD Bias Auto-Adjust (for SGSSAA)</UserfriendlyName>
|
||||
<HexSettingID>0x00638E8F</HexSettingID>
|
||||
<MinRequiredDriverVersion>313.00</MinRequiredDriverVersion>
|
||||
<GroupName>4 - Texture Filtering</GroupName>
|
||||
@@ -7637,7 +7729,7 @@
|
||||
</SettingValues>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Vulkan/OpenGL present method</UserfriendlyName>
|
||||
<UserfriendlyName>Vulkan/OpenGL Present Method</UserfriendlyName>
|
||||
<HexSettingID>0x20D690F8</HexSettingID>
|
||||
<GroupName>2 - Sync and Refresh</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
@@ -7656,6 +7748,22 @@
|
||||
</CustomSettingValue>
|
||||
</SettingValues>
|
||||
</CustomSetting>
|
||||
<CustomSetting>
|
||||
<UserfriendlyName>Vulkan/OpenGL Present Method - Flags</UserfriendlyName>
|
||||
<HexSettingID>0x20324987</HexSettingID>
|
||||
<GroupName>2 - Sync and Refresh</GroupName>
|
||||
<MinRequiredDriverVersion>0</MinRequiredDriverVersion>
|
||||
<SettingValues>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>N/A</UserfriendlyName>
|
||||
<HexValue>0x00000000</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>0x00080004 Allow promoting DXVK to DXGI/DirectFlip</UserfriendlyName>
|
||||
<HexValue>0x00080004</HexValue>
|
||||
</CustomSettingValue>
|
||||
</SettingValues>
|
||||
</CustomSetting>
|
||||
|
||||
<!--<CustomSetting>
|
||||
<UserfriendlyName>StereoProfile</UserfriendlyName>
|
||||
|
||||
@@ -3250,6 +3250,10 @@
|
||||
<UserfriendlyName>ENABLE_NON_STEREO - enable DX present on non-stereo windows</UserfriendlyName>
|
||||
<HexValue>0x00000008</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>Allow DXVK promotion</UserfriendlyName>
|
||||
<HexValue>0x00080000</HexValue>
|
||||
</CustomSettingValue>
|
||||
<CustomSettingValue>
|
||||
<UserfriendlyName>ENABLE_FULLSCREEN_WIN7_STEREO - enable Win7 fullscreen stereo mechanism</UserfriendlyName>
|
||||
<HexValue>0x10000000</HexValue>
|
||||
|
||||
1
nspector/frmDrvSettings.Designer.cs
generated
1
nspector/frmDrvSettings.Designer.cs
generated
@@ -408,6 +408,7 @@
|
||||
this.lblApplications.Size = new System.Drawing.Size(840, 17);
|
||||
this.lblApplications.TabIndex = 25;
|
||||
this.lblApplications.Text = "fsagame.exe, bond.exe, herozero.exe";
|
||||
this.lblApplications.DoubleClick += new System.EventHandler(this.tsbAddApplication_Click);
|
||||
//
|
||||
// toolStripButton5
|
||||
//
|
||||
|
||||
@@ -537,6 +537,10 @@ namespace nspector
|
||||
{
|
||||
ScaleFactor = lblWidth330.Width / 330;
|
||||
|
||||
// Later Windows versions changed DPI scaling method, check with Graphics and use it if larger
|
||||
using (Graphics g = CreateGraphics())
|
||||
ScaleFactor = Math.Max(ScaleFactor, Math.Max(g.DpiX / 96f, g.DpiY / 96f));
|
||||
|
||||
chSettingID.Width = lblWidth330.Width;
|
||||
chSettingValueHex.Width = lblWidth96.Width;
|
||||
}
|
||||
@@ -627,6 +631,8 @@ namespace nspector
|
||||
ResetSelectedValue();
|
||||
}
|
||||
|
||||
ToolTip appPathsTooltip = new ToolTip() { InitialDelay = 250 };
|
||||
|
||||
private void ChangeCurrentProfile(string profileName)
|
||||
{
|
||||
if (profileName == GetBaseProfileName() || profileName == _baseProfileName)
|
||||
@@ -636,6 +642,7 @@ namespace nspector
|
||||
tsbDeleteProfile.Enabled = false;
|
||||
tsbAddApplication.Enabled = false;
|
||||
tssbRemoveApplication.Enabled = false;
|
||||
appPathsTooltip.SetToolTip(lblApplications, "");
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -643,9 +650,9 @@ namespace nspector
|
||||
tsbDeleteProfile.Enabled = true;
|
||||
tsbAddApplication.Enabled = true;
|
||||
tssbRemoveApplication.Enabled = true;
|
||||
appPathsTooltip.SetToolTip(lblApplications, "Double-click to add application");
|
||||
}
|
||||
|
||||
|
||||
RefreshCurrentProfile();
|
||||
}
|
||||
|
||||
@@ -806,7 +813,15 @@ namespace nspector
|
||||
}
|
||||
}
|
||||
else
|
||||
ResetCurrentProfile();
|
||||
{
|
||||
if (MessageBox.Show(this,
|
||||
"Restore profile to NVIDIA driver defaults?",
|
||||
"Restore profile",
|
||||
MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
|
||||
{
|
||||
ResetCurrentProfile();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void tsbRefreshProfile_Click(object sender, EventArgs e)
|
||||
@@ -917,15 +932,24 @@ namespace nspector
|
||||
|
||||
private void tsbAddApplication_Click(object sender, EventArgs e)
|
||||
{
|
||||
var openDialog = new OpenFileDialog();
|
||||
openDialog.DefaultExt = "*.exe";
|
||||
openDialog.Filter = "Application EXE Name|*.exe|Application Absolute Path|*.exe";
|
||||
if (_CurrentProfile == GetBaseProfileName() || _CurrentProfile == _baseProfileName)
|
||||
return;
|
||||
|
||||
if (openDialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
|
||||
var applications = new Dictionary<string, string>();
|
||||
_currentProfileSettingItems = _drs.GetSettingsForProfile(_CurrentProfile, GetSettingViewMode(), ref applications);
|
||||
|
||||
var existingPaths = new HashSet<string>(applications.Values, StringComparer.OrdinalIgnoreCase);
|
||||
var applicationName = "";
|
||||
|
||||
if (InputBox.Show("Add Application", "Enter an application path/filename/UWP ID to add to the profile:", ref applicationName, new List<string>(), "", 2048, true) == DialogResult.OK)
|
||||
{
|
||||
string applicationName = new FileInfo(openDialog.FileName).Name;
|
||||
if (openDialog.FilterIndex == 2)
|
||||
applicationName = openDialog.FileName;
|
||||
// Add new application path
|
||||
if (existingPaths.Contains(applicationName))
|
||||
{
|
||||
MessageBox.Show("This application is already assigned to this profile!",
|
||||
"Error adding Application", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
@@ -936,25 +960,26 @@ namespace nspector
|
||||
if (ex.Status == Native.NVAPI2.NvAPI_Status.NVAPI_EXECUTABLE_ALREADY_IN_USE || ex.Status == Native.NVAPI2.NvAPI_Status.NVAPI_ERROR)
|
||||
{
|
||||
if (lblApplications.Text.ToUpper().IndexOf(" " + applicationName.ToUpper() + ",") != -1)
|
||||
MessageBox.Show("This application executable is already assigned to this profile!",
|
||||
MessageBox.Show("This application is already assigned to this profile!",
|
||||
"Error adding Application", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
else
|
||||
{
|
||||
string profileNames = _scanner.FindProfilesUsingApplication(applicationName);
|
||||
if (profileNames == "")
|
||||
MessageBox.Show("This application executable might already be assigned to another profile!",
|
||||
MessageBox.Show("This application might already be assigned to another profile!",
|
||||
"Error adding Application", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
else
|
||||
MessageBox.Show(
|
||||
"This application executable is already assigned to the following profiles: " +
|
||||
"This application is already assigned to the following profiles: " +
|
||||
profileNames, "Error adding Application", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
else
|
||||
throw;
|
||||
}
|
||||
|
||||
RefreshCurrentProfile();
|
||||
}
|
||||
RefreshCurrentProfile();
|
||||
}
|
||||
|
||||
private void tssbRemoveApplication_DropDownItemClicked(object sender, ToolStripItemClickedEventArgs e)
|
||||
|
||||
Reference in New Issue
Block a user