Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4062642
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T15:37:28+00:00 2026-05-20T15:37:28+00:00

What does this error mean?, I keep getting this error, it use to work

  • 0

What does this error mean?, I keep getting this error, it use to work fine and it just started throwing this error…. any help?

img1.ImageUrl = ConfigurationManager.AppSettings.Get("Url").Replace("###", randomString) 
 + Server.UrlEncode(((System.Web.UI.MobileControls.Form)Page.FindControl("mobileForm")).Title);

An exception of type ‘System.NullReferenceException’ occurred in
MyProject.DLL but was not handled in user code

Additional information: Object reference not set to an instance of an
object.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T15:37:28+00:00Added an answer on May 20, 2026 at 3:37 pm

    It means somewhere in your chain of calls, you tried to access a Property or call a method on an object that was null.

    Given your statement:

    img1.ImageUrl = ConfigurationManager
                        .AppSettings
                        .Get("Url")
                        .Replace("###", randomString) 
                    + Server.UrlEncode(
                          ((System.Web.UI.MobileControls.Form)Page
                          .FindControl("mobileForm"))
                          .Title);
    

    I’m guessing either the call to AppSettings.Get("Url") is returning null because the value isn’t found or the call to Page.FindControl("mobileForm") is returning null because the control isn’t found.

    You could easily break this out into multiple statements to solve the problem:

    var configUrl = ConfigurationManager.AppSettings.Get("Url");
    var mobileFormControl = Page.FindControl("mobileForm")
                                as System.Web.UI.MobileControls.Form;
    
    if(configUrl != null && mobileFormControl != null)
    {
        img1.ImageUrl = configUrl.Replace("###", randomString) + mobileControl.Title;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

When I use this statement if(count($this->input->post('p_id') =0)) , I keep getting this error: Fatal
In Perl, what does this error mean? Unresolved symbol: Perl_Gthr_key_ptr I am getting this
I keep getting this error: Error: uncaught exception: Syntax error, unrecognized expression: [object Object]
What does this error mean? /tmp/ccevEqoI.o: In function `main': funcptr.c:(.text+0x61): undefined reference to `AddALL'
I get this error: System.Reflection.TargetException: Object does not match target type. when trying to
Take the method System.Windows.Forms.Control.Invoke(Delegate method) Why does this give a compile time error: string
What does this mean exactly? I'm doing something like this: File.Copy(@\\foo\bar\baz.txt, @c:\test\baz.txt); MSDN doesn't
I'm using C# , .NET and SQL Server with Linq2SQL. What does this error
Does this pattern: setTimeout(function(){ // do stuff }, 0); Actually return control to the
Why does this javascript return 108 instead of 2008? it gets the day and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.