61 references to Format
System.Xaml (61)
src\Microsoft.DotNet.Wpf\src\Shared\MS\Utility\FrugalList.cs (6)
334throw new ArgumentException(SR.Format(SR.FrugalList_TargetMapCannotHoldAllData, oldList.ToString(), this.ToString()), nameof(oldList)); 608throw new ArgumentException(SR.Format(SR.FrugalList_TargetMapCannotHoldAllData, oldList.ToString(), this.ToString()), nameof(oldList)); 1081throw new ArgumentException(SR.Format(SR.FrugalList_TargetMapCannotHoldAllData, oldList.ToString(), this.ToString()), nameof(oldList)); 1120throw new ArgumentException(SR.Format(SR.FrugalList_TargetMapCannotHoldAllData, oldList.ToString(), this.ToString()), nameof(oldList)); 1405throw new ArgumentException(SR.Format(SR.FrugalList_TargetMapCannotHoldAllData, oldList.ToString(), this.ToString()), nameof(oldList)); 1480throw new ArgumentException(SR.Format(SR.FrugalList_TargetMapCannotHoldAllData, oldList.ToString(), this.ToString()), nameof(oldList));
src\Microsoft.DotNet.Wpf\src\Shared\System\Windows\Markup\ReflectionHelper.cs (1)
431throw new InvalidOperationException(SR.Format(SR.ParserAssemblyLoadVersionMismatch, request, found));
System\Windows\Markup\StaticExtension.cs (1)
86throw new ArgumentException(SR.Format(SR.MarkupExtensionNoContext, GetType().Name, nameof(IXamlTypeResolver)));
System\Windows\Markup\StaticExtensionsToInstanceDescriptorsConverter.cs (1)
34throw new ArgumentException(SR.Format(SR.MustBeOfType, nameof(value), nameof(StaticExtension)));
System\Windows\Markup\TypeExtension.cs (1)
73throw new InvalidOperationException(SR.Format(SR.MarkupExtensionNoContext, GetType().Name, nameof(IXamlTypeResolver)));
System\Windows\Markup\TypeExtensionConverter.cs (1)
34throw new ArgumentException(SR.Format(SR.MustBeOfType, nameof(value), nameof(TypeExtension)));
System\Windows\Markup\ValueSerializer.cs (1)
266return new NotSupportedException(SR.Format(SR.ConvertFromException, base.GetType().Name, text));
System\Xaml\Context\NameFixupGraph.cs (1)
491exceptionMessage.Append(SR.Format(SR.LineNumberOnly, meName, token.LineNumber));
System\Xaml\Context\ObjectWriterContext.cs (1)
319throw new ArgumentException(SR.Format(SR.NotAmbientProperty, xamlMember.DeclaringType.Name, xamlMember.Name), nameof(properties));
System\Xaml\InfosetObjects\DeferredWriter.cs (7)
104throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), methodName)); 133throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), "WriteEndObject")); 161throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), "WriteMember")); 182throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), "WriteEndMember")); 220throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), "WriteValue")); 245throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), "WriteNamespace")); 301throw new XamlInternalException(SR.Format(SR.MissingCase, _mode.ToString(), nameof(SetLineInfo)));
System\Xaml\InfosetObjects\XamlObjectWriter.cs (11)
305_context.CurrentInstance = inst ?? throw _context.WithLineInfo(new XamlObjectWriterException(SR.Format(SR.GetObjectNull, parentInstance.GetType(), parentProperty.Name))); 346string err = SR.Format(SR.NoPropertyInCurrentFrame_SO, xamlType.ToString(), 375throw new XamlParseException(SR.Format(SR.CantAssignRootInstance, 421string err = SR.Format(SR.OpenPropertyInCurrentFrame_EO, _context.CurrentType.ToString(), 832? SR.Format(SR.NoPropertyInCurrentFrame_V, value, _context.CurrentType.ToString()) 1066throw new InvalidOperationException(SR.Format(SR.ObjectWriterTypeNotAllowed, 1167throw ctx.WithLineInfo(new XamlObjectWriterException(SR.Format(SR.CannotResolveTypeForFactoryMethod, ownerTypeName, propertyName.Name))); 1178throw ctx.WithLineInfo(new XamlObjectWriterException(SR.Format(SR.NotAssignableFrom, currentType.GetQualifiedName(), instType.GetQualifiedName()))); 1299string err = SR.Format(SR.TypeConverterFailed, targetName, value); 2199throw ctx.WithLineInfo(new XamlObjectWriterException(SR.Format(SR.XClassMustMatchRootInstance, className, rootInstanceType.FullName))); 2329exceptionMessage.Append(SR.Format(SR.LineNumberOnly, string.Empty, token.LineNumber));
System\Xaml\MS\Impl\XmlNsInfo.cs (4)
279throw new XamlSchemaException(SR.Format(SR.BadInternalsVisibleTo2, assemblyName, assembly.FullName), ex); 284throw new XamlSchemaException(SR.Format(SR.BadInternalsVisibleTo2, assemblyName, assembly.FullName), ex); 334throw new XamlSchemaException(SR.Format(SR.DuplicateXmlnsCompat, assembly.FullName, oldns)); 454throw new XamlSchemaException(SR.Format(SR.XmlnsCompatCycle, assembly.FullName, ns));
System\Xaml\Parser\GenericTypeNameParser.cs (1)
253throw new TypeNameParserException(SR.Format(SR.InvalidCharInTypeName, _scanner.ErrorCurrentChar, _inputText));
System\Xaml\Parser\MePullParser.cs (1)
417error = SR.Format(SR.MissingComma2, _context.CurrentMember.Name, _tokenizer.TokenText);
System\Xaml\Parser\XamlPullParser.cs (1)
1198: base(xamlScanner, SR.Format(SR.UnexpectedNodeType, nodetype.ToString(), parseRule)) { }
System\Xaml\Runtime\ClrObjectRuntime.cs (6)
79throw CreateException((SR.Format(SR.CannotResolveTypeForFactoryMethod, xamlType, methodName))); 167throw CreateException(SR.Format(SR.TypeConverterFailed2, instance, typeof(string)), ex); 183throw CreateException(SR.Format(SR.CanConvertFromFailed, typeof(T), converter.GetType()), ex); 199throw CreateException(SR.Format(SR.CanConvertToFailed, type, converter.GetType()), ex); 215throw CreateException(SR.Format(SR.TypeConverterFailed2, instance, typeof(string)), ex); 231throw CreateException(SR.Format(SR.TypeConverterFailed2, instance, typeof(T)), ex);
System\Xaml\Schema\TypeReflector.cs (1)
1058string message = SR.Format(SR.TooManyAttributesOnType,
System\Xaml\Schema\XamlTypeInvoker.cs (2)
92throw new XamlSchemaException(SR.Format(SR.NoAddMethodFound, _xamlType, itemType)); 124throw new XamlSchemaException(SR.Format(SR.NoAddMethodFound, _xamlType, itemType));
System\Xaml\Schema\XamlValueConverter.cs (1)
82throw new XamlSchemaException(SR.Format(SR.ConverterMustDeriveFromBase,
System\Xaml\XamlException.cs (2)
50return SR.Format(SR.LineNumberOnly, base.Message, LineNumber); 150: base(SR.Format(SR.DuplicateMemberSet, (member != null) ? member.Name : null, (type != null) ? type.Name : null))
System\Xaml\XamlObjectReader.cs (6)
919throw new InvalidOperationException(SR.Format(SR.AttachedPropertyOnDictionaryKey, value.ToString(), props[0].Key.ToString())); 1291throw new XamlObjectReaderException(SR.Format(SR.ObjectReaderInstanceDescriptorIncompatibleArgumentTypes, "null", parameterInfo.ParameterType)); 1297throw new XamlObjectReaderException(SR.Format(SR.ObjectReaderInstanceDescriptorIncompatibleArgumentTypes, argument.GetType(), parameterInfo.ParameterType)); 1880throw new XamlObjectReaderException(SR.Format(SR.ObjectReaderAttachedPropertyNotFound, owningType, ap.Key.MemberName)); 2135throw new XamlObjectReaderException(SR.Format(SR.ObjectReaderXamlNamePropertyMustBeString, property.Name, property.DeclaringType)); 2632throw new XamlObjectReaderException(SR.Format(SR.ObjectReaderTypeNotAllowed,
System\Xaml\XamlType.cs (1)
1596throw new XamlSchemaException(SR.Format(SR.MarkupExtensionWithDuplicateArity, UnderlyingType, typeVector.Length));
System\Xaml\XamlXmlWriter.cs (3)
1276throw new InvalidOperationException(SR.Format(SR.WhiteSpaceInCollection, value, containingXamlType.Name)); 1316throw new XamlXmlWriterException(SR.Format(SR.CannotWriteXmlSpacePreserveOnMember, frameWithXmlSpacePreserve.Member, value)); 1474throw new InvalidOperationException(SR.Format(SR.WhiteSpaceInCollection, writer.deferredValue, containingXamlType.Name));