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  |  

AspDotNetStoreFront
  Ads  
Iron Speed Designer is a software development tool for building database, reporting, and forms applications for .NET without hand-coding.
 


  Sponsors  

Meet Our Sponsors

Webhost4life, specialists in DNN hosting
Mad Development is a full service interactive agency focusing on the merge of design, technology, e-commerce, and affiliate marketing by providing total website solutions.
AspDotNetStoreFront - E-Commerce by Design - The Leading ASP.NET shopping cart platform for developers!
SteadyRain
DataSprings - Great Ideas. Always Flowing.
R2integrated - formerly bi4ce
 


DotNetNuke Forums
 
  Forum  General DotNetN...  Extend It! ( Pr...  Load UserControl (ascx)
Previous Previous
 
Next Next
New Post 3/17/2008 2:01 PM
User is offline b471code3
134 posts
www.froggeyestudios.com
9th Ranked


Re: Load UserControl (ascx) 

Prowler - wondering where your Request.Params is coming from?  I have been looking into this for some time and this makes perfect sense to me but I am also still new to programming within DNN.  Do you have any other code to go with your example? 

 SDFprowler wrote
If Request.Params("go") = "sum" Then
                Dim objModule As Entities.Modules.PortalModuleBase = Nothing
                objModule = CType(LoadControl("DNNReportingPolSum.ascx"), Entities.Modules.PortalModuleBase)
                objModule.ModuleConfiguration = ModuleConfiguration
                Controls.Add(objModule)
            Else
                Dim objModule As Entities.Modules.PortalModuleBase = Nothing
                objModule = CType(LoadControl("DNNReportingStart.ascx"), Entities.Modules.PortalModuleBase)
                objModule.ModuleConfiguration = ModuleConfiguration
                Controls.Add(objModule)
            End If

I use this for my datalist and it works fairly good but still not navigating to another control:

 

Protected Sub dlContacts_ItemCommand(ByVal source As Object, ByVal e As DataListCommandEventArgs)

Select Case e.CommandName
Case "Insert"
InsertContact(e)
Exit Sub
Case "Edit" 
EditContact(e)
Exit Sub
Case "Select"
SelectContact(e)
Exit Sub 
Case "Delete" 
DeleteContact(e) 
Exit Sub 
Case "Cancel" 
CancelContact(e)
Exit Sub 
Case "Update" 
UpdateContact(e)
Exit Sub 
End Select 

End Sub

  Protected Sub EditContact(ByVal e As DataListCommandEventArgs)
' takes user to edit template 
dlContacts.EditItemIndex = e.Item.ItemIndex
dlContacts.DataBind()
End Sub 

Protected
Sub SelectContact(ByVal e As DataListCommandEventArgs)
' displays the selected item details 
dlContacts.SelectedIndex = e.Item.ItemIndex
dlContacts.DataBind()
End Sub 

 ......

 

 

 

 

 
New Post 3/18/2008 6:43 PM
User is offline mpdan
28 posts
10th Ranked


Re: Load UserControl (ascx) 

Is there anything wrong with using a MultiView in this case?  

 

 
New Post 8/21/2008 4:15 AM
User is offline Richard Golko
50 posts
www.UCanUse.com
10th Ranked


Re: Load UserControl (ascx) 
Modified By Richard Golko  on 8/21/2008 6:36:02 AM)

Thanks for your post about loading differnet controls/modules into another dnn module.

I have a module where I'm trying to do what you desribed.  On postback the control dissappears, so I have to load it every postback.  however the v13wstat3 is being lost; teh user entered values are gone every postback.  How do you alleviate that problem?  I have tried for 3 days but to no avail.  If you have a way to help please let me know.  I/m dying here!

 

More details:  I am loading the control into a panel wrapped in a Telerik ajaz loading panel.

I've tried loading it into the loading panel itself; same result.

I've tried loading it into D.Bauer's placeholder control and it still loses stae in that!

I'm willing to pay someone for a working solutino to this.

Thanks.

 
New Post 8/21/2008 9:56 AM
User is offline Carlos Rodriguez
524 posts
www.almacigo.com
8th Ranked


Re: Load UserControl (ascx) 

Nothing wrong with using a MultiView, if the modules/forms in question are simple.  But if any of the forms gets complex, you are better off separating them into different controls.

I used a derivative of the example presented by InDyneInc in this link.  They use the concept of a "switchboard" main control, under which, according to your logic, parameters, etc. you load the other user controls. 

The way I have done it, and I have never ran into the problem with v13wstate, is that I have no controls at all in the switchboard module, which is the registered View control for the module.  This is another advantage I see with this method, you don't have to register any of the other user controls, just the main View control.

Hope this helps.

Carlos

 

 
New Post 8/21/2008 4:44 PM
User is offline Richard Golko
50 posts
www.UCanUse.com
10th Ranked


Re: Load UserControl (ascx) 

Thanks for that information and link, Carlos.  We have managed to solve the issue with the multiview control, and I'll look over the additional information for more complex modules. 

 
Previous Previous
 
Next Next
  Forum  General DotNetN...  Extend It! ( Pr...  Load UserControl (ascx)
 


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.

 


DNNMasters - modules, consulting, development
DNNMasters developers are involved in DNN development since DNN 1.0.9 and today we offer a broad range of DNN related products and services including custom development of modules, help with ing third party modules for specific needs, general DNN technical support and administrative services.
www.dnnmasters.com
Cygnusoft Custom Software
Cygnusoft has been providing cutting-edge custom software solutions for 20 years. Cygnusoft is also a leading start-up incubator, helping our partners build successful new businesses.
www.cygnusoft.com
Digicon: DotNetNuke design and development
Digicon is based in Brisbane, Queensland, Australia
digicon.com.au

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