Article Index

New release of ProfileView

I've posted the source and binary for the latest release of my ProfileView ASP.NET server control. I was finally able to address the much requested fix to make the order of the properties displayed at runtime reflect the order they are declared in the web.config. Here are the release notes:



I tried to use your ProfileView webcontrol, but I don't know how (no tut, no sample...)
Here is what I did :

>%@ Register TagPrefix="FlimFlan" Namespace="FlimFlan.WebControls" Assembly="ProfileView" %<

>form id="profile01" runat="server"%lt;
>FlimFlan:ProfileView id="ProfileView01" runat="server" /%lt;

but it doesn't work... can you give some hint please.
Luc - January 09, 2006 02:18am
Close. In your Register directive, you need to set the "Assembly" attribute to the name of the assembly (the DLL, without extension) - not the name of the control. You specify the name of the control when you actually place the control. Example:

[%@ Register Assembly="FlimFlan.WebControls" Namespace="FlimFlan.WebControls" TagPrefix="flim" %]

[flim:profileview id="ProfileView1" runat="server"/]

(using square brackets instead of angle brackets)
Joshua Flanagan - January 09, 2006 07:10pm
Hi Joshua

I'm trying to use your control and have one question regarding it. I've three atrributes defined for my profile in the web.config, namely FirstName, LastName and PhoneNumber. The control is showing textboxes for First Name and Last Name, but nothing for Phone Number. Is there any way I can have it show additional controls for modifying additional profile information???

Nikhil - April 02, 2007 04:13pm
Regarding my earlier question, I had phone number as type int in the web.config, as soon as I changed it to string, it appeared in the ProfileView control.

so my next question is how can I've a Validator validate one of the textboxes, if it's possible to do so. Also, I would like to format the styling of the ProfileView control. Can it be done??


P.S - I just tried to peep inside ur source code. It's all VOODOO magic to me
Nikhil - April 02, 2007 04:49pm
Try setting the type of phone-number to "Int32" or "System.Int32" instead of "int". The control does not recognize "int" as a valid type, since it is not defined by the .NET Framework (it is defined as an alias inside the C# compiler).
The styling options are not as good as I would like. The control should render IDs and CSS class names on each of the tags. You should be able to add styles to each control by referencing those names and IDs in a stylesheet.
Joshua Flanagan - April 02, 2007 06:00pm
Some issues here:

1. When UserName property is set it does not re-render the control to update the profile values of that user. In fact it gets confused and makes a mess of it.

2. How would it go about re-rendering the whole control when the profile properties of the user (not just the values but the profile set) differs from the previous one?

I placed it in a page where I first select the application which then loads the users which is then used to set the username on the ProfileView. It just does not work. You can set the Username property but that is about it.
Emilio - April 14, 2007 07:25am
The UserName property was added as an afterthought, and it is now obvious it was not implemented correctly. The code needs to be changed so that the controls are re-built in the PreRender event, so that the updated state of internal values are reflected. I have not had any time to dedicated to this fix. The source code is available, so you are welcome to make the change, and I will repost it and give you credit.
Joshua Flanagan - April 15, 2007 08:59am