asp.net in the DNN module development of the RESX problem _ practical skills

Source: Internet
Author: User
Tags dnn
The RESX problem encountered in the development of DNN modules
Recently, a previous Crossarticle module was modified, where a resourkey in a Test.ascx file can always display only the text values given directly, not the values in the ResX file.
Other ascx files can use the text in their own resx.
Repeatedly check the n times, fast crazy. Generating ResX under the VS2008 Tools menu does not solve the problem.
Please give a hint to your friends, thank you.
Related Code Snippets:
<?xml:namespace prefix = asp/> "resourcekey=" Hyplreadmore ">
&LT;TD align= "left" nowrap>
<asp:hyperlink id= "Lnkreadmore" resourcekey= "Hyplreadmore" visible= ' <%# showreadmore%> ' class= ' Normal ' runat= "Server" text= "Details ..." ></asp:HyperLink>
</td>
Then a few friends answered, although did not solve the problem, but I still have a hint, after the use of "getresourcefile (This," "as a keyword, google out of the answer."
= = Below is the answer:
In private void InitializeComponent ()
Add "this. Localresourcefile =
DotNetNuke.Services.Localization.Localization.GetResourceFile (This, "Crossarticle.ascx"); "
Will solve the problem.
The URL involved:
Http://anforen.5d6d.com/thread-294-1-1.html
Http://dnnme.cn/showtopic-557.aspx
Another problem is:
I was on the Ascx page, adding LinkButton, unable to handle the click event in the code behind file, and double-clicking the button on the page, only to be processed in the script code in the ascx file.
Just started checking the code everywhere.
Finally found the answer is as follows:
When the public abstract class class is set, the button does not have a lightning event setting for the property window. Changing the abstract to partial can
To
= = =
Two small problems, solved, in this note, I wrote this is the style. The main is to let me and everyone in the future when Google, find clues is enough.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.