|
britneyssssers wrote: User.Identity works when you have passport credentials
It is not only for Passport. Windows authentication also uses this. In fact I've never built a site that uses Passport authentication. Has anyone else? (I'm curous)
britneyssssers wrote: a easy solution is to make a manual authentication of the user ID y password against to database
An easy solution would be to use the built in functionality provided by the asp.net framework and add entries in the web.config to authenticate against. This is much easier than creating a database, tables and proceduces and the necessary overhead to use it.
only two letters away from being an asset
|
|
|
|
|
Hi all,
Any body know GOF Design patterns
Softy Boy
|
|
|
|
|
softy_boy wrote: Any body know GOF Design patterns
Yes.
|
|
|
|
|
lol colin,
yep me too.
g00fy
|
|
|
|
|
Yep, and a few others, like the Rube Goldberg pattern used by the last client.
only two letters away from being an asset
|
|
|
|
|
pls tell me on my mail id
g_parwez@rediffmail.com
g_parwez@yahoo.com
Softy Boy
|
|
|
|
|
Hi Friends,
I m using 1 session variable like this
Session["fullname"]="ABC";
then I pass this value to a class let say in which the FullName Property is declared with Public static key words
SessionInfo.FullName=Session[""].ToString();
It works fine for one user
but when i run two sessions what happens is
if Mr. "A" is already logged on the web site and after Mr. "A", Mr."B" logs in.
the name of Mr."A" changes to Mr."B" and on both browswer windows now name is Mr."B".
Would you please help me , where i am wrong?
Please if you do not understand my problem, do ask me.
thansk
Naveed Kamboh
|
|
|
|
|
the property is static, that is the problem
why do you not just access the session var, rather than store it in another class?
else you will need to get complicated, if you want to keep the property static and keep an IDictionary<sessionId, propertyValue> in the object and return the appropriate value for the users session.
other option, *cleaner* than static property, but less clean that just accessing session var, is to create an instance object for each session like.
new SessionInfo().FullName = Session["fullname"] as String;
hope this helps
g00fy
|
|
|
|
|
How can I change the color and style of an asp.net form?
Regards,
Thomas
|
|
|
|
|
|
How can I make an multilanguge application in asp.net ?
,,,,,,,,,,,,,,,,,,.................,,,,,,,,,,,,
|
|
|
|
|
|
|
Hi *.*,
I've got a user-control with 3 Dropdowns, A, B and C. If the user selects something in A, the content of B should change depending on the value selected in A. I sure could do that by reposting the page on every selection change. What I'd rather do is to send all possible values wrapped up in some javascript to the client. Can somebody give me a starting point on how to cope with this?
-> How do I attach Javascript to the Dropdowns change event?
-> How to send all values to the client?
thanks in advance!
/matthias
I love deadlines. I like the whooshing sound they make as they fly by. [Douglas Adams]
|
|
|
|
|
i would use ajax for this, if this is not possible then look here,
http://javascriptkit.com/script/script2/multiplecombo.shtml
plenty of e.g's on that site
hope that helps,
g00fy
|
|
|
|
|
I am having a problem with a asp:menu 2.0 control. When I set up the control to use an XmlDataSource the postback event doesn't fire for all the menu items. i.e. I have a OnMenuItemClick event, but it only fires for the items under the first menu entry. Here is the aspx markup:
<asp:Menu ID="mnuMain" runat="server" Orientation="Horizontal" OnMenuItemClick="mnuMain_MenuItemClick" DataSourceID="xmldsMenu">
<DataBindings>
<asp:MenuItemBinding DataMember="MenuNode" NavigateUrlField="url" TextField="title" ValueField="value" />
<asp:MenuItemBinding DataMember="MenuNode" NavigateUrlField="url" TextField="title" ValueField="value" />
</DataBindings>
</asp:Menu>
<asp:XmlDataSource ID="xmldsMenu" runat="server" DataFile="menu.xml" XPath="/MapHomeNode/MenuNode">
</asp:XmlDataSource>
-- modified at 7:15 Wednesday 6th September, 2006
|
|
|
|
|
Hi there. What does your xml file look like?
|
|
|
|
|
hi all,
i am converting my custom control from a flow layout to a more configurable layout using div's (System.Web.UI.WebControls.Panel ). The control has a couple of buttons on it that work fine if i just render them within the custom control and not put them in another controls control collection.
As soon as i put the button/s into another controls control collection, the events dont fire. I have created a class WebPanel that extends Panel and implements INamingContainer but that doesn't help either. The same problem occurs also if I use a Table instead of a Panel
this is my overriden OnBubbleEvent
protected override bool OnBubbleEvent(object source, EventArgs e)
{
if (e is CommandEventArgs)
{
CommandEventArgs e1 = (CommandEventArgs)e;
Button button = source as Button;
OnClick(this, new ButtonEventArgs(button));
return false;
}
return true;
}
this is my overriden CreateChildControls
protected override void CreateChildControls()
{
Controls.Clear();
Button button = new Button();
button.Text = "Button1";
button.CommandArgument = "Button1";
this.Buttons.Add(button);
}
btw, this.Buttons is a custom ButtonCollection that has a ButtonAdded event, which adds the Button to the Controls collection
This renders & events fire
protected override void Render(HtmlTextWriter writer)
{
EnsureChildControls();
foreach (Button button in Buttons)
{
button.RenderControl(writer);
}
}
This renders & event *dont* fire
protected override void Render(HtmlTextWriter writer)
{
EnsureChildControls();
Panel container = new Panel();
Controls.Add(container);
foreach (Button button in Buttons)
{
container.Controls.Add(button);
}
container.RenderControl(writer);
}
Any ideas please.
g00fy
|
|
|
|
|
Hello
first you should be implements inamingcontainer class
Implements INamingContainer
Softy Boy
|
|
|
|
|
thanks for the reply
but ... i am implementing that else it would not fire the event when *not* contained within the control collection of the other control.
regards,
g00fy
|
|
|
|
|
hello,
pls check object scope, it's mean i think it's not live in memory still raising events of control.
Softy Boy
|
|
|
|
|
Hi there,
Can you try to explicitly specify the ID property for the button control in the CreateChildControls method?
|
|
|
|
|
tried that and it is the same problem
thanks for the reply
goofy
|
|
|
|
|
IMO, in this case the ids of the dynamic buttons are different when the parent control is rendered and when it is created on postback. And as a result of this, the postback event cannot be routed to the button's Command event. You can try debugging your application and double check the ID property of the dynamic buttons and see if this is the case.
|
|
|
|
|
i will try that now,
not sure if this helps but the following code produces two lines of buttons and neither fire the event, normally the button.RenderControl(writer); LOC would fire but as soon as i add the button to a controls control collection it failes everywhere
protected override void Render(HtmlTextWriter writer)
{
EnsureChildControls();
Panel container = new Panel();
foreach (Button button in Buttons)
{
button.RenderControl(writer);
container.Controls.Add(button);
}
container.RenderControl(writer);
}
am debugging extensively as we speak
thank you
g00fy
|
|
|
|