More in this section
Forums / General Discussions / I got error when i save image Credits and description

I got error when i save image Credits and description

The forums are in read-only mode. In case that you want to directly contact the Progress Sitefinity team use the support center. In our Google Plus group you can find more than one thousand Sitefinity developers discussing different topics. For the Stack Overflow threads don’t forget to use the “Sitefinity” tag.
3 posts, 0 answered
  1. jmmy
    jmmy avatar
    3 posts
    04 Dec 2010
    15 Jan 2011
    Link to this post

    Hi please help me i am face error message when i am upload image in photoshoot.
    when i enter description and credits  i will got the error screen.
    below is the error which i got

    Object reference not set to an instance of an object.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

    Source Error:

    Line 61: 
    Line 62: 		LibraryDescriptionInfo libraryDescription = LibraryDescriptionController.GetByID(libraryID);
    Line 63: 		libraryDescription.Description = description;
    Line 64: 		libraryDescription.Credits = credits;
    Line 65: 		LibraryDescriptionController.Update(libraryDescription);

    Source File: c:\inetpub\vhosts\\httpdocs\App_Code\LibraryDescriptionEdit.cs    Line: 63

    Stack Trace:

    [NullReferenceException: Object reference not set to an instance of an object.]
       LibraryDescriptionEdit.LibraryDescription_Saved(Object sender, CommandEventArgs e) in c:\inetpub\vhosts\\httpdocs\App_Code\LibraryDescriptionEdit.cs:63
       Telerik.Libraries.WebControls.Admin.LibraryEdit`1.OnSaved(CommandEventArgs e) +270
       Telerik.Libraries.WebControls.Admin.LibraryEdit`1.SaveLibrary(String commandName) +807
       Telerik.Libraries.WebControls.Admin.LibraryEdit`1.Button_Command(Object sender, CommandEventArgs e) +231
       System.Web.UI.WebControls.LinkButton.OnCommand(CommandEventArgs e) +108
       System.Web.UI.WebControls.LinkButton.RaisePostBackEvent(String eventArgument) +135
       System.Web.UI.WebControls.LinkButton.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
       System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
       System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +175
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565
  2. jmmy
    jmmy avatar
    3 posts
    04 Dec 2010
    17 Jan 2011
    Link to this post
    please any one help me regarding this issue thanks
  3. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    12 Sep 2017
    17 Jan 2011
    Link to this post
    Hi jmmy,

    As far as I see you use a custom code - App_Code/LibraryDescriptionEdit.cs

    The code you have is failing because

    libraryDescription or libraryDescription.Description is null and you do not check for null exceptions.

    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Register for webinar
3 posts, 0 answered