aboutsummaryrefslogtreecommitdiff
path: root/src/api
diff options
context:
space:
mode:
Diffstat (limited to 'src/api')
-rw-r--r--src/api/wix/WixToolset.Data/WarningMessages.cs727
1 files changed, 5 insertions, 722 deletions
diff --git a/src/api/wix/WixToolset.Data/WarningMessages.cs b/src/api/wix/WixToolset.Data/WarningMessages.cs
index 67915620..8391da90 100644
--- a/src/api/wix/WixToolset.Data/WarningMessages.cs
+++ b/src/api/wix/WixToolset.Data/WarningMessages.cs
@@ -3,100 +3,9 @@
3namespace WixToolset.Data 3namespace WixToolset.Data
4{ 4{
5 using System; 5 using System;
6 using System.Resources;
7 6
8 public static class WarningMessages 7 public static class WarningMessages
9 { 8 {
10 public static Message AccessDeniedForDeletion(SourceLineNumber sourceLineNumbers, string tempFilesBasePath)
11 {
12 return Message(sourceLineNumbers, Ids.AccessDeniedForDeletion, "Access denied; cannot delete '{0}'.", tempFilesBasePath);
13 }
14
15 public static Message AccessDeniedForSettingAttributes(SourceLineNumber sourceLineNumbers, string filePath)
16 {
17 return Message(sourceLineNumbers, Ids.AccessDeniedForSettingAttributes, "Access denied; cannot set attributes on '{0}'.", filePath);
18 }
19
20 public static Message ActionSequenceCollision(SourceLineNumber sourceLineNumbers, string sequenceTableName, string actionName1, string actionName2, int sequenceNumber)
21 {
22 return Message(sourceLineNumbers, Ids.ActionSequenceCollision, "The {0} table contains actions '{1}' and '{2}' which both have the same sequence number {3}. Please change the sequence number for one of these actions to avoid an ICE warning.", sequenceTableName, actionName1, actionName2, sequenceNumber);
23 }
24
25 public static Message ActionSequenceCollision2(SourceLineNumber sourceLineNumbers)
26 {
27 return Message(sourceLineNumbers, Ids.ActionSequenceCollision2, "The location of the action related to previous warning.");
28 }
29
30 public static Message AllChangesIncludedInPatch(SourceLineNumber sourceLineNumbers)
31 {
32 return Message(sourceLineNumbers, Ids.AllChangesIncludedInPatch, "All changes between the baseline and upgraded packages will be included in the patch except for any change to the ProductCode. The 'All' element is supported primarily for testing purposes and negates the benefits of patch families.");
33 }
34
35 public static Message AmbiguousFileOrDirectoryName(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string value)
36 {
37 return Message(sourceLineNumbers, Ids.AmbiguousFileOrDirectoryName, "The {0}/@{1} attribute's value '{2}' is an ambiguous short name because it ends with a '~' character followed by a number. Under some circumstances, this name could resolve to more than one file or directory name and lead to unpredictable results (for example 'MICROS~1' may correspond to 'Microsoft Shared' or 'Microsoft Foo' or literally 'Micros~1').", elementName, attributeName, value);
38 }
39
40 public static Message AttributeShouldContain(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string attributeValue, string expectedContains, string otherAttributeName, string otherAttributeValue)
41 {
42 return Message(sourceLineNumbers, Ids.AttributeShouldContain, "The {0}/@{1} attribute value '{2}' should contain '{3}' when the {0}/@{4} attribute is set to '{5}'.", elementName, attributeName, attributeValue, expectedContains, otherAttributeName, otherAttributeValue);
43 }
44
45 public static Message BackslashTerminateInlineDirectorySyntax(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string value)
46 {
47 return Message(sourceLineNumbers, Ids.BackslashTerminateInlineDirectorySyntax, "Backslash terminate the {0}/@{1} attribute's inline directory value '{2}'. A backslash ensures a directory name will not be mistaken for a directory reference.", elementName, attributeName, value);
48 }
49
50 public static Message BadColumnDataIgnored(SourceLineNumber sourceLineNumbers, string value, string tableName, string columnName)
51 {
52 return Message(sourceLineNumbers, Ids.BadColumnDataIgnored, "The value '{0}' in table '{1}', column '{2}' is invalid according to the column's validation information. The decompiled output includes a best-effort representation of this value.", value, tableName, columnName);
53 }
54
55 public static Message CannotUpdateCabCache(SourceLineNumber sourceLineNumbers, string cabinetPath, string detail)
56 {
57 return Message(sourceLineNumbers, Ids.CannotUpdateCabCache, "Cannot update the timestamp of cached cabinet: '{0}'. If the timestamp is not updated, the build may rebuild more than is necessary. To fix the issue, ensure that the cabinet file is writable, error: {1}", cabinetPath, detail);
58 }
59
60 public static Message ColumnsIncompatibleWithInstallerVersion(SourceLineNumber sourceLineNumbers, string tableName, int packageInstallerVersion)
61 {
62 return Message(sourceLineNumbers, Ids.ColumnsIncompatibleWithInstallerVersion, "Table '{0}' uses columns that require a version of Windows Installer greater than specified in your package ('{1}').", tableName, packageInstallerVersion);
63 }
64
65 public static Message CopyFileFileIdUseless(SourceLineNumber sourceLineNumbers)
66 {
67 return Message(sourceLineNumbers, Ids.CopyFileFileIdUseless, "Since the CopyFile/@FileId attribute was specified but none of the following attributes (DestinationName, DestinationDirectory, DestinationProperty) were specified, this authoring will not do anything.");
68 }
69
70 public static Message DangerousTableInMergeModule(SourceLineNumber sourceLineNumbers, string tableName)
71 {
72 return Message(sourceLineNumbers, Ids.DangerousTableInMergeModule, "Merge modules should not contain the '{0}' table because all merge conflicts cannot avoided. However, this warning can be suppressed if all of the consumers of the Merge Module agree to not duplicate identifiers in the '{0}' table.", tableName);
73 }
74
75 public static Message DecompiledStandardActionRelativelyScheduledInModule(SourceLineNumber sourceLineNumbers, string sequenceTableName, string actionName)
76 {
77 return Message(sourceLineNumbers, Ids.DecompiledStandardActionRelativelyScheduledInModule, "The {0} table contains a standard action '{1}' that does not have a sequence number specified. A value in the Sequence column is required for standard actions in a merge module. Remove the action from the decompiled authoring to have WiX automatically sequence it.", sequenceTableName, actionName);
78 }
79
80 public static Message DecompilingAsCustomTable(SourceLineNumber sourceLineNumbers, string tableName)
81 {
82 return Message(sourceLineNumbers, Ids.DecompilingAsCustomTable, "The {0} table is being decompiled as a custom table.", tableName);
83 }
84
85 public static Message DefaultLanguageUsedForUnversionedFile(SourceLineNumber sourceLineNumbers, string language, string fileId)
86 {
87 return Message(sourceLineNumbers, Ids.DefaultLanguageUsedForUnversionedFile, "The DefaultLanguage '{0}' was used for file '{1}' which has no language or version. For unversioned files, specifying a value for DefaultLanguage is not neccessary and it will not be used when determining file versions. Remove the DefaultLanguage attribute to eliminate this warning.", language, fileId);
88 }
89
90 public static Message DefaultLanguageUsedForVersionedFile(SourceLineNumber sourceLineNumbers, string language, string fileId)
91 {
92 return Message(sourceLineNumbers, Ids.DefaultLanguageUsedForVersionedFile, "The DefaultLanguage '{0}' was used for file '{1}' which has no language. Specifying a language that is different from the actual file may result in unexpected versioning behavior during a repair or while patching. Either specify a value for DefaultLanguage or put the language in the version information resource to eliminate this warning.", language, fileId);
93 }
94
95 public static Message DefaultVersionUsedForUnversionedFile(SourceLineNumber sourceLineNumbers, string version, string fileId)
96 {
97 return Message(sourceLineNumbers, Ids.DefaultVersionUsedForUnversionedFile, "The DefaultVersion '{0}' was used for file '{1}' which has no version. No entry for this file will be placed in the MsiFileHash table. For unversioned files, specifying a version that is different from the actual file may result in unexpected versioning behavior during a repair or while patching. Version the resource to eliminate this warning.", version, fileId);
98 }
99
100 public static Message DeprecatedAttribute(SourceLineNumber sourceLineNumbers, string elementName, string attributeName) 9 public static Message DeprecatedAttribute(SourceLineNumber sourceLineNumbers, string elementName, string attributeName)
101 { 10 {
102 return Message(sourceLineNumbers, Ids.DeprecatedAttribute, "The {0}/@{1} attribute has been deprecated.", elementName, attributeName); 11 return Message(sourceLineNumbers, Ids.DeprecatedAttribute, "The {0}/@{1} attribute has been deprecated.", elementName, attributeName);
@@ -122,21 +31,6 @@ namespace WixToolset.Data
122 return Message(sourceLineNumbers, Ids.DeprecatedAttributeValue, "The value \"{0}\" for the {1}/@{2} attribute has been deprecated. Please use \"{3}\" instead.", attributeValue, elementName, attributeName, newAttributeValue); 31 return Message(sourceLineNumbers, Ids.DeprecatedAttributeValue, "The value \"{0}\" for the {1}/@{2} attribute has been deprecated. Please use \"{3}\" instead.", attributeValue, elementName, attributeName, newAttributeValue);
123 } 32 }
124 33
125 public static Message DeprecatedCommandLineSwitch(string oldSwitch)
126 {
127 return Message(null, Ids.DeprecatedCommandLineSwitch, "The command line switch '{0}' is deprecated.", oldSwitch);
128 }
129
130 public static Message DeprecatedCommandLineSwitch(string oldSwitch, string newSwitch)
131 {
132 return Message(null, Ids.DeprecatedCommandLineSwitch, "The command line switch '{0}' is deprecated. Please use '{1}' instead.", oldSwitch, newSwitch);
133 }
134
135 public static Message DeprecatedComponentGroupId(SourceLineNumber sourceLineNumbers, string elementName)
136 {
137 return Message(sourceLineNumbers, Ids.DeprecatedComponentGroupId, "The {0}/@Id attribute contains invalid characters for an identifier. Being able to use invalid identifier characters for a {0} identifier has been deprecated.", elementName);
138 }
139
140 public static Message DeprecatedElement(SourceLineNumber sourceLineNumbers, string elementName) 34 public static Message DeprecatedElement(SourceLineNumber sourceLineNumbers, string elementName)
141 { 35 {
142 return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated.", elementName); 36 return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated.", elementName);
@@ -152,126 +46,6 @@ namespace WixToolset.Data
152 return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated. Please use the {1} or {2} element instead.", elementName, newElementName1, newElementName2); 46 return Message(sourceLineNumbers, Ids.DeprecatedElement, "The {0} element has been deprecated. Please use the {1} or {2} element instead.", elementName, newElementName1, newElementName2);
153 } 47 }
154 48
155 public static Message DeprecatedIgnoreModularizationElement(SourceLineNumber sourceLineNumbers)
156 {
157 return Message(sourceLineNumbers, Ids.DeprecatedIgnoreModularizationElement, "The IgnoreModularization element has been deprecated. Use the Binary/@SuppressModularization, CustomAction/@SuppressModularization, or Property/@SuppressModularization attribute instead.");
158 }
159
160 public static Message DeprecatedLocalizationVariablePrefix(SourceLineNumber sourceLineNumbers, string variableId)
161 {
162 return Message(sourceLineNumbers, Ids.DeprecatedLocalizationVariablePrefix, "The localization variable $(loc.{0}) uses a deprecated prefix '$'. Please use the '!' prefix instead. Since the prefix '$' is also used by the preprocessor, it has been deprecated to avoid namespace collisions.", variableId);
163 }
164
165 public static Message DeprecatedLongNameAttribute(SourceLineNumber sourceLineNumbers, string elementName, string longNameAttributeName, string nameAttributeName, string shortNameAttributeName)
166 {
167 return Message(sourceLineNumbers, Ids.DeprecatedLongNameAttribute, "The {0}/@{1} attribute has been deprecated. Since WiX now has the ability to generate short file/directory names, the desired name should be specified in the {2} attribute instead. If the name specified in the {2} attribute is a short name, then WiX will not generate a short name. If the name specified in the {2} attribute is a long name and you want to manually specify the short name, please set the short name value in the {3} attribute.", elementName, longNameAttributeName, nameAttributeName, shortNameAttributeName);
168 }
169
170 public static Message DeprecatedPreProcVariable(SourceLineNumber sourceLineNumbers, string oldName, string newName)
171 {
172 return Message(sourceLineNumbers, Ids.DeprecatedPreProcVariable, "The built-in preprocessor variable '{0}' is deprecated. Please correct your authoring to use the new '{1}' preprocessor variable instead.", oldName, newName);
173 }
174
175 public static Message DeprecatedQuestionMarksGuid(SourceLineNumber sourceLineNumbers, string elementName, string attributeName)
176 {
177 return Message(sourceLineNumbers, Ids.DeprecatedQuestionMarksGuid, "The {0}/@{1} attribute's value '????????-????-????-????-????????????' has been deprecated. Use '*' instead.", elementName, attributeName);
178 }
179
180 public static Message DeprecatedRegistryElement(SourceLineNumber sourceLineNumbers)
181 {
182 return Message(sourceLineNumbers, Ids.DeprecatedRegistryElement, "The Registry element has been deprecated. Please use one of the new elements which replaces its functionality: RegistryKey for creating registry keys, RegistryValue for writing registry values, RemoveRegistryKey for removing registry keys, and RemoveRegistryValue for removing registry values.");
183 }
184
185 public static Message DeprecatedRegistryKeyActionAttribute(SourceLineNumber sourceLineNumbers)
186 {
187 return Message(sourceLineNumbers, Ids.DeprecatedRegistryKeyActionAttribute, "The RegistryKey/@Action attribute has been deprecated. In most cases, you can simply omit @Action. If you need to force Windows Installer to create an empty key or recursively delete the key, use the ForceCreateOnInstall or ForceDeleteOnUninstall attributes instead.");
188 }
189
190 public static Message DeprecatedTable(string tableName)
191 {
192 return Message(null, Ids.DeprecatedTable, "The {0} table is not supported by the WiX toolset because it has been deprecated by the Windows Installer team. Any information in this table will be left out of the decompiled output.", tableName);
193 }
194
195 public static Message DeprecatedUpgradeProperty(SourceLineNumber sourceLineNumbers)
196 {
197 return Message(sourceLineNumbers, Ids.DeprecatedUpgradeProperty, "Specifying a Property element as a child of an Upgrade element has been deprecated. Please specify this Property element as a child of a different element such as Package or Fragment.");
198 }
199
200 public static Message DirectoryInUse(SourceLineNumber sourceLineNumbers, string filePath)
201 {
202 return Message(sourceLineNumbers, Ids.DirectoryInUse, "The directory '{0}' is in use and cannot be deleted.", filePath);
203 }
204
205 public static Message DirectoryRedundantNames(SourceLineNumber sourceLineNumbers, string elementName, string shortNameAttributeName, string longNameAttributeName, string attributeValue)
206 {
207 return Message(sourceLineNumbers, Ids.DirectoryRedundantNames, "The {0} element's {1} and {2} values are both '{3}'. This is redundant; the {2} attribute should be removed.", elementName, shortNameAttributeName, longNameAttributeName, attributeValue);
208 }
209
210 public static Message DirectoryRedundantNames(SourceLineNumber sourceLineNumbers, string elementName, string sourceNameAttributeName, string longSourceAttributeName)
211 {
212 return Message(sourceLineNumbers, Ids.DirectoryRedundantNames, "The {0} element's source and destination names are identical. This is redundant; the {1} and {2} attributes should be removed if present.", elementName, sourceNameAttributeName, longSourceAttributeName);
213 }
214
215 public static Message DiscardedRollbackBoundary(SourceLineNumber sourceLineNumbers, string rollbackBoundaryId)
216 {
217 return Message(sourceLineNumbers, Ids.DiscardedRollbackBoundary, "The RollbackBoundary '{0}' was discarded because it was not followed by a package. Without a package the rollback boundary doesn't do anything. Verify that the RollbackBoundary element is not followed by another RollbackBoundary and that the element is not at the end of the chain.", rollbackBoundaryId);
218 }
219
220 public static Message DiscardedRollbackBoundary2(SourceLineNumber sourceLineNumbers)
221 {
222 return Message(sourceLineNumbers, Ids.DiscardedRollbackBoundary2, "Location of rollback boundary related to previous warning.");
223 }
224
225 public static Message DiscouragedAllUsersValue(SourceLineNumber sourceLineNumbers, string path, string machineOrUser)
226 {
227 return Message(sourceLineNumbers, Ids.DiscouragedAllUsersValue, "Bundles require a package to be either per-machine or per-user. The MSI '{0}' ALLUSERS Property is set to '2' which may change from per-user to per-machine at install time. The Bundle will assume the package is per-{1} and will not work correctly if that changes. If possible, use the Package/@Scope attribute values 'perUser' or 'perMachine' instead.", path, machineOrUser);
228 }
229
230 public static Message DetectConditionRecommended(SourceLineNumber sourceLineNumbers, string elementName)
231 {
232 return Message(sourceLineNumbers, Ids.DetectConditionRecommended, "The {0}/@DetectCondition attribute is recommended so the package is only installed when absent.", elementName);
233 }
234
235 public static Message ExePackageDetectInformationRecommended(SourceLineNumber sourceLineNumbers)
236 {
237 return Message(sourceLineNumbers, Ids.ExePackageDetectInformationRecommended, "The ExePackage/@DetectCondition attribute or child element ArpEntry is recommended so the package is only installed when absent.");
238 }
239
240 public static Message DownloadUrlNotSupportedForAttachedContainers(SourceLineNumber sourceLineNumbers, string containerId)
241 {
242 return Message(sourceLineNumbers, Ids.DownloadUrlNotSupportedForAttachedContainers, "The Container '{0}' is attached but included a @DownloadUrl attribute. Attached Containers cannot be downloaded so the download URL is being ignored.", containerId);
243 }
244
245 public static Message DownloadUrlNotSupportedForBAPayloads(SourceLineNumber sourceLineNumbers, string payloadId)
246 {
247 return Message(sourceLineNumbers, Ids.DownloadUrlNotSupportedForBAPayloads, "The BootstrapperApplication Payload '{0}' included a @DownloadUrl attribute. BootstrapperApplication Payloads cannot be downloaded so the download URL is being ignored.", payloadId);
248 }
249
250 public static Message DuplicateComponentGuidsMustHaveMutuallyExclusiveConditions(SourceLineNumber sourceLineNumbers, string componentId, string guid, string type, string keyPath)
251 {
252 return Message(sourceLineNumbers, Ids.DuplicateComponentGuidsMustHaveMutuallyExclusiveConditions, "Component/@Id='{0}' with {2} '{3}' has a @Guid value '{1}' that duplicates another component in this package. This is not officially supported by Windows Installer and cannot be used when creating patches. It otherwise works as long as all components with the same GUID have mutually-exclusive conditions. It is recommended to give each component its own unique GUID.", componentId, guid, type, keyPath);
253 }
254
255 public static Message DuplicatePrimaryKey(SourceLineNumber sourceLineNumbers, string primaryKey, string tableName)
256 {
257 return Message(sourceLineNumbers, Ids.DuplicatePrimaryKey, "The primary key '{0}' is duplicated in table '{1}' and will be ignored. Please remove one of the entries or rename a part of the primary key to avoid the collision.", primaryKey, tableName);
258 }
259
260 public static Message EmptyAttributeValue(SourceLineNumber sourceLineNumbers, string elementName, string attributeName)
261 {
262 return Message(sourceLineNumbers, Ids.EmptyAttributeValue, "The {0}/@{1} attribute's value cannot be an empty string. If you want the value to be null or empty, simply remove the entire attribute.", elementName, attributeName);
263 }
264
265 public static Message EmptyCabinet(SourceLineNumber sourceLineNumbers, string cabinetName, bool isPatch)
266 {
267 if (isPatch)
268 {
269 return Message(sourceLineNumbers, Ids.EmptyCabinet, "The cabinet '{0}' does not contain any files. If this patch contains no files, this warning can likely be safely ignored. Otherwise, try passing -p to torch.exe when first building the transforms, or add a ComponentRef to your PatchFamily authoring to pull changed files into the cabinet.", cabinetName, isPatch);
270 }
271
272 return Message(sourceLineNumbers, Ids.EmptyCabinet, "The cabinet '{0}' does not contain any files. If this installation contains no files, this warning can likely be safely ignored. Otherwise, please add files to the cabinet or remove it.", cabinetName);
273 }
274
275 public static Message ExpectedForeignRow(SourceLineNumber sourceLineNumbers, string tableName, string primaryKey, string columnName, string columnValue, string foreignTableName) 49 public static Message ExpectedForeignRow(SourceLineNumber sourceLineNumbers, string tableName, string primaryKey, string columnName, string columnValue, string foreignTableName)
276 { 50 {
277 return Message(sourceLineNumbers, Ids.ExpectedForeignRow, "The {0} table contains a row with primary key(s) '{1}' whose {2} column contains a value, '{3}', which specifies a foreign key relationship with the {4} table. However, since the expected foreign row specified by this value does not exist, this will result in some information being left out of the decompiled output.", tableName, primaryKey, columnName, columnValue, foreignTableName); 51 return Message(sourceLineNumbers, Ids.ExpectedForeignRow, "The {0} table contains a row with primary key(s) '{1}' whose {2} column contains a value, '{3}', which specifies a foreign key relationship with the {4} table. However, since the expected foreign row specified by this value does not exist, this will result in some information being left out of the decompiled output.", tableName, primaryKey, columnName, columnValue, foreignTableName);
@@ -282,375 +56,19 @@ namespace WixToolset.Data
282 return Message(sourceLineNumbers, Ids.ExpectedForeignRow, "The {0} table contains a row with primary key(s) '{1}' whose {2} and {4} columns contain the values, '{3}' and '{5}', which specify a foreign key relationship with the {6} table. However, since the expected foreign row specified by this value does not exist, this will result in some information being left out of the decompiled output.", tableName, primaryKey, columnName1, columnValue1, columnName2, columnValue2, foreignTableName); 56 return Message(sourceLineNumbers, Ids.ExpectedForeignRow, "The {0} table contains a row with primary key(s) '{1}' whose {2} and {4} columns contain the values, '{3}' and '{5}', which specify a foreign key relationship with the {6} table. However, since the expected foreign row specified by this value does not exist, this will result in some information being left out of the decompiled output.", tableName, primaryKey, columnName1, columnValue1, columnName2, columnValue2, foreignTableName);
283 } 57 }
284 58
285 public static Message ExternalCabsAreNotSigned(string databaseFile)
286 {
287 return Message(null, Ids.ExternalCabsAreNotSigned, "The installer database '{0}' has external cabs, but at least one of them is not signed. Please ensure that all external cabs are signed, if you mean to sign them. If you don't mean to sign them, there is no need to inscribe the MSI as part of your build.", databaseFile);
288 }
289
290 public static Message FailedToDeleteTempDir(string directory)
291 {
292 return Message(null, Ids.FailedToDeleteTempDir, "Failed to delete temporary directory: {0}", directory);
293 }
294
295 public static Message FileSearchFileNameIssue(SourceLineNumber sourceLineNumbers, string elementName, string attributeName1, string attributeName2)
296 {
297 return Message(sourceLineNumbers, Ids.FileSearchFileNameIssue, "The {0} element's {1} and {2} attributes were found. Due to a bug with the Windows Installer, only the Name or LongName attribute should be used. Use the Name attribute for 8.3 compliant file names and the LongName attribute for longer ones. When using only the LongName attribute, ICE03 should be ignored for the Signature table's FileName column.", elementName, attributeName1, attributeName2);
298 }
299
300 public static Message GeneratedShortFileNameConflict(SourceLineNumber sourceLineNumbers, string shortFileName)
301 {
302 return Message(sourceLineNumbers, Ids.GeneratedShortFileNameConflict, "The short file name '{0}' was generated for multiple files that may be installed to the same directory. This could be due to conflicting long file names specified by the File/@Name attribute. If that is the case, please resolve the conflict in those attributes. Otherwise, please manually set the File/@ShortName attribute on the conflicting row to fix the collision. If one of the colliding files was added via a patch, that short file name should be specified manually to avoid disturbing the original short file name.", shortFileName);
303 }
304
305 public static Message GeneratedShortFileNameConflict2(SourceLineNumber sourceLineNumbers)
306 {
307 return Message(sourceLineNumbers, Ids.GeneratedShortFileNameConflict2, "The location of a conflicting generated short file name related to the previous warning.");
308 }
309
310 public static Message IdentifierCannotBeModularized(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string identifier, int length, int maximumLength)
311 {
312 return Message(sourceLineNumbers, Ids.IdentifierCannotBeModularized, "The {0}/@{1} attribute's value, '{2}', is {3} characters long. It will be too long if modularized. The identifier shouldn't be longer than {4} characters long to allow for modularization (appending a guid for merge modules).", elementName, attributeName, identifier, length, maximumLength);
313 }
314
315 public static Message IdentifierTooLong(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string value)
316 {
317 return Message(sourceLineNumbers, Ids.IdentifierTooLong, "The {0}/@{1} attribute's value, '{2}', is too long for an identifier. Standard identifiers are 72 characters long or less.", elementName, attributeName, value);
318 }
319
320 public static Message IllegalActionInSequence(SourceLineNumber sourceLineNumbers, string sequenceTableName, string actionName)
321 {
322 return Message(sourceLineNumbers, Ids.IllegalActionInSequence, "The {0} table contains an action '{1}' which is not allowed in this table. If this is a standard action then it is not valid for this table, if it is a custom action or dialog then this table does not accept actions of that type. This action will be left out of the decompiled output.", sequenceTableName, actionName);
323 }
324
325 public static Message IllegalColumnValue(SourceLineNumber sourceLineNumbers, string tableName, string columnName, object value) 59 public static Message IllegalColumnValue(SourceLineNumber sourceLineNumbers, string tableName, string columnName, object value)
326 { 60 {
327 return Message(sourceLineNumbers, Ids.IllegalColumnValue, "The {0}.{1} column's value, '{2}', is not a recognized legal value. This information will be left out of the decompiled output.", tableName, columnName, value); 61 return Message(sourceLineNumbers, Ids.IllegalColumnValue, "The {0}.{1} column's value, '{2}', is not a recognized legal value. This information will be left out of the decompiled output.", tableName, columnName, value);
328 } 62 }
329 63
330 public static Message IllegalRegistryKeyPath(SourceLineNumber sourceLineNumbers, string componentName, string registryId)
331 {
332 return Message(sourceLineNumbers, Ids.IllegalRegistryKeyPath, "Component '{0}' specifies an illegal registry keypath of '{1}'. Since this entry actually represents a registry key, not a registry value, it cannot be the keypath.", componentName, registryId);
333 }
334
335 public static Message ImplicitComponentPrimaryFeature(string componentId)
336 {
337 return Message(null, Ids.ImplicitComponentPrimaryFeature, "The component '{0}' does not have an explicit primary feature parent specified. If the source files are linked in a different order, the primary parent feature may change. To prevent accidental changes, the primary feature parent should be set to 'yes' in one of the ComponentRef/@Primary, ComponentGroupRef/@Primary, or FeatureGroupRef/@Primary locations for this component.", componentId);
338 }
339
340 public static Message ImplicitlyPerUser(SourceLineNumber sourceLineNumbers, string path)
341 {
342 return Message(sourceLineNumbers, Ids.ImplicitlyPerUser, "The MSI '{0}' does not explicitly indicate that it is a per-user package even though the ALLUSERS Property is blank. This suggests a per-user package so the Bundle will assume the package is per-user. If possible, use the Package/@InstallScope attribute to be explicit instead.", path);
343 }
344
345 public static Message ImplicitMergeModulePrimaryFeature(string componentId)
346 {
347 return Message(null, Ids.ImplicitMergeModulePrimaryFeature, "The merge module '{0}' does not have an explicit primary feature parent specified. If the source files are linked in a different order, the primary parent feature may change. To prevent accidental changes, the primary feature parent should be set to 'yes' in one of the MergeRef/@Primary or FeatureGroupRef/@Primary locations for this component.", componentId);
348 }
349
350 public static Message InvalidAttributeCombination(SourceLineNumber sourceLineNumbers, string attrib1, string attrib2, string name, string value)
351 {
352 return Message(sourceLineNumbers, Ids.InvalidAttributeCombination, "It is invalid to combine attributes {0} and {1}. The decompiled output will set attribute {2} to {3}.", attrib1, attrib2, name, value);
353 }
354
355 public static Message InvalidHigherInstallerVersionInModule(SourceLineNumber sourceLineNumbers, string moduleId, int moduleInstallerVersion, int packageInstallerVersion)
356 {
357 return Message(sourceLineNumbers, Ids.InvalidHigherInstallerVersionInModule, "Merge module '{0}' has an installer version of {1} which is greater than the package's installer version of {2}. Merging a module with a higher installer version than the package it is being merged into can result in invalid values in the resulting msi. You must set the Package/@InstallerVersion attribute to {1} or greater to merge this merge module into your package.", moduleId, moduleInstallerVersion, packageInstallerVersion);
358 }
359
360 public static Message InvalidFourPartVersion(SourceLineNumber sourceLineNumbers, string elementName, string version)
361 {
362 return Message(sourceLineNumbers, Ids.InvalidFourPartVersion, "Invalid {0}/@Version '{1}'. {0} version has a max value of \"65535.65535.65535.65535\" and must be all numeric.", elementName, version);
363 }
364
365 public static Message InvalidRemoveFile(SourceLineNumber sourceLineNumbers, string file, string component)
366 {
367 return Message(sourceLineNumbers, Ids.InvalidRemoveFile, "File '{0}' was removed from component '{1}'. Removing a file from a component will not result in the file being removed by a patch. You should author a RemoveFile element in your component to remove the file from the installation if you want the file to be removed.", file, component);
368 }
369
370 public static Message MajorUpgradePatchNotRecommended()
371 {
372 return Message(null, Ids.MajorUpgradePatchNotRecommended, "Changing the ProductCode in a patch is not recommended because the patch cannot be uninstalled nor can it be sequenced along with other patches for the target package. See https://learn.microsoft.com/en-us/windows/win32/msi/applying-major-upgrades-by-patching-the-local-installation-of-the-product for more information.");
373 }
374
375 public static Message MediaExternalCabinetFilenameIllegal(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string value)
376 {
377 return Message(sourceLineNumbers, Ids.MediaExternalCabinetFilenameIllegal, "The {0}/@{1} attribute's value, '{2}', is not a valid external cabinet name. Legal cabinet names should follow 8.3 format: they should contain no more than 8 characters followed by an optional extension of no more than 3 characters. Any character except for the following may be used: \\ ? | > < : / * \" + , ; = [ ] (space). The Windows Installer team has recommended following the 8.3 format for external cabinet files and any other naming scheme is officially unsupported (which means it is not guaranteed to work on all platforms).", elementName, attributeName, value);
378 }
379
380 public static Message MergeRescheduledAction(SourceLineNumber sourceLineNumbers, string tableName, string actionName, string mergeModuleFile)
381 {
382 return Message(sourceLineNumbers, Ids.MergeRescheduledAction, "The {0} table contains an action '{1}' which cannot be merged from the merge module '{2}'. This action is likely colliding with an action in the database that is being created. The colliding action may have been authored in the database or merged in from another merge module. If this is a standard action, it is likely colliding due to a difference in the condition for the action in the database and merge module. If this is a custom action, it should only be declared in the database or one merge module.", tableName, actionName, mergeModuleFile);
383 }
384
385 public static Message MergeTableFailed(SourceLineNumber sourceLineNumbers, string tableName, string primaryKeys, string mergeModuleFile)
386 {
387 return Message(sourceLineNumbers, Ids.MergeTableFailed, "The {0} table contains a row with primary key(s) '{1}' which cannot be merged from the merge module '{2}'. This is likely due to collision of rows with the same primary key(s) (but other different values in other columns) between the database and the merge module.", tableName, primaryKeys, mergeModuleFile);
388 }
389
390 public static Message MissingUpgradeCode(SourceLineNumber sourceLineNumbers)
391 {
392 return Message(sourceLineNumbers, Ids.MissingUpgradeCode, "The Package/@UpgradeCode attribute was not found; it is strongly recommended to ensure that this package can be upgraded.");
393 }
394
395 public static Message MsiTransactionLimitations(SourceLineNumber sourceLineNumbers)
396 {
397 return Message(sourceLineNumbers, Ids.MsiTransactionLimitations, "MSI transactions have limitations that make it hard to use them successfully in a bundle. Test the bundle thoroughly, especially in upgrade scenarios and the scenario that required them in the first place.");
398 }
399
400 public static Message NestedInstall(SourceLineNumber sourceLineNumbers, string tableName, string columnName, object value)
401 {
402 return Message(sourceLineNumbers, Ids.NestedInstall, "The {0}.{1} column's value, '{2}', indicates a nested install. Nested installations are not supported by the WiX team. This action will be left out of the decompiled output.", tableName, columnName, value);
403 }
404
405 public static Message NewComponentAddedToExistingFeature(SourceLineNumber sourceLineNumbers, string component, string feature, string transformPath)
406 {
407 return Message(sourceLineNumbers, Ids.NewComponentAddedToExistingFeature, "Component '{0}' was added to feature '{1}' in the transform '{2}'. If you cannot guarantee that this feature will always be installed, you should consider adding new components to new top-level features to prevent prompts for source when installing this patch.", component, feature, transformPath);
408 }
409
410 public static Message NoPerMachineDependencies(SourceLineNumber sourceLineNumbers, string packageId)
411 {
412 return Message(sourceLineNumbers, Ids.NoPerMachineDependencies, "Bundle dependencies will not be registered on per-machine package '{0}' for a per-user bundle. Either make sure that all packages are installed per-machine, or author any per-machine dependencies as permanent packages.", packageId);
413 }
414
415 public static Message NotABinaryWixlib(string wixlib)
416 {
417 return Message(null, Ids.NotABinaryWixlib, "'{0}' is not a binary Wixlib and has no embedded files.", wixlib);
418 }
419
420 public static Message NullMsiAssemblyNameValue(SourceLineNumber sourceLineNumbers, string componentName, string name)
421 {
422 return Message(sourceLineNumbers, Ids.NullMsiAssemblyNameValue, "The assembly in component '{0}' has a null or empty {1} assembly name value.", componentName, name);
423 }
424
425 public static Message OrphanedProgId(SourceLineNumber sourceLineNumbers, string progId)
426 {
427 return Message(sourceLineNumbers, Ids.OrphanedProgId, "ProgId '{0}' is orphaned. It has no associated component, so it will never install. Every ProgId should have either a parent Class element or child Extension element (at any distance).", progId);
428 }
429
430 public static Message PackageCodeSet(SourceLineNumber sourceLineNumbers)
431 {
432 return Message(sourceLineNumbers, Ids.PackageCodeSet, "The Package/@Id attribute has been set. Setting this attribute will allow nonidentical .msi files to have the same package code. This may be a problem because the package code is the primary identifier used by the installer to search for and validate the correct package for a given installation. If a package is changed without changing the package code, the installer may not use the newer package if both are still accessible to the installer. Please remove the Id attribute in order to automatically generate a new package code for each new .msi file.");
433 }
434
435 public static Message PatchTable(SourceLineNumber sourceLineNumbers, string tableName)
436 {
437 return Message(sourceLineNumbers, Ids.PatchTable, "The {0} table is added to the install package by a transform from a patch package (.msp) and not authored directly into an install package (.msi). The information in this table will be left out of the decompiled output.", tableName);
438 }
439
440 public static Message PathCanonicalized(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string originalValue, string canonicalValue)
441 {
442 return Message(sourceLineNumbers, Ids.PathCanonicalized, "The {0}/@{1} attribute's value, '{2}', has been canonicalized to '{3}'.", elementName, attributeName, originalValue, canonicalValue);
443 }
444
445 public static Message PerUserButForcingPerMachine(SourceLineNumber sourceLineNumbers, string path)
446 {
447 return Message(sourceLineNumbers, Ids.PerUserButForcingPerMachine, "The MSI '{0}' is a per-user package being forced to per-machine. Verify that the MsiPackage/@ForcePerMachine attribute is expected and that the per-user package works correctly when forced to install per-machine.", path);
448 }
449
450 public static Message PlaceholderValue(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string value)
451 {
452 return Message(sourceLineNumbers, Ids.PlaceholderValue, "The {0}/@{1} attribute's value, '{2}', is a placeholder value used in example files. Please replace this placeholder with the appropriate value.", elementName, attributeName, value);
453 }
454
455 public static Message PossiblyIncorrectTypelibVersion(SourceLineNumber sourceLineNumbers, string id)
456 {
457 return Message(sourceLineNumbers, Ids.PossiblyIncorrectTypelibVersion, "The Typelib table entry with Id '{0}' could have an incorrect version of '256.0'. InstallShield has a bug relating to the Typelib Version column: it will incorrectly set the value '65536' in to represent version '1.0'. However, this number actually corresponds to version '256.0'. This bug will not affect the typelib version that is registered during installation, however, it will prevent the Windows Installer from correctly identifying whether a typelib is already installed and lead to unnecessary reinstallations of the typelib.", id);
458 }
459
460 public static Message PreprocessorUnknownPragma(SourceLineNumber sourceLineNumbers, string pragmaName)
461 {
462 return Message(sourceLineNumbers, Ids.PreprocessorUnknownPragma, "The pragma '{0}' is unknown. Please ensure you have referenced the extension that defines this pragma.", pragmaName);
463 }
464
465 public static Message PreprocessorWarning(SourceLineNumber sourceLineNumbers, string message)
466 {
467 return Message(sourceLineNumbers, Ids.PreprocessorWarning, "{0}", message);
468 }
469
470 public static Message ProductIdAuthored(SourceLineNumber sourceLineNumbers)
471 {
472 return Message(sourceLineNumbers, Ids.ProductIdAuthored, "The 'ProductID' property should not be directly authored because it will prevent the ValidateProductID standard action from performing any validation during the installation. This property will be set by the ValidateProductID standard action or control event.");
473 }
474
475 public static Message PropertyModularizationSuppressed(SourceLineNumber sourceLineNumbers)
476 {
477 return Message(sourceLineNumbers, Ids.PropertyModularizationSuppressed, "The Property/@SuppressModularization attribute has been set to 'yes'. Using this functionality is strongly discouraged; it should only be necessary as a workaround of last resort in rare scenarios.");
478 }
479
480 public static Message PropertyUseless(SourceLineNumber sourceLineNumbers, string id)
481 {
482 return Message(sourceLineNumbers, Ids.PropertyUseless, "Property '{0}' does not contain a Value attribute and is not marked as Admin, Secure, or Hidden. The Property element is being ignored.", id);
483 }
484
485 public static Message PropertyValueContainsPropertyReference(SourceLineNumber sourceLineNumbers, string propertyId, string otherProperty)
486 {
487 return Message(sourceLineNumbers, Ids.PropertyValueContainsPropertyReference, "The '{0}' Property contains '[{1}]' in its value which is an illegal reference to another property. If this value is a string literal, not a property reference, please ignore this warning. To set a property with the value of another property, use a CustomAction with Property and Value attributes.", propertyId, otherProperty);
488 }
489
490 public static Message RelatedAttributeConditionallyIgnored(SourceLineNumber sourceLineNumbers, string recessiveAttribute, string dominantAttribute, string dominantValue)
491 {
492 return Message(sourceLineNumbers, Ids.RelatedAttributeConditionallyIgnored, "Ignoring attribute {0} because attribute {1} is set to {2}.", recessiveAttribute, dominantAttribute, dominantValue);
493 }
494
495 public static Message RemotePayloadsMustNotAlsoBeCompressed(SourceLineNumber sourceLineNumbers, string elementName)
496 {
497 return Message(sourceLineNumbers, Ids.RemotePayloadsMustNotAlsoBeCompressed, "The {0}/@Compressed attribute must have value 'no' when a RemotePayload child element is present. RemotePayload indicates that a package will always be downloaded and cannot be compressed into a bundle. To eliminate this warning, explicitly set the {0}/@Compressed attribute to 'no'.", elementName);
498 }
499
500 public static Message RemoveFileNameRequired(SourceLineNumber sourceLineNumbers)
501 {
502 return Message(sourceLineNumbers, Ids.RemoveFileNameRequired, "The RemoveFile/@Name attribute will soon become required. In order to match the old functionality of not specifying this attribute, please use the new RemoveFolder element instead.");
503 }
504
505 public static Message RequiresMsi200for64bitPackage(SourceLineNumber sourceLineNumbers)
506 {
507 return Message(sourceLineNumbers, Ids.RequiresMsi200for64bitPackage, "Package/@InstallerVersion must be 200 or greater for a 64-bit package. The value will be changed to 200. Please specify a value of 200 or greater in order to eliminate this warning.");
508 }
509
510 public static Message RequiresMsi500forArmPackage(SourceLineNumber sourceLineNumbers)
511 {
512 return Message(sourceLineNumbers, Ids.RequiresMsi500forArmPackage, "Package/@InstallerVersion must be 500 or greater for an ARM64 package. The value will be changed to 500. Please specify a value of 500 or greater in order to eliminate this warning.");
513 }
514
515 public static Message ReservedAttribute(SourceLineNumber sourceLineNumbers, string elementName, string attributeName)
516 {
517 return Message(sourceLineNumbers, Ids.ReservedAttribute, "The {0}/@{1} attribute is reserved for future use and has no effect in this version of the WiX toolset.", elementName, attributeName);
518 }
519
520 public static Message RetainRangeMismatch(SourceLineNumber sourceLineNumbers, string fileId)
521 {
522 return Message(sourceLineNumbers, Ids.RetainRangeMismatch, "Mismatch in RetainRangeCounts for the file '{0}' - ignoring the retain ranges.", fileId);
523 }
524
525 public static Message ServiceConfigFamilyNotSupported(SourceLineNumber sourceLineNumbers, string elementName)
526 {
527 return Message(sourceLineNumbers, Ids.ServiceConfigFamilyNotSupported, "{0} functionality is documented in the Windows Installer SDK to \"not [work] as expected.\" Consider replacing {0} with the WixToolset.Util.wixext ServiceConfig element.", elementName);
528 }
529
530 public static Message SkippingMergeModuleTable(SourceLineNumber sourceLineNumbers, string tableName)
531 {
532 return Message(sourceLineNumbers, Ids.SkippingMergeModuleTable, "The {0} table can only be represented in WiX for merge modules. The information in this table will be left out of the decompiled output.", tableName);
533 }
534
535 public static Message StandardDirectoryConflictInMergeModule(SourceLineNumber sourceLineNumbers, string directory, string standardDirectory)
536 {
537 return Message(sourceLineNumbers, Ids.StandardDirectoryConflictInMergeModule, "The Directory '{0}' starts with the same Id as the standard folder in Windows Installer '{1}'. A directory Id that begins with the same Id as a standard folder that is in an MSM may encounter a conflict when merging the MSM into an MSI. This may result in the contents of this merge module being installed to an unexpected location. To eliminate this warning, change your directory Id to not start with the same Id as any standard folders.", directory, standardDirectory);
538 }
539
540 public static Message SuppressAction(SourceLineNumber sourceLineNumbers, string action, string sequenceName)
541 {
542 return Message(sourceLineNumbers, Ids.SuppressAction, "The action '{0}' in the {1} table is being suppressed.", action, sequenceName);
543 }
544
545 public static Message SuppressAction2(SourceLineNumber sourceLineNumbers)
546 {
547 return Message(sourceLineNumbers, Ids.SuppressAction2, "The location of the suppressed action related to previous warning.");
548 }
549
550 public static Message SuppressMergedAction(string action, string sequenceName)
551 {
552 return Message(null, Ids.SuppressMergedAction, "The merged action '{0}' in the {1} table is being suppressed.", action, sequenceName);
553 }
554
555 public static Message TableIncompatibleWithInstallerVersion(SourceLineNumber sourceLineNumbers, string tableName, int packageInstallerVersion)
556 {
557 return Message(sourceLineNumbers, Ids.TableIncompatibleWithInstallerVersion, "Using table '{0}' requires a version of Windows Installer greater than specified in your package ('{1}').", tableName, packageInstallerVersion);
558 }
559
560 public static Message TargetDirCorrectedDefaultDir()
561 {
562 return Message(null, Ids.TargetDirCorrectedDefaultDir, "The Directory with Id 'TARGETDIR' must have the value 'SourceDir' in its 'DefaultDir' column. This has been automatically corrected for you in the decompiled output.");
563 }
564
565 public static Message TooManyProgIds(SourceLineNumber sourceLineNumbers, string clsId, string progId, string otherClsId)
566 {
567 return Message(sourceLineNumbers, Ids.TooManyProgIds, "Class '{0}' tried to use ProgId '{1}' which has already been associated with class '{2}'. This information will be left out of the decompiled output.", clsId, progId, otherClsId);
568 }
569
570 public static Message SymbolNotTranslatedToOutput(IntermediateSymbol symbol)
571 {
572 var symbolString = $"SymbolName: '{symbol.Definition.Name}', Id: '{symbol.Id?.Id}'";
573 return Message(symbol.SourceLineNumbers, Ids.SymbolNotTranslatedToOutput, "The binder doesn't know how to place the following symbol into the output: {0}", symbolString);
574 }
575
576 public static Message UnableToFindFileFromCabOrImage(SourceLineNumber sourceLineNumbers, string existingFileSpec, string srcFileSpec)
577 {
578 return Message(sourceLineNumbers, Ids.UnableToFindFileFromCabOrImage, "Unable to find existing file {0} to place in src location {1}. Will likely cause a linker break.", existingFileSpec, srcFileSpec);
579 }
580
581 public static Message UnableToResetAcls(string error)
582 {
583 return Message(null, Ids.UnableToResetAcls, "Unable to reset acls on destination files. Exception detail: {0}", error);
584 }
585
586 public static Message UnavailableBundleConditionVariable(SourceLineNumber sourceLineNumbers, string elementName, string attributeName, string variable, string illegalValueList)
587 {
588 return Message(sourceLineNumbers, Ids.UnavailableBundleConditionVariable, "{0}/@{1} contains the built-in Variable '{2}', which is not available when it is evaluated. (Unavailable Variables are: {3}.). Rewrite the condition to avoid Variables that are never valid during its evaluation.", elementName, attributeName, variable, illegalValueList);
589 }
590
591 public static Message UnclearShortcut(SourceLineNumber sourceLineNumbers, string shortcutId, string fileId, string componentId)
592 {
593 return Message(sourceLineNumbers, Ids.UnclearShortcut, "Because it is an advertised shortcut, the target of shortcut '{0}' will be the keypath of component '{2}' rather than parent file '{1}'. To eliminate this warning, you can (1) make the Shortcut element a child of the File element that is the keypath of component '{2}', (2) make file '{1}' the keypath of component '{2}', or (3) remove the @Advertise attribute so the shortcut is a non-advertised shortcut.", shortcutId, fileId, componentId);
594 }
595
596 public static Message UnexpectedEntrySection(SourceLineNumber sourceLineNumbers, string sectionType, string expectedType)
597 {
598 return Message(sourceLineNumbers, Ids.UnexpectedEntrySection, "Found entry point <{0}> that does not match expected <{1}> output type. Verify that your source code is correct and matches the expected output type.", sectionType, expectedType);
599 }
600
601 public static Message UnexpectedTableInProduct(SourceLineNumber sourceLineNumbers, string tableName)
602 {
603 return Message(sourceLineNumbers, Ids.UnexpectedTableInProduct, "An unexpected row in the '{0}' table was found in this package. Packages should not contain the '{0}' table.", tableName);
604 }
605
606 public static Message UnknownAction(SourceLineNumber sourceLineNumbers, string sequenceTableName, string actionName)
607 {
608 return Message(sourceLineNumbers, Ids.UnknownAction, "The {0} table contains an action '{1}' which is not a known custom action, dialog, or standard action. This action will be left out of the decompiled output.", sequenceTableName, actionName);
609 }
610
611 public static Message UnknownPermission(SourceLineNumber sourceLineNumbers, string tableName, string primaryKey, int bitPosition) 64 public static Message UnknownPermission(SourceLineNumber sourceLineNumbers, string tableName, string primaryKey, int bitPosition)
612 { 65 {
613 return Message(sourceLineNumbers, Ids.UnknownPermission, "The {0} table contains a row with primary key '{1}' which has an unknown permission at bit {2}.", tableName, primaryKey, bitPosition); 66 return Message(sourceLineNumbers, Ids.UnknownPermission, "The {0} table contains a row with primary key '{1}' which has an unknown permission at bit {2}.", tableName, primaryKey, bitPosition);
614 } 67 }
615 68
616 public static Message UnrepresentableColumnValue(SourceLineNumber sourceLineNumbers, string tableName, string columnName, object value) 69 public static Message DownloadUrlNotSupportedForBAPayloads(SourceLineNumber sourceLineNumbers, string payloadId)
617 {
618 return Message(sourceLineNumbers, Ids.UnrepresentableColumnValue, "The {0}.{1} column's value, '{2}', cannot currently be represented in the WiX schema.", tableName, columnName, value);
619 }
620
621 public static Message UnsupportedCommandLineArgument(string arg)
622 {
623 return Message(null, Ids.UnsupportedCommandLineArgument, "'{0}' is not a valid command line argument.", arg);
624 }
625
626 public static Message UnsupportedCommandLineArgumentValue(string arg, string value, string fallback)
627 {
628 return Message(null, Ids.UnsupportedCommandLineArgument, "The value '{0}' is not a valid value for command line argument '{1}'. Using the value '{2}' instead.", value, arg, fallback);
629 }
630
631 public static Message UpdateOfNonKeyPathFile(string nonKeyPathFileId, string componentId, string keyPathFileId)
632 {
633 return Message(null, Ids.UpdateOfNonKeyPathFile, "File '{0}' in Component '{1}' was changed, but the KeyPath file '{2}' was not. This file will not be patched on the target system if the REINSTALLMODE does not contain 'A'. The KeyPath file should also be changed and included in your patch.", nonKeyPathFileId, componentId, keyPathFileId);
634 }
635
636 public static Message UxPayloadsOnlySupportEmbedding(SourceLineNumber sourceLineNumbers, string sourceFile)
637 {
638 return Message(sourceLineNumbers, Ids.UxPayloadsOnlySupportEmbedding, "A bootstrapper application or bundle extension payload ('{0}') was marked for something other than embedded packaging, possibly because it included a @DownloadUrl attribute. Bootstrapper application and bundle extension payloads must be embedded in the bundle, so the requested packaging is being ignored and the file is being embedded anyway.", sourceFile);
639 }
640
641 public static Message ValidationFailedDueToSystemPolicy()
642 {
643 return Message(null, Ids.ValidationFailedDueToSystemPolicy, "Validation could not run due to system policy. To eliminate this warning, run the process as admin or suppress ICE validation.");
644 }
645
646 public static Message ValidationWarning(SourceLineNumber sourceLineNumbers, string ice, string message)
647 {
648 return Message(sourceLineNumbers, Ids.ValidationWarning, "{0}: {1}", ice, message);
649 }
650
651 public static Message VariableDeclarationCollision(SourceLineNumber sourceLineNumbers, string variableName, string variableValue, string variableCollidingValue)
652 { 70 {
653 return Message(sourceLineNumbers, Ids.VariableDeclarationCollision, "The variable '{0}' with value '{1}' was previously declared with value '{2}'.", variableName, variableValue, variableCollidingValue); 71 return Message(sourceLineNumbers, Ids.DownloadUrlNotSupportedForBAPayloads, "The BootstrapperApplication Payload '{0}' included a @DownloadUrl attribute. BootstrapperApplication Payloads cannot be downloaded so the download URL is being ignored.", payloadId);
654 } 72 }
655 73
656 public static Message InvalidMsiProductVersion(SourceLineNumber sourceLineNumbers, string version, string package) 74 public static Message InvalidMsiProductVersion(SourceLineNumber sourceLineNumbers, string version, string package)
@@ -669,14 +87,10 @@ namespace WixToolset.Data
669 version); 87 version);
670 } 88 }
671 89
672 public static Message CollidingModularizationTypes(string tableName, string columnName, string foreignTableName, int foreignColumnNumber, string modularizationType, string foreignModularizationType) 90 public static Message SymbolNotTranslatedToOutput(IntermediateSymbol symbol)
673 {
674 return Message(null, Ids.CollidingModularizationTypes, "The definition for the '{0}' table's '{1}' column is a foreign key relationship to the '{2}' table's column number {3}. The modularization types of the two column definitions differ: table '{0}' uses type {4} and table '{2}' uses type {5}. Change one of the modularization types so that they match.", tableName, columnName, foreignTableName, foreignColumnNumber, modularizationType, foreignModularizationType);
675 }
676
677 public static Message InvalidEnvironmentVariable(string environmentVariable, string value, string defaultValue)
678 { 91 {
679 return Message(null, Ids.InvalidEnvironmentVariable, "The {0} environment variable is set to an invalid value of '{1}'. The default value '{2}' will be used instead.", environmentVariable, value, defaultValue); 92 var symbolString = $"SymbolName: '{symbol.Definition.Name}', Id: '{symbol.Id?.Id}'";
93 return Message(symbol.SourceLineNumbers, Ids.SymbolNotTranslatedToOutput, "The binder doesn't know how to place the following symbol into the output: {0}", symbolString);
680 } 94 }
681 95
682 public static Message WindowsInstallerFileTooLarge(SourceLineNumber sourceLineNumbers, string path, string fileDescription) 96 public static Message WindowsInstallerFileTooLarge(SourceLineNumber sourceLineNumbers, string path, string fileDescription)
@@ -689,154 +103,23 @@ namespace WixToolset.Data
689 return Message(sourceLineNumbers, Ids.WindowsInstallerFileTooLarge, "The Windows Installer does not support {0} files larger than 2GB in size. Reduce the size or number of files embedded in '{1}' or the installation will likely fail with an unexpected error.", fileDescription, path); 103 return Message(sourceLineNumbers, Ids.WindowsInstallerFileTooLarge, "The Windows Installer does not support {0} files larger than 2GB in size. Reduce the size or number of files embedded in '{1}' or the installation will likely fail with an unexpected error.", fileDescription, path);
690 } 104 }
691 105
692 public static Message InvalidWixVersion(SourceLineNumber sourceLineNumbers, string version, string elementName, string attributeName)
693 {
694 return Message(sourceLineNumbers, Ids.InvalidWixVersion, "Invalid WixVersion '{0}' in {1}/@'{2}'. Comparisons may yield unexpected results.", version, elementName, attributeName);
695 }
696
697 public static Message VBScriptIsDeprecated(SourceLineNumber sourceLineNumbers)
698 {
699 return Message(sourceLineNumbers, Ids.VBScriptIsDeprecated, "VBScript is a deprecated Windows component: https://learn.microsoft.com/en-us/windows/whats-new/deprecated-features. VBScript custom actions might fail on some Windows systems. Rewrite or eliminate VBScript custom actions for best compatibility.");
700 }
701
702 private static Message Message(SourceLineNumber sourceLineNumber, Ids id, string format, params object[] args) 106 private static Message Message(SourceLineNumber sourceLineNumber, Ids id, string format, params object[] args)
703 { 107 {
704 return new Message(sourceLineNumber, MessageLevel.Warning, (int)id, format, args); 108 return new Message(sourceLineNumber, MessageLevel.Warning, (int)id, format, args);
705 } 109 }
706 110
707 private static Message Message(SourceLineNumber sourceLineNumber, Ids id, ResourceManager resourceManager, string resourceName, params object[] args)
708 {
709 return new Message(sourceLineNumber, MessageLevel.Warning, (int)id, resourceManager, resourceName, args);
710 }
711
712 public enum Ids 111 public enum Ids
713 { 112 {
714 IdentifierCannotBeModularized = 1000,
715 EmptyAttributeValue = 1001,
716 UnableToFindFileFromCabOrImage = 1002,
717 CopyFileFileIdUseless = 1003,
718 NestedInstall = 1004,
719 OrphanedProgId = 1005,
720 PropertyUseless = 1006,
721 RemoveFileNameRequired = 1007,
722 SuppressAction = 1008,
723 SuppressMergedAction = 1009,
724 TargetDirCorrectedDefaultDir = 1010,
725 AccessDeniedForDeletion = 1011,
726 DirectoryInUse = 1012,
727 AccessDeniedForSettingAttributes = 1013,
728 UnknownAction = 1024,
729 IdentifierTooLong = 1026,
730 UnknownPermission = 1030, 113 UnknownPermission = 1030,
731 DirectoryRedundantNames = 1031,
732 UnableToResetAcls = 1032,
733 MediaExternalCabinetFilenameIllegal = 1033,
734 DeprecatedPreProcVariable = 1034,
735 FileSearchFileNameIssue = 1043,
736 AmbiguousFileOrDirectoryName = 1044,
737 PossiblyIncorrectTypelibVersion = 1048,
738 ImplicitComponentPrimaryFeature = 1049,
739 ActionSequenceCollision = 1050,
740 ActionSequenceCollision2 = 1051,
741 SuppressAction2 = 1052,
742 UnexpectedTableInProduct = 1053,
743 DeprecatedAttribute = 1054, 114 DeprecatedAttribute = 1054,
744 MergeRescheduledAction = 1055,
745 MergeTableFailed = 1056,
746 DecompiledStandardActionRelativelyScheduledInModule = 1057,
747 IllegalActionInSequence = 1058,
748 ExpectedForeignRow = 1059, 115 ExpectedForeignRow = 1059,
749 DecompilingAsCustomTable = 1060,
750 SkippingMergeModuleTable = 1062,
751 UnrepresentableColumnValue = 1064,
752 DeprecatedTable = 1065,
753 PatchTable = 1066,
754 IllegalColumnValue = 1067, 116 IllegalColumnValue = 1067,
755 DeprecatedLongNameAttribute = 1069,
756 GeneratedShortFileNameConflict = 1070,
757 GeneratedShortFileNameConflict2 = 1071,
758 DangerousTableInMergeModule = 1072,
759 DeprecatedLocalizationVariablePrefix = 1073,
760 PlaceholderValue = 1074,
761 MissingUpgradeCode = 1075,
762 ValidationWarning = 1076,
763 PropertyValueContainsPropertyReference = 1077,
764 DeprecatedUpgradeProperty = 1078,
765 EmptyCabinet = 1079,
766 DeprecatedRegistryElement = 1080,
767 IllegalRegistryKeyPath = 1081,
768 ProductIdAuthored = 1083,
769 ImplicitMergeModulePrimaryFeature = 1084,
770 DeprecatedIgnoreModularizationElement = 1085,
771 PropertyModularizationSuppressed = 1086,
772 DeprecatedPackageCompressedAttribute = 1087,
773 DeprecatedQuestionMarksGuid = 1090,
774 PackageCodeSet = 1091,
775 InvalidFourPartVersion = 1093,
776 InvalidRemoveFile = 1095,
777 PreprocessorWarning = 1096,
778 UpdateOfNonKeyPathFile = 1097,
779 UnsupportedCommandLineArgument = 1098,
780 MajorUpgradePatchNotRecommended = 1099,
781 RetainRangeMismatch = 1100,
782 DefaultLanguageUsedForVersionedFile = 1101,
783 DefaultLanguageUsedForUnversionedFile = 1102,
784 DefaultVersionUsedForUnversionedFile = 1103,
785 InvalidHigherInstallerVersionInModule = 1104,
786 ValidationFailedDueToSystemPolicy = 1105,
787 ColumnsIncompatibleWithInstallerVersion = 1106,
788 TableIncompatibleWithInstallerVersion = 1107,
789 DeprecatedCommandLineSwitch = 1108,
790 UnexpectedEntrySection = 1109,
791 NewComponentAddedToExistingFeature = 1110,
792 DeprecatedAttributeValue = 1111, 117 DeprecatedAttributeValue = 1111,
793 UnclearShortcut = 1113,
794 TooManyProgIds = 1114,
795 BadColumnDataIgnored = 1115,
796 NullMsiAssemblyNameValue = 1116,
797 InvalidAttributeCombination = 1117,
798 VariableDeclarationCollision = 1118,
799 DuplicatePrimaryKey = 1119,
800 RequiresMsi200for64bitPackage = 1121,
801 ExternalCabsAreNotSigned = 1122,
802 FailedToDeleteTempDir = 1123,
803 StandardDirectoryConflictInMergeModule = 1124,
804 PreprocessorUnknownPragma = 1125,
805 DeprecatedComponentGroupId = 1126,
806 UxPayloadsOnlySupportEmbedding = 1127,
807 DiscardedRollbackBoundary = 1129,
808 DeprecatedElement = 1130, 118 DeprecatedElement = 1130,
809 CannotUpdateCabCache = 1131,
810 DownloadUrlNotSupportedForBAPayloads = 1132, 119 DownloadUrlNotSupportedForBAPayloads = 1132,
811 DiscouragedAllUsersValue = 1133,
812 ImplicitlyPerUser = 1134,
813 PerUserButForcingPerMachine = 1135,
814 AttributeShouldContain = 1136,
815 DuplicateComponentGuidsMustHaveMutuallyExclusiveConditions = 1137,
816 DeprecatedRegistryKeyActionAttribute = 1138,
817 NotABinaryWixlib = 1139,
818 NoPerMachineDependencies = 1140,
819 DownloadUrlNotSupportedForAttachedContainers = 1141,
820 ReservedAttribute = 1142,
821 RequiresMsi500forArmPackage = 1143,
822 RemotePayloadsMustNotAlsoBeCompressed = 1144,
823 AllChangesIncludedInPatch = 1145,
824 RelatedAttributeConditionallyIgnored = 1146,
825 BackslashTerminateInlineDirectorySyntax = 1147,
826 InvalidMsiProductVersion = 1148, 120 InvalidMsiProductVersion = 1148,
827 ServiceConfigFamilyNotSupported = 1149,
828 SymbolNotTranslatedToOutput = 1150, 121 SymbolNotTranslatedToOutput = 1150,
829 MsiTransactionLimitations = 1151,
830 PathCanonicalized = 1152,
831 DetectConditionRecommended = 1153,
832 CollidingModularizationTypes = 1156,
833 InvalidEnvironmentVariable = 1157,
834 WindowsInstallerFileTooLarge = 1158, 122 WindowsInstallerFileTooLarge = 1158,
835 UnavailableBundleConditionVariable = 1159,
836 DiscardedRollbackBoundary2 = 1160,
837 ExePackageDetectInformationRecommended = 1161,
838 InvalidWixVersion = 1162,
839 VBScriptIsDeprecated = 1163,
840 } 123 }
841 } 124 }
842} 125}