|
The index page on a website i'm designing contains a menu for, well, navigation. My question is what is the best route to dynamically set the menu's SiteMapProvider to the correct provider based on a users login credentials.
Nathan Lindley
|
|
|
|
|
Hi
I have built 2 .net user controls and placed them both on the same page. One control (headlinedisplay.ascx) displays headlines from a webservice and the other displays the full article of a headline when you click on a headline links in the first usercontrol(articleDisplay.ascx).
I am displaying the headlines from headlinedisplay by progamatically creating asp/html controls. The problem I have is that when I click on a headline(linkbutton) and the Articleclick event fires to render the article the headlines in the headlinedisplay user control dissapear becuase of the post back. I think this happens because the controls were created dynamically and I need to redraw them. (If I through the data into a datalist this doesnt happen but leads to other problems so i cant really use that as a solution)
Does anybody know of away around this?
thanks for your help,
|
|
|
|
|
There is no way around it. If you create controls dynamically, you have to create them every time the page is created.
---
b { font-weight: normal; }
|
|
|
|
|
Guffa,
thanks for the reply. I kind of figured that. I guess I will store the response from the webservice in a session vaiable and then just redisplay the headlines on postback.
|
|
|
|
|
Hello,
I want to add nodes to Asp.Net 2.0 SiteMapPath in my runtime code.
I did as follows:
' Create site map path node collection
Dim siteMapPathNodeCollection As SiteMapNodeCollection
' Add node
siteMapPathNodeCollection.Add(New SiteMapNode(...))
My problem is I am ask to insert a 'provider' in SiteMapNode. I don't get it.
I have a data view with various rows and 2 columns 'Title' and 'Url'.
All I want is add these rows values to my site map path.
I was trying to loop through each row in my dataview but I am getting this problem with the provider.
Can someone sugest me how to do this?
Thanks,
Miguel
|
|
|
|
|
Take a look at this:
XmlAttributeCollection attrColl = myElement.Attributes;<br />
<br />
Console.WriteLine("Display all the attributes in the collection...");<br />
for (int i = 0; i < attrColl.Count; i++)<br />
{<br />
Console.Write("{0} = ", attrColl[i].Name);<br />
Console.Write("{0}", attrColl[i].Value);<br />
Console.WriteLine();<br />
}
It is in C#, but I am sure, you can translate it to VB
Sincerely,
Elina
Life is great!!!
Enjoy every moment of it!
|
|
|
|
|
Hi
I am a web developer currently teaching myself ASP.NET 2.0 (in c#) with MySQL (rare combination, but still viable?). Getting ASP.NET & MySQL to work together at first was difficult, but now I understand the basics most code catered towards MS SQL can be altered to work with MySQL.
I mainly create bespoke content management systems for clients, so even though my knowledge is quite weak I am still putting it to regular use and constantly learning new things. I keep coming up against silly bugs/problems, or am having to write an awful lot of code (sometimes snippets twice) because I am not clued up on the best practices as I am essentially just making it up as I go along.
The tutorials and articles here are generally useful, but can sometimes be written crudely as they will only serve one purpose and no point in confusing someone by overcomplicating the methods. Alot of resources out there are catered towards 1.0 and 1.1 - when an awful lot changed in 2.0.
When I was learning PHP it was a great help to find opensource projects to delve into (even ones not classed as opensource still were of help because the code is always available). But with ASP.NET, practically everything is closed source (.dll's) and/or you have to pay a high price to see the source code.
Could anyone please recommend me any books worth getting, or offer any advice on how to find better online resources, or perhaps point me in the direction of some opensource projects I can look at - or towards some opensource groups I could collaborate with.
Thanks
|
|
|
|
|
|
Hello everyone,
Thanks in advance for any responses.
I had a question about developing a custom web service written in .net 2.0 for Windows SharePoint Services (i.e. running in _vti_bin or _Layouts directories). I can write a custom web service in .net 1.1, however, I am having an issue with the discovery of the wsdl for the 2.0 web service. I believe it has to do with the differences between 1.1 and 2.0 web project compilations. There is a great article for writing custom web services for sharepoint on msdn http://msdn.microsoft.com/library/default.asp?url=/library/en-us/odc_sp2003_ta/html/odc_writingcustomwebservicesforsppt.asp
however, I need one in .net 2.0, any help would be greatly appreciated...
Brandon
braber
|
|
|
|
|
Hello,
I have an Asp.Net 2.0 Web.Sitemap file as follows:
...
<siteMap
xmlns = "http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >
<siteMapNode>
<siteMapNode
url = "~/default.aspx"
description = "Jaqueline Roxo Atelier"
title = "Página Inicial"
footer = "true" />
...
I want to loop through all 'siteMapNode' nodes and check if 'footer' attribute is true.
If 'footer' is true I want to add the 'url' and 'title' values to a data table or to a data view.
Is this possible?
Can someone suggest a way to do this?
Thanks,
Miguel
|
|
|
|
|
Yes, this is possible, look into the XmlDocument, XmlNode, XmlNodeList classes, then look for simple xpath queries... something like (//sitemapnode[@footer='true']/) of just query all sitemapnodes and then look for the attribute in the XmlNode...
Brandon
braber
|
|
|
|
|
Is it possible to intercept keystrokes in asp.net? i have someone who wants a specific button that wants to be the enter button to fire that event. I know in vb.net for windows applications that you can basically choose which button you want. If someone out there has something, it would be very useful.
|
|
|
|
|
Javascript events will be your best bet. OnKeyDown and the like.
|
|
|
|
|
How would i be able to fire a method in code behind if im using javascipt?
|
|
|
|
|
By making a postback.
---
b { font-weight: normal; }
|
|
|
|
|
Don't use the code behind for this. Otherwise you will have to do a post back on each key stroke and you user will hate you. Use Javascript. Then you can do a form.submit to fire the post back or some other mechinisum.
|
|
|
|
|
i am openning a link using a window.open when the page loads with IE7 but popup blocker is blocking it when the 'Use pop-up blocker'is enable(in Privacy tab of internet option).I want to bypass it means while the pop up blocker is enabled the window should open with the link.
any suggestion wud be appreciable...
thanks,
|
|
|
|
|
target="_blank" in anchor tag will open new window every time a link is clicked and won't have problems with popup blockers.
If you need to resize the window, you can do it with javascript. However, if you want to hide addressbars, scrollbars etc in the opened window, maybe it's better just to use DHTML window instead.
For this I would suggest using Ferant DHTML Studio Lite which is way cool!
|
|
|
|
|
Hii,
I have DNN setup alright. I have developed a separate Web Application and now I need to make my application workable with the DNN Users, means all the existing DNN users can use my site with the same credentials.
How do I go about doing this??
Please help me out
thanx
Mubashir
Every job is a self portrait of the person who did it.
|
|
|
|
|
Make a module out of the separate web application you developed.
One of the key ideas in DNN and modules IS that you don't need to force your users to log in multiple times to access different sections of your site.
|
|
|
|
|
I think I was not able to explain my question properly.
Actually I have some users in DNN. Now I want to make those users workable with my separate AST.NET web application. I can see the username and password in the DNN Database, but password is decrypted
Any suggestion
Mubashir
Every job is a self portrait of the person who did it.
|
|
|
|
|
How can I delete Items from database using datagrid. Can any one help me by giving code for delete event handler.
|
|
|
|
|
|
I have a domain where queries will be in form www.domain.com/demo12345
demo12345 being a code I need to grab & process.
I need to have a single page to process these requests and the only thing this domain does, is that it reads the code and processes it.
Can I do this on that domain itself or do I need to configure a redirection in IIS and grab the code from the referrer url?
|
|
|
|
|
use this function
Request.RawUrl()
it returns a string so u do string manipulation to get the part u want from it
hope this would help ...
Best Regards
3ala2
|
|
|
|