Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

DotNetNuke Marketplace
  Need Help?  
Professional technical support for DotNetNuke is available from DotNetNuke Corporation.
 


  Ads  
Active Modules -- Active Forums for DotNetNuke
 


  Sponsors  

Meet Our Sponsors

The Official Microsoft ASP.NET Website
Portal Webhosting - Hosting For Developers
Red-Gate Software
MaximumASP
SourceGear - Tools for Developers
.: CounterSoft :.
 


DotNetNuke Forums
 
  Forum  General DotNetN...  Extend It! ( Pr...  NavigateUrl vs EditUrl
Previous Previous
 
Next Next
New Post 5/14/2008 9:48 AM
Resolved
User is offline r_honey
107 posts
9th Ranked


NavigateUrl vs EditUrl 

Even after some searching, I am not precisely clear about the differences between the NavigateUrl & EditUrl methods, and when should I use which one???

In would be extremely helpful, if somebody could explain precisely their differences, and intended uses???

Also, I passed a string "Action=Add" in cmdArgs of EdittUrl. How do I retrieve it on the destination control???

 
New Post 5/15/2008 12:52 AM
User is offline r_honey
107 posts
9th Ranked


Re: NavigateUrl vs EditUrl 

Can someone please explain the parameters in the following overload of EditUrl:

"Public Function EditUrl(ByVal KeyName As String, ByVal KeyValue As String, ByVal ControlKey As String, ByVal ParamArray AdditionalParameters() As String) As String"

I mean every control (except the primary View Control) has a key associated to it. So, what does KeyName or KeyValue signify here??? What should be passed as their values?

Also, what are AdditionalParameters? Is there any special syntax to be used for strings being passed to AdditionalParameters???
 Are they passed to the destination page in its QueryString?? (In my case, I tried to pass "Action=Add" as Additional Parameter, but could not retrieve anything like that on the destination control)!!!

 
New Post 5/15/2008 11:34 AM
User is offline Snoek8
43 posts
www.mexmax-internet.com
10th Ranked


Re: NavigateUrl vs EditUrl 

The function of the additional parameters is indeed as you described. If you put "Action=Add" as your additional parameter this parameter will be accessible as a querystring parameter on your destination page.

Stephan
www.mexmax-internet.com

 
New Post 5/15/2008 12:02 PM
Accepted Answer 
User is offline Brian Dukes
366 posts
www.engagesoftware.com
8th Ranked


Re: NavigateUrl vs EditUrl 

You want to use EditUrl when you are navigating to a sub control of your current control (using a Control Key).  If you are navigating anywhere else, use NavigateUrl.  The main difference, (aside from the different signatures) is that EditUrl will include mid=(your module's ID) in the querystring so that DNN knows how to load the control you are trying to load based on the control key.

The most basic scenario for EditUrl is where you just need to get to a sub control with a control key of "Edit".  That's where you'll just use EditUrl() without any parameters.  Say that the control key is "DisplayOptions," then use EditUrl("DisplayOptions").

Now, the "tricky" part is when you want to pass custom parameters.  For the first parameter, use those KeyName, and KeyValue parameters (so, EditUrl("Action", "Add", "DisplayOptions") ).  If you have other parameters, use the AdditionalParamters array, like so: EditUrl("Action", "Add", "DisplayOptions", "pid=1", "lid=2", "xid=3").  The reason this seems kind of weird is that EditUrl is written with the edit scenario in mind, where you'd do something like EditUrl("itemId", 3, "EditItem"), where you often need to keep track of just one parameter (the item you are editing).

All of these parameters should show up on the querystring (all EditUrl is doing, after all, is creating a URL).  In the receiving control, you should be able to get at them by calling Request.QueryString("Action"), etc.

If that isn't working, take a look at the URL that EditUrl is generating, and see whether those values are getting put on it.

Hope that helps,


Brian Dukes
Engage Software
St. Louis, MO
314.966.4000

The leading provider of DotNetNuke support, training and custom module development.
 
New Post 5/15/2008 4:26 PM
User is offline baldwin
96 posts
www.dnnsun.com
10th Ranked


Re: NavigateUrl vs EditUrl 

And you can get some helpful information from here :http://www.adefwebserver.com/DotNetNukeHELP/NavigateURL/ !  The tutorial shows the detail of the NavigateURL function and his paramaters!

Hope that helps for you, also!


www.dnnsun.com:The professional provider of DotNetNuke support, skin design and custom module development.
The professional provider of DotNetNuke support, skin design and custom module development.
Showcase your website Powered by dnn!
Showcase your website Powered by dnn!
 
Previous Previous
 
Next Next
  Forum  General DotNetN...  Extend It! ( Pr...  NavigateUrl vs EditUrl
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:

1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


OnyakTech
Modules for Help Desks, Live Chat, Project Management, CRM, Charting, Reporting, Scrolling Text/Images, Portal Community tools and much more.
www.OnyakTech.com
IHostASP.NET Provides the Ideal DNN Hosting
We will help you with the installation, configuration, and troubleshooting of your DNN portal, no task is too big or small for us. Unlike other companies we are not just providing a reliable hosting service, but we are also focused on providing the best DotNetNuke hosting service on the internet.
www.ihostasp.net
$7.16/mo - Powerful DotNetNuke Hosting
Powerful DotNetNuke Hosting starting at under $8/mo with FREE SQL 2005, FREE Installation and expert support.
www.re-invent.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP