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.0newbie: code only execute if user is Host, strangenewbie: code only execute if user is Host, strange
Previous
 
Next
New Post
8/21/2006 9:57 AM
 

Hey

I've created a new module ("AskUs" is the module name) using visual studio 2005 and DotNetNuke Starter Kit.

In ViewAskUs.ascx, I added a Label control and a button. On the click event of the button a method will change the text of the Label control. But it only changes the text if user is Host (I haven't tryed if the user is Admin).:

protected void Button1_Click(object sender, EventArgs e)
{
  lblWelcome.Text = "Hello the world";
  Debug.WriteLine("TESTING");
}

What am I doing wrong? I want this code to be executed for all users...

PS: Even if being a Host the Debug.WriteLine code in the method wasn't executed (nothing appear in the output window), why?

moonshiner

 
New Post
8/21/2006 12:30 PM
 

I have no idea about debug.writeline, I never use that. I work with breakpoints

 

Make shure module caching is off. That's why your code doesn't execute when not logged in. It uses the cached version. Check the cache setting in the module settings.


Edit your Skin.xml and Container.xml files with:
Yannick's SXE
 
New Post
8/21/2006 4:48 PM
 

How do I turn off this cache?

The only setting I see which mentions the word cache is "Cache Time (secs):" (which has the value 60). This setting isn't under the module, it's under the page settings (maybe it's the same?)

moonshiner

 
New Post
8/23/2006 12:57 PM
 
Jup that's the value, please put it on 0 and all your problems will be gone




That setting is only usefull for modules wich are static, like Text/HTMl and Media

Edit your Skin.xml and Container.xml files with:
Yannick's SXE
 
Previous
 
Next
HomeHomeArchived Discus...Archived Discus...Developing Under Previous Versions of .NETDeveloping Under Previous Versions of .NETASP.Net 2.0ASP.Net 2.0newbie: code only execute if user is Host, strangenewbie: code only execute if user is Host, strange


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