Print this Page

GROUP Functions

Below is a listing of all the functions.

 

AddGroup

AddGroup

This function adds a group to the FuseTalk database.

 

Return Type: Integer

 

Name

Type

Description

GroupName

String

The name of the group.

ForumID

Integer

The ID of the forum.

SecurityContext

String

A comma-delimited list which contains the list of the security descriptors for the category.

 

Examples

Visual Basic.Net

'Method AddGroup

Result = ftObj.AddGroup("My New Group", ForumID, "")

 

C#

//Method AddGroup

Result = ftObj.AddGroup("My New Group", ForumID, "");

 

AddGroupToCategory

AddGroupToCategory

This function adds a group to the category security structure.

 

Return Type: n/a

 

Name

Type

Description

GroupID

Integer

 

CategoryID

Integer

The category ID the group will be added to.

 

Examples

Visual Basic.Net

'Method AddGroupToCategory

ftObj.AddGroupToCategory(MyGroup.ID, 1)

 

'Method GetCategoryGroups

Dim Permissons() As GroupPermission = ftObj.GetCategoryGroups(1)

If Not Permissons Is Nothing Then   

Dim Per As GroupPermission    

For Each Per In Permissons       

MsgBox(Per.Group.Name)   

Next

End If

 

'Method RemoveGroupFromCategory

ftObj.RemoveGroupFromCategory(MyGroup.ID, 1)

 

C#

//Method AddGroupToCategory

ftObj.AddGroupToCategory(MyGroup.ID, 1);

 

//Method GetCategoryGroups

FuseTalk.API.GroupPermission[] Permissons = ftObj.GetCategoryGroups(1);

if (Permissons != null)

{

foreach (FuseTalk.API.GroupPermission Per in Permissons)

{

Interaction.MsgBox(Per.Group.Name, 0, null);

}

}

 

//Method RemoveGroupFromCategory

ftObj.RemoveGroupFromCategory(MyGroup.ID, 1);

 

AddGroupUser

AddGroupUser

This function will add a user to a group.

 

Return Type: Integer

 

Name

Type

Description

GroupID

Integer

The group ID of the group.

ForumID

Integer

The ID of the forum.

UserName

String

The name of the user you want to add to the group.

 

Examples

Visual Basic.Net

'Method AddGroupUser

Result = ftObj.AddGroupUser(MyGroup.ID, ForumID, User.Username)

If Result  0 Then MsgBox(Result)

 

C#

//Method AddGroupUser

Result = ftObj.AddGroupUser(MyGroup.ID, ForumID, User.Username);

if (Result != 0)

{

Interaction.MsgBox(Result, 0, null);

}

 

DeleteGroup

DeleteGroup

This function will delete a group from the FuseTalk database.

 

Return Type: n/a

 

Name

Type

Description

GroupID

Integer

The group ID of the group you wish to delete.

 

Examples

Visual Basic.Net

'Method DeleteGroup

ftObj.DeleteGroup(MyGroup.ID)

 

C#

//Method DeleteGroup

ftObj.DeleteGroup(MyGroup.ID);

 

DeleteUserFromGroup

DeleteUserFromGroup

This function will remove a user from a group.

 

Return Type: n/a

 

Name

Type

Description

GroupID

Integer

The group ID of the group.

UserID

Integer

The ID of the forum.

 

GetCategoryGroups

GetCategoryGroups

Get all the groups that are tagged to the category.

 

Return Type:  GroupPermission()

 

Name

Type

Description

CategoryID

Integer

The category ID you want to get the groups for.

 

Examples

Visual Basic.Net

'Method AddGroupToCategory

ftObj.AddGroupToCategory(MyGroup.ID, 1)

 

'Method GetCategoryGroups

Dim Permissons() As GroupPermission = ftObj.GetCategoryGroups(1)

If Not Permissons Is Nothing Then

   Dim Per As GroupPermission

   For Each Per In Permissons

       MsgBox(Per.Group.Name)

   Next

End If

 

'Method RemoveGroupFromCategory

ftObj.RemoveGroupFromCategory(MyGroup.ID, 1)

 

C#

//Method AddGroupToCategory

ftObj.AddGroupToCategory(MyGroup.ID, 1);

 

//Method GetCategoryGroups

FuseTalk.API.GroupPermission[] Permissons = ftObj.GetCategoryGroups(1);

if (Permissons != null)

{

foreach (FuseTalk.API.GroupPermission Per in Permissons)

{

Interaction.MsgBox(Per.Group.Name, 0, null);

}

}

 

//Method RemoveGroupFromCategory

ftObj.RemoveGroupFromCategory(MyGroup.ID, 1);

 

GetGroup

GetGroup

This function will get a group based on a group ID.

 

Return Type:  Group

 

Name

Type

Description

GroupID

Integer

The group ID of the group you wish to get.

 

Examples

Visual Basic.Net

'Method GetGroup

Dim MyGroup As Group = ftObj.GetGroup(MyGroupID)

 

C#

//Method GetGroup

FuseTalk.API.Group MyGroup = ftObj.GetGroup(MyGroupID);

 

Related Items

GetCategoryGroups, GetGroups, GetGroupUsers, GetForumGroupings, GetAllForumGroupings, GetAllGroupings, GetGrouping

 

GetGroupIDByName

GetGroupIDByName

Get the group ID of a group name.

 

Return Type: Integer

 

Name

Type

Description

GroupName

String

The name of the group.

ForumID

Integer

The ID of the forum the group belongs to.

 

Examples

Visual Basic.Net

'Method GetGroupIDByName

Dim MyGroupID As Integer = ftObj.GetGroupIDByName("My New Group", ForumID)

 

C#

//Method GetGroupIDByName

int MyGroupID = ftObj.GetGroupIDByName("My New Group", ForumID);

 

GetGroups

GetGroups

This function gets all the groups for a forum.

 

Return Type:  Group()

 

Name

Type

Description

ForumID

Integer

The ID of the forum. Put a 0 if you want to retrieve global groups.

 

Examples

Visual Basic.Net

'Method GetGroups

Dim Groups As Group() = ftObj.GetGroups(ForumID)

Dim Group As Group

For Each Group In Groups    

MsgBox(Group.ID & ": " & Group.Name & " - " & Group.Security)

Next

 

C#

//Method GetGroups FuseTalk.API.Group[] Groups = ftObj.GetGroups(ForumID);

foreach (FuseTalk.API.Group Group in Groups)

{

Interaction.MsgBox(Group.ID + ": " + Group.Name + " - " + Group.Security, 0, null);

}

 

Related Items

GetCategoryGroups, GetGroupUsers, GetGroup, GetForumGroupings, GetAllForumGroupings, GetAllGroupings, GetGrouping

 

GetGroupsForUser

GetGroupsForUser

This function gets all the groups for a user.

 

Return Type: String

 

Name

Type

Description

UserID

Integer

The ID of the user.

ForumID

Integer

The ID of the forum the user belongs to.

 

Examples

Visual Basic.Net

'Method GetGroupsForUser

Dim SecurityRights As String = ftObj.GetGroupsForUser(User.ID, ForumID) MsgBox(SecurityRights)

 

C#

//Method GetGroupsForUser

string SecurityRights = ftObj.GetGroupsForUser(User.ID, ForumID); Interaction.MsgBox(SecurityRights, 0, null);

 

GetGroupUsers

GetGroupUsers

This function will get a listing of all users for a group.

 

Return Type:  GroupUser()

 

Name

Type

Description

GroupID

Integer

The group ID of the group.

 

Examples

Visual Basic.Net

'Method GetGroupUsers

Dim GroupUsers As GroupUser() = ftObj.GetGroupUsers(MyGroup.ID)

Dim gUser As GroupUser

For Each gUser In GroupUsers    

MsgBox(gUser.ftUser.Username)

Next

 

C#

//Method GetGroupUsers

FuseTalk.API.GroupUser[] GroupUsers = ftObj.GetGroupUsers(MyGroup.ID);

foreach (FuseTalk.API.GroupUser gUser in GroupUsers)

{

Interaction.MsgBox(gUser.ftUser.Username, 0, null);

}

 

RemoveGroupFromCategory

RemoveGroupFromCategory

Removes a group from a category.

 

Return Type: n/a

 

Name

Type

Description

GroupID

Integer

The group ID you want to remove.

CategoryID

Integer

The category ID the group you are removing belongs to.

 

Examples

Visual Basic.Net

'Method AddGroupToCategory

ftObj.AddGroupToCategory(MyGroup.ID, 1)

 

'Method GetCategoryGroups

Dim Permissons() As GroupPermission = ftObj.GetCategoryGroups(1)

If Not Permissons Is Nothing Then   

Dim Per As GroupPermission    

For Each Per In Permissons       

MsgBox(Per.Group.Name)   

Next

End If

 

'Method RemoveGroupFromCategory

ftObj.RemoveGroupFromCategory(MyGroup.ID, 1)

 

C#

//Method AddGroupToCategory

ftObj.AddGroupToCategory(MyGroup.ID, 1);

 

//Method GetCategoryGroups

FuseTalk.API.GroupPermission[] Permissons = ftObj.GetCategoryGroups(1);

if (Permissons != null)

{

foreach (FuseTalk.API.GroupPermission Per in Permissons)

{

Interaction.MsgBox(Per.Group.Name, 0, null);

}

}

 

//Method RemoveGroupFromCategory

ftObj.RemoveGroupFromCategory(MyGroup.ID, 1);

 

UpdateGroup

UpdateGroup

This function will update a group from the FuseTalk database.

 

Return Type: n/a

 

Name

Type

Description

GroupName

String

The name of the group.

GroupID

Integer

The group ID of the group you wish to update.

ForumID

Integer

The ID of the forum.

SecurityContext

String

A comma-delimited list which contains the list of the security descriptors for the category.

 

Examples

Visual Basic.Net

'Method UpdateGroup

ftObj.UpdateGroup("New Group Name", MyGroup.ID, ForumID, "")

 

C#

//Method UpdateGroup

ftObj.UpdateGroup("New Group Name", MyGroup.ID, ForumID, "");