IResourceWriter::AddResource Method (String^, Object^)

 

Adds a named resource of type Object to the list of resources to be written.

Namespace:   System.Resources
Assembly:  mscorlib (in mscorlib.dll)

void AddResource(
	String^ name,
	Object^ value
)

Parameters

name
Type: System::String^

The name of the resource.

value
Type: System::Object^

The value of the resource.

Exception Condition
ArgumentNullException

The name parameter is null.

The resource is not written until the Generate method is called.

System_CAPS_noteNote

value might have to be serializable, so you might have to provide a type converter, depending on which resource writer is used.

.NET Framework
Available since 1.1
Return to top
Show: