Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Parameter Passing Between ModulesParameter Passing Between Modules
Previous
 
Next
New Post
3/28/2008 11:58 AM
 

Hi,

I've developed two custom modules, to allow the creation of a course/curriculum with class enrollment, and a separate testing module, containing tests related to the courses. I placed a grid on the main form of the course module that will contain all the test associated tests. I would this to be a link, and when the user clicks; it will populate a list box on the main form of the test module with the corresponding test.  What parameters do I need to pass to the test module, to make this work? Can this be achieved using query string parameters? As always any help is appreciated!

Thanks,

Larry B.

 

 
New Post
3/28/2008 12:13 PM
 

This really is dependent on the way that your module is built, most likely a single querystring parameter would be enough, to pass a unique id or soemthing that would allow you to pull it up, but it depends on your specific needs.

I would personally recommend an encrypted URL parameter to keep things more secure.


-Mitchel Sellers
Microsoft MVP, ASPInsider, DNN MVP
CEO/Director of Development - IowaComputerGurus Inc.
LinkedIn Profile

Visit mitchelsellers.com for my mostly DNN Blog and support forum.

Visit IowaComputerGurus.com for free DNN Modules, DNN Performance Tips, DNN Consulting Quotes, and DNN Technical Support Services
 
New Post
3/28/2008 3:19 PM
 

Do you have an example of how i go about setting this up? The only parameter I need to pass in, is the "TestID", I have the "TestID" column setup as an item templete in the grid. But once the click comes in Im not sure how to handle it. Will the load event of the test module retrieve the querystring parameter? Heres  the item template i have setup. Im using VB.net. Thanks again!

<

radG:GridTemplateColumn HeaderText="Test(s)" UniqueName="TemplateColumn">

 

<ItemTemplate>

 

<asp:HyperLink runat="server" NavigateUrl='<%# DataBinder.Eval(Container, "DataItem.TestID") %>'

 

Text='<%# DataBinder.Eval(Container, "DataItem.TestName") %>'></asp:HyperLink>

 

</ItemTemplate>

 

</radG:GridTemplateColumn>

 

 
New Post
3/28/2008 5:28 PM
 

Thanks Mitch - I also found a very good read on using IMC(Inter-Module Communication) here:

http://www.kemmis.info/blog/archive/2008/02/22/dotnetnuke-inter-module-communication-or-how-your-modules-can-get-their.aspx

 
New Post
3/31/2008 10:23 PM
 

Larry B.,

I just posted an answer to a different thread that you might find useful.

http://www.dotnetnuke.com/Community/Forums/tabid/795/forumid/111/threadid/216093/scope/posts/Default.aspx

That thread gives a basic explanation of how to send a query string. For the second part of your question here is one way that you can “catch” a query string.

       Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
          
Try
                If Not Page.IsPostBack Then
                    Dim _Key As Integer = 0 
                    If Request.QueryString("KEY") IsNot Nothing
Then
                       
_Key = CType(Request.QueryString("KEY"), Integer)
                    End If 
                   
'Do something with _Key
               
End
If
           
Catch ex As Exception
                ProcessModuleLoadException(Me, ex)
            End
Try
       
End Sub

In this example the query string is KEY and the value is an integer.

It’s important to note that IMC only works if the two modules are on the same page. If they are not on the same page then the next best way to send a parameter is via a query string using NavigateURL() on the sending page and something like the above code to receive the parameter on the destination page.

Hope this helps, if you’re still having problems or if you have any questions let me know.

Nathan Rover

 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0Parameter Passing Between ModulesParameter Passing Between Modules


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, 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 DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out