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

HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...Control declaration breakingControl declaration breaking
Previous
 
Next
New Post
2/27/2008 9:17 AM
 

Hi,

Having some trouble declaring a usrcontrol in my code.

Just be be sure I was not doing something odd, I set up a new instance of DNN and all source code.
When I open the DNN solution, this statement fails in exactly the same way as my own code:

Line 172 of the EditVendors.ascx.vb file. Dim objBanners As Banners
Likewise in line 179, same file and other similar declarations elsewhere...

In the first case, the DIM statement claims that Banners is undefined. Std DNN code without a single change.
Namespaces and all controls as-is but it is not "seeing" the usercontrol class in the same namespace!

I'm doing something similar as I've done before in a different project, but cannot declare the control to eventually add to the PlaceHolder...
I'm working in VS2005 and have develped quite a few DNN modules and suddenly hit this, not seeing it before.

PLEASE tell me what could be wrong!! What am I not doing or doing wrong?

THANKS.

 

 
New Post
2/27/2008 10:51 AM
 

Are you using the WSP or WAP development model?


-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
2/27/2008 11:07 AM
 
Hi Mitch, Actually, the DNN simply opens as-is BUT what I'm trying to do is NOT in DNN but a separate project FOR NOW. I'm trying to do what I have done in DNN in this mini project to dynamically inject n number of the same usercontrol into a PlaceHolder. So within the Parent control code, declare a child control and load it then add to the PlaceHolder control as per code similar to this: Dim objBanners As Banners objBanners = CType(Me.LoadControl("~" & [PATH] & "/Banners.ascx"), Banners) 'OTHER PROPERTY SETTINGS HERE divBanners.Controls.Add(objBanners) The issue I'm seeing in both the std. DNN code is that the child control cannot be declared because VS claims that it is undefined. In both cases (DNN and my mini project), the child control is clearly defined within the same namespace. In the sample above, it says Banners is undefined and that is in the DNN code, clean and unchanged. This can't be THAT difficult to achieve! Thanks for ANY advice!
 
New Post
2/27/2008 11:17 AM
 

Sorry, it is WSP for now. I have others in WAP.

Come to think of it, I'll swtich to WAP and see if that will change things...bet it does...DOH!

Thanks

 
Previous
 
Next
HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...Control declaration breakingControl declaration breaking


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