David, always happy to help fellow MOSSers..

 

Unfortunately I do not have a blog, although it's perhaps time to start!
So if you have any suggestions for a good blog space let me know.  In
the mean time I'm happy to provide any assistance via email.

 

The screen shot I sent you, was just one of two custom web parts I
developed to provide the functionality for a user to edit his/her
profile.

 

1)       User Directory Web Part

This web part displays all users from the SharePoint user profile store
in a hierarchical tree view based on the organisations social hierarchy
(who a person reports too) and incorporates the "presence" icon as seen
in MOSS.  It has two views: Social Hierarchy View which displays users
from the top manager down in the organisation, and Alphabetical View,
displays users grouped into folders by first alphabet character of their
name. This web part allows a user to find people in the organisation and
to select a user to edit.

2)       User Directory Editor Web Part

This web part was designed to be used with the first web part in a
connected way, when a user is selected in the User Directory Web Part
the account name is sent to this web part to display the users details.
A user is always displayed in View mode first, and only those profile
properties for which the current user has permission to view will be
displayed.  If the user has rights to edit any properties of the
selected users profile, the Edit button will be enabled and they will be
able to edit fields for which they have permission.  This web part also
allows customisation of permissions by a site administrator, that is it
allows an administrator to define a list of profile properties that a
Manager is allowed to edit for other users. It also allows you to select
a SharePoint Group and give it permission to edit other users profiles
for selected properties. This can be useful in an organisation where a
specific business unit has responsibility for maintaining specific user
information for the department as users start/exit and move around a
department.  I almost forgot to mention but this web part also has the
ability to sync changes back to Active Directory, in fact it should work
with any LDAP directory as it uses the same Primary DataSource
Connection configured for the SSP in Central Admin. It does not support
updates of properties mapped to a secondary datasource such as the BDC.

 

The first web part took me about 4-5 weeks development effort. The
second web part was not a trivial task and has taken me about 3 months
effort as well as another developer I am training in MOSS development
about 3 weeks.

 

Hope that helps for now, and I will provide some insights into some of
the more interesting development issues I encountered while developing
this web part some time soon. I'll be in Sydney next week on a training
course so might try to blog about my encounters during this time.

 

Regards,

Justin Kleyn 
Solution Architect | MOSS Speacialist | Senior Consultant - Software
Development 
KAZ ACT | KAZ Group Pty Ltd 
19-25 Moore Street  |  Turner ACT 2612 
(02) 6219 0910  |  0439 472 998  |  Fax: (02) 6249 1620 
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>   |
www.kaz-group.com 
------------------------------------------------------------------------
----------------- 
This communication may contain confidential information and/or copyright
material of KAZ Group Pty Ltd ABN 25 002 124 405 and its related bodies
corporate.  It may also be the subject of legal professional privilege.
If you are not an intended recipient, you must not keep, forward, copy,
use, save or rely on this communication and any such action is
unauthorised and prohibited.  If you have received this communication in
error, please reply to this e-mail to notify the sender of its incorrect
delivery, and then delete both it and your reply.

________________________________

From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
Of Crabbe, David
Sent: Friday, 4 April 2008 1:30 PM
To: [email protected]
Subject: RE: [OzMOSS] Custom Edit Details (User Profile Properties) page
on MySites

 

Thanks Justin, I really appreciate your reply.

 

The custom profile editor you have created looks good.  Can you please
give me an indication of how long it took you to develop?  Any chance
the gotcha's and hidden gems involved in its development can be shared?
Do you have a blog? :)

 

David Crabbe

Consultant

Web Solutions Team

Fujitsu Australia Ltd

T: +61 8 9268 1505

E: [EMAIL PROTECTED]

 

________________________________

From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
Of Kleyn, Justin 
Sent: Friday, 4 April 2008 7:20 AM
To: [email protected]
Subject: RE: [OzMOSS] Custom Edit Details (User Profile Properties) page
on MySites

Hello David,

 

What you are trying to achieve is not possible using the out-of-the-box
functionality, here's why:

 

The EditProfile.aspx page uses a SharePoint control (ProfileEditor.ascx)
to display the user profile properties, this control does very little
other than set the following properties of the base control it inherits
from:

 

public ProfileEditor
<http://www.aisto.com/roeder/dotnet/Default.aspx?Target=code://Microsoft
.SharePoint.Portal:12.0.0.0:71e9bce111e9429c/Microsoft.SharePoint.Portal
.WebControls.ProfileEditor/.ctor()> ()
{
    base.ShowWarningIcon
<http://www.aisto.com/roeder/dotnet/Default.aspx?Target=code://Microsoft
.SharePoint.Portal:12.0.0.0:71e9bce111e9429c/Microsoft.SharePoint.Portal
.WebControls.ProfileUI/property:ShowWarningIcon:Boolean>  = true;
    base.RestrictUserEditable
<http://www.aisto.com/roeder/dotnet/Default.aspx?Target=code://Microsoft
.SharePoint.Portal:12.0.0.0:71e9bce111e9429c/Microsoft.SharePoint.Portal
.WebControls.ProfileUI/property:RestrictUserEditable:Boolean>  = true;
    base.MoveEditablePropertiesToTop
<http://www.aisto.com/roeder/dotnet/Default.aspx?Target=code://Microsoft
.SharePoint.Portal:12.0.0.0:71e9bce111e9429c/Microsoft.SharePoint.Portal
.WebControls.ProfileUI/property:MoveEditablePropertiesToTop:Boolean>  =
true;
    base.IsEditMode
<http://www.aisto.com/roeder/dotnet/Default.aspx?Target=code://Microsoft
.SharePoint.Portal:12.0.0.0:71e9bce111e9429c/Microsoft.SharePoint.Portal
.WebControls.ProfileUI/property:IsEditMode:Boolean>  = true;
    base.FirstPageElementId
<http://www.aisto.com/roeder/dotnet/Default.aspx?Target=code://Microsoft
.SharePoint.Portal:12.0.0.0:71e9bce111e9429c/Microsoft.SharePoint.Portal
.WebControls.ProfileUI/property:FirstPageElementId:String>  = "HBN100";
}

 

The base control is called ProfileUI.ascx and it is this control that
does all the work.  In fact the following controls are all derived from
this base control:

 

Microsoft.SharePoint.Portal.WebControls.ProfileAdminEditor

Microsoft.SharePoint.Portal.WebControls.ProfileAdminNew

Microsoft.SharePoint.Portal.WebControls.ProfileEditor

Microsoft.SharePoint.Portal.WebControls.ProfileViewer

 

These controls are merely wrappers for the base class that initialise
the properties of the base class to setup it's behaviour such as whether
to display in Edit mode or View mode.

 

The reason why you will not be able to modify this base classes
behaviour to display profile properties separately for each section, is
because it has a single method called "LoadProfileTable" that loads the
profile properties into an html table for display on the page. It loads
all profile properties into the table depending on the properties that
have been set by it's derived class.

Unfortunately this method is marked as internal and cannot be overridden
thus we are stuck with the default behaviour given to us by MOSS.

 

The only option available is to write your own custom code to display
and edit user profile properties, in fact I am just finalising the
development of a custom web part that does just that.  Let me say that
this is no trivial task as there are many factors to consider to
replicate the same behaviour in regards to maintaining the same security
that MOSS performs.  One of the challenges with developing a web part to
edit user profile properties was deciding which controls to use to
display the property to be edited, such as a Person, Url, Multivalue,
Choice types etc.  In my efforts, I have uncovered many hidden gems
(inbuilt SharePoint controls) that can be used to provide the same look
& feel and behaviour as the MOSS edit screens.

 

I have attached a screen shot of our custom web part that displays
profile properties for each section in a separate tab.

 

Regards,

Justin Kleyn 
Solution Architect | MOSS Speacialist | Senior Consultant - Software
Development 
KAZ ACT | KAZ Group Pty Ltd 
19-25 Moore Street  |  Turner ACT 2612 
(02) 6219 0910  |  0439 472 998  |  Fax: (02) 6249 1620 
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>   |
www.kaz-group.com 
------------------------------------------------------------------------
----------------- 
This communication may contain confidential information and/or copyright
material of KAZ Group Pty Ltd ABN 25 002 124 405 and its related bodies
corporate.  It may also be the subject of legal professional privilege.
If you are not an intended recipient, you must not keep, forward, copy,
use, save or rely on this communication and any such action is
unauthorised and prohibited.  If you have received this communication in
error, please reply to this e-mail to notify the sender of its incorrect
delivery, and then delete both it and your reply.

 

 




This is an email from Fujitsu Australia Limited, ABN 19 001 011 427. It
is confidential to the ordinary user of the email address to which it
was addressed and may contain copyright and/or legally privileged
information. No one else may read, print, store, copy or forward all or
any of it or its attachments. If you receive this email in error, please
return to sender. Thank you.
 
If you do not wish to receive commercial email messages from Fujitsu
Australia Limited, please email [EMAIL PROTECTED]

 

-------------------------------------------------------------------
OzMOSS.com - to unsubscribe from this list, send a message back to the
list with 'unsubscribe' as the subject.
Powered by mailenable.com



------------------------------------------------------------------- OzMOSS.com 
- to unsubscribe from this list, send a message back to the list with 
'unsubscribe' as the subject.

Powered by mailenable.com

Reply via email to