ModuleSettings.aspx.cs error getting resource for

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
4/5/2011 8:59:20 AM
Gravatar
Total Posts 87

ModuleSettings.aspx.cs error getting resource for

Hi

i have my own module with settings and was using it for a while, module does not has any resources and i use it without compilations just by putting it on server as ascx and cs files in source form. 

with last release i downloaded  and installed fresh server (Windows with MySQL, .Net 3.5) and now when i try edit values on settings page of my module and press save it shows this error message

 ERROR mojoPortal.Web.AdminUI.ModuleSettingsPage - ModuleSettings.aspx.cs error getting resource for s.SettingName ShowRSS

and same messages for each of my custom settings i've added to my module (ShowRSS - is a custom property of my module).

I installed everything as usual and as i did several times before with previous versions of mojoportal but now it stuck.

Can anyone help? point me what setting i can fix to make it working?

thanks

4/5/2011 9:16:25 AM
Gravatar
Total Posts 18439

Re: ModuleSettings.aspx.cs error getting resource for

Hi,

That is logged inside a try catch like this:

try
                {
                    settingLabel = GetGlobalResourceObject(resourceFile, s.SettingName).ToString();
                }
                catch (NullReferenceException ex)
                {
                    if (log.IsErrorEnabled)
                    {
                        log.Error("ModuleSettings.aspx.cs error getting resource for s.SettingName " + s.SettingName, ex);
                    }
                }

so you may see it in your log but it should not appear in the page and it should not be causing edit problems. I would look for a different cause or a different error if you are not able to edit.

If you are not using resources, you might try putting "Resource" as the resourceFile in your settings anyway and see if it helps.

Hope it helps,

Joe

4/5/2011 9:58:00 AM
Gravatar
Total Posts 87

Re: ModuleSettings.aspx.cs error getting resource for

Thank you for quick reply

i've put Resource as you recommended and not sure it is because of that change or because i looked more carafully on the list and found one more error in log, but after changes i found one more error and it helped me to fix it.

Thank you.

4/5/2011 10:10:11 AM
Gravatar
Total Posts 87

Re: ModuleSettings.aspx.cs error getting resource for

Small correction: setting Resource is really helped because on other PC with different configuration it started working just after setting this name without any other errors.

So after more investigations and putting back empty field instead of "Resource" i found this error message as last in log

2011-04-05 18:08:08,169 ERROR mojoPortal.Web.Global - 80.64.88.20-ru-RU - /Admin/ModuleSettings.aspx?mid=12&pageid=1
System.Resources.MissingManifestResourceException: Could not find any resources appropriate for the specified culture or the neutral culture.  Make sure "Resources..resources" was correctly embedded or linked into assembly "App_GlobalResources.dphhj-hv" at compile time, or that all the satellite assemblies required are loadable and fully signed.

Hope it will help to nail what was changed to make this error.

 

Regards,

Victor

 

 

4/5/2011 10:14:03 AM
Gravatar
Total Posts 18439

Re: ModuleSettings.aspx.cs error getting resource for

It does, I have fixed it in my copy so it will be fixed in the next release. For now the workaround is to set the resourceFile="Resource" when you are not really using a resource file of your own.

Best,

Joe

8/4/2011 8:33:29 AM
Gravatar
Total Posts 87

Re: ModuleSettings.aspx.cs error getting resource for

Hi Joe,

few days ago i downloaded fresh version of mojoportal (.net 4.0 with MySql patch over it) and the problem is still there: if i add my custom module it gives same error and it goes away after i set "Resource" in the textbox as you recommended. I do not think it is really important but just wanted to let you know, may be you made fix that you mentioned in some other fork.

Regards,

Victor

 

You must sign in to post in the forums. This thread is closed to new posts.