Mono Support Auto Add New Member to Group 

Viewed 16283 time(s), 6 post(s), 6/21/2014 11:06:21 PM - by JulianMummery
6/21/2014 11:06:21 PM
35 Reputation 4 Total posts

Hi,

I would like to automatically add all new members to a group.

The idea is that my site will only have one public group that will be one massive public wall.

The easiest way I can think of achieving this is by creating a trigger on the SQL Server database which will create the right links in the tables.

Can you think of an easier way to achieve this?

Thanks

1
6/22/2014 7:14:32 AM
15993 Reputation 2214 Total posts

Hi,

 Yes that is one option if you don't want to get into development.

BTW if you will have only one group and it will be public why use groups at all? Can you clarify a bit?

Regards

2
6/22/2014 2:51:38 PM
35 Reputation 4 Total posts

Hi Khorvat,

Thank you for your reply.

The reason I thought  that a group would be better is because I want everyone to automatically be friends with everyone else. e.g. 200 group members and then someone new registers and straight away has 200 friends as part of the group.

I could develop this myself but just wanted to save time really.

It mat help if I explain what I am trying to achieve in the long term.

I ultimately want my potential user base to be able to upload an images or images with optional comments so that it gets added to a never ending list of posts for everyone to see. So in effect it would be like one public wall where everybody is automatically friends with everyone else. Like a club if you like. At the moment the wall has comments as the main thing with an option of uploading a file. I would need it around the other way with it being mandatory that image(s) are used with optional comments. I guess that means getting down and dirty with the code which is fine but would I need to purchase a special licence in order to make these kind of changes.

Kind Regards

Julian 

3
6/22/2014 3:05:28 PM
35 Reputation 4 Total posts

Just seen the price of the source code edition. There is no way I can afford $2999 for what is a hobby project. Shame.

4
6/22/2014 4:08:27 PM
2218 Reputation 300 Total posts

Hello,

If your goal is to add only users to a group when registering you wouldn't need a source code license edition. For a start you would need to setup a custom based MonoX project and learn how to build custom web parts. Links for the relevant blog posts:
http://www.mono-software.com/blog/post/Mono/95/Building-a-custom-ASP-NET-project-based-on-MonoX/
http://www.mono-software.com/Blog/post/Mono/93/Building-a-custom-Web-part/

After you've read the following you should simply inherit the MonoX membership editor and add any post registration actions in there. I recommend registering an AccountCreationCompleted event handler and inserting custom logic in there.

protected override void OnInit(EventArgs e)
{
   base.OnInit(e);
   base.AccountCreationCompleted += new EventHandler(ctlMembership_AccountCreationCompleted);
}
   
void ctlMembership_AccountCreationCompleted(object sender, EventArgs e)
{
  // insert post account creation logic here
}
Regards,
Mario

5
6/22/2014 11:38:40 PM
35 Reputation 4 Total posts

Thank you :::Mzilic:::

I will look into that and let you know how I get on :) sounds like just the thing.

Kind Regards

Julian

6
This is a demo site for MonoX. Please visit Mono Software for more info.