Add a confirmation dialog if the waste service disposal provider field is not empty when the template is applied
This commit is contained in:
parent
54aa91afc1
commit
0c9b38ddd9
@ -361,6 +361,13 @@ namespace ENI2.DetailViewControls
|
||||
{
|
||||
if (this._currentTemplate == null) return;
|
||||
|
||||
// confirm overwrite of waste disposal service provider
|
||||
if (this.textBox_WasteDisposalServiceProvider.Text.Length > 0)
|
||||
{
|
||||
if (MessageBox.Show(Properties.Resources.textConfirmWSDPOverwrite, Properties.Resources.textConfirmation, MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No)
|
||||
== MessageBoxResult.No) { return; }
|
||||
}
|
||||
|
||||
this._undoTemplate = createFromCurrentText(null, null);
|
||||
|
||||
this.textBox_AgentCity.Text = this._currentTemplate.AgentCity;
|
||||
|
||||
9
ENI2/Properties/Resources.Designer.cs
generated
9
ENI2/Properties/Resources.Designer.cs
generated
@ -2173,6 +2173,15 @@ namespace ENI2.Properties {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to The existing value for the waste disposal service provider will be overwritten. Proceed?.
|
||||
/// </summary>
|
||||
public static string textConfirmWSDPOverwrite {
|
||||
get {
|
||||
return ResourceManager.GetString("textConfirmWSDPOverwrite", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Construction characteristics.
|
||||
/// </summary>
|
||||
|
||||
@ -2257,4 +2257,7 @@
|
||||
<data name="textNSWStatus" xml:space="preserve">
|
||||
<value>NSW-Status</value>
|
||||
</data>
|
||||
<data name="textConfirmWSDPOverwrite" xml:space="preserve">
|
||||
<value>The existing value for the waste disposal service provider will be overwritten. Proceed?</value>
|
||||
</data>
|
||||
</root>
|
||||
@ -339,6 +339,13 @@ namespace ENI2.SheetDisplayControls
|
||||
{
|
||||
if (this._currentTemplate == null) return;
|
||||
|
||||
// confirm overwrite of waste disposal service provider
|
||||
if (this.textBox_WasteDisposalServiceProvider.Text.Length > 0)
|
||||
{
|
||||
if (MessageBox.Show(Properties.Resources.textConfirmWSDPOverwrite, Properties.Resources.textConfirmation, MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No)
|
||||
== MessageBoxResult.No) { return; }
|
||||
}
|
||||
|
||||
this._undoTemplate = createFromCurrentText(null, null);
|
||||
|
||||
this.textBox_AgentCity.Text = this._currentTemplate.AgentCity;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user