AddCatalogRelationship Method (String, String, String, String, String, Int32, String, Decimal, Int32)
Add a CatalogRelationship to this CatalogRelationshipsDataSet and return a CatalogRelationshipsDataSet..::.CatalogRelationship.
Namespace: Microsoft.CommerceServer.Catalog
Assembly: Microsoft.CommerceServer.Catalog (in Microsoft.CommerceServer.Catalog.dll)
Syntax
'Declaration
Public Function AddCatalogRelationship ( _
TargetCatalogName As String, _
TargetProductId As String, _
TargetCategoryName As String, _
RelationshipName As String, _
RelationshipDescription As String, _
Rank As Integer, _
DisplayName As String, _
ListPrice As Decimal, _
CatalogClassTypes As Integer _
) As CatalogRelationshipsDataSet..::.CatalogRelationship
'Usage
Dim instance As CatalogRelationshipsDataSet..::.CatalogRelationshipsDataTable
Dim TargetCatalogName As String
Dim TargetProductId As String
Dim TargetCategoryName As String
Dim RelationshipName As String
Dim RelationshipDescription As String
Dim Rank As Integer
Dim DisplayName As String
Dim ListPrice As Decimal
Dim CatalogClassTypes As Integer
Dim returnValue As CatalogRelationshipsDataSet..::.CatalogRelationship
returnValue = instance.AddCatalogRelationship(TargetCatalogName, _
TargetProductId, TargetCategoryName, _
RelationshipName, RelationshipDescription, _
Rank, DisplayName, ListPrice, CatalogClassTypes)
public CatalogRelationshipsDataSet..::.CatalogRelationship AddCatalogRelationship(
string TargetCatalogName,
string TargetProductId,
string TargetCategoryName,
string RelationshipName,
string RelationshipDescription,
int Rank,
string DisplayName,
decimal ListPrice,
int CatalogClassTypes
)
public:
CatalogRelationshipsDataSet..::.CatalogRelationship^ AddCatalogRelationship(
String^ TargetCatalogName,
String^ TargetProductId,
String^ TargetCategoryName,
String^ RelationshipName,
String^ RelationshipDescription,
int Rank,
String^ DisplayName,
Decimal ListPrice,
int CatalogClassTypes
)
public function AddCatalogRelationship(
TargetCatalogName : String,
TargetProductId : String,
TargetCategoryName : String,
RelationshipName : String,
RelationshipDescription : String,
Rank : int,
DisplayName : String,
ListPrice : decimal,
CatalogClassTypes : int
) : CatalogRelationshipsDataSet..::.CatalogRelationship
Parameters
- TargetCatalogName
Type: System..::.String
Catalog name of the target category.
- TargetProductId
Type: System..::.String
ProductId of the target product.
- TargetCategoryName
Type: System..::.String
Category name of the target category.
- RelationshipName
Type: System..::.String
Name of this relationship.
- RelationshipDescription
Type: System..::.String
Description of this relationship.
- Rank
Type: System..::.Int32
The order of sibling entities in the product catalog system with respect to their container
- DisplayName
Type: System..::.String
Display name for this product
- ListPrice
Type: System..::.Decimal
List Price for this product.
- CatalogClassTypes
Type: System..::.Int32
The type of catalog.
Return Value
Type: Microsoft.CommerceServer.Catalog..::.CatalogRelationshipsDataSet..::.CatalogRelationship
A CatalogRelationshipsDataSet..::.CatalogRelationship containing the added item.
Remarks
Prioritizing, ordering, or sequencing may involve using the Rank Property. Positive and negative rank values are allowed in the catalog system.
The CatalogRelationshipsDataSet object must be saved before these changes will be persisted to the database.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
CatalogRelationshipsDataSet..::.CatalogRelationshipsDataTable Class
CatalogRelationshipsDataSet..::.CatalogRelationshipsDataTable Members