ASP.NET 2.0 Web Page Problem?

Discussion in 'ASP .Net' started by dm3281, Jun 24, 2008.

  1. dm3281

    dm3281 Guest

    Hi all --

    I have a strange issue.

    I have obtained a scripted database and compiled ASP.NET 2.0 application
    from a sister site that I'm trying to implement locally. I have
    successfully created the database and accessed various ASP.NET 2.0 admin web
    pages for populating some of the fields. The issue is, on one particular
    page that has two dropdown listboxes, where second was is populated with a
    list of customer numbers after the "group" is selected from the first
    dropdown appears to be throwing an ASP.NET exception error.

    Originally, we thought it may have been a database issue. However, I have
    backed up and given the database to our sister center and it works fine for
    the on their existing system.

    For the life of me I cannot get the page to work. I have checked IIS
    settings, application settings, etc., and cannot find anything. Its not too
    complicated of a web page and the only IIS configuration was creating a
    virtual directory/application and assigning .NET 2.0 to it.

    I have requested that they resend me the ASP.NET code/assemblies since I
    have no source to look at.

    I'm uncertain how the same code/database works on another system and throws
    an index error for me.


    The error is below.

    If anyone has any ideas, I'd be more than appreciative.

    Server Error in '/intranet' Application.
    --------------------------------------------------------------------------------

    Index was outside the bounds of the array.
    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.IndexOutOfRangeException: Index was outside the
    bounds of the array.

    Source Error:

    An unhandled exception was generated during the execution of the current web
    request. Information regarding the origin and location of the exception can
    be identified using the exception stack trace below.

    Stack Trace:


    [IndexOutOfRangeException: Index was outside the bounds of the array.]
    Operations_HBMBlockStatus.Repeater1_ItemCreated(Object sender,
    RepeaterItemEventArgs e) +1285
    System.Web.UI.WebControls.Repeater.OnItemCreated(RepeaterItemEventArgs e)
    +105
    System.Web.UI.WebControls.Repeater.CreateItem(Int32 itemIndex,
    ListItemType itemType, Boolean dataBind, Object dataItem) +92
    System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean
    useDataSource) +454
    System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e) +53
    System.Web.UI.WebControls.Repeater.DataBind() +72
    System.Web.UI.WebControls.Repeater.EnsureDataBound() +55
    System.Web.UI.WebControls.Repeater.OnPreRender(EventArgs e) +12
    System.Web.UI.Control.PreRenderRecursiveInternal() +86
    System.Web.UI.Control.PreRenderRecursiveInternal() +170
    System.Web.UI.Control.PreRenderRecursiveInternal() +170
    System.Web.UI.Control.PreRenderRecursiveInternal() +170
    System.Web.UI.Control.PreRenderRecursiveInternal() +170
    System.Web.UI.Page.ProcessRequestMain(Boolean
    includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2041




    --------------------------------------------------------------------------------
    Version Information: Microsoft .NET Framework Version:2.0.50727.1433;
    ASP.NET Version:2.0.50727.1433
     
    dm3281, Jun 24, 2008
    #1
    1. Advertising

  2. dm3281

    Jeff Winn Guest

    That's called a bug :)

    Based on the stack trace you've shown the problem is when the
    Operations_HBMBlockStatus page's Repeater1 ItemCreated event is being
    raised. The index out of range exception occurs when trying to access the
    index of a collection that is outside the bounds of the collection.

    For example: You have an array consisting of 2 objects, and the code tries
    to access the 3rd.

    You sister site might be hiding the exception by logging it or ignoring them
    somehow, I'd need to see the code to say for sure (which I don't want). It's
    not a problem with how your server is configured, the page wouldn't have
    started rendering if that was the case. If push comes to shove and you have
    to look at the code (assuming they haven't obfuscated it) go download Lutz
    Roeder's .NET Reflector and look at the disassembled code.

    "dm3281" <> wrote in message
    news:...
    > Hi all --
    >
    > I have a strange issue.
    >
    > I have obtained a scripted database and compiled ASP.NET 2.0 application
    > from a sister site that I'm trying to implement locally. I have
    > successfully created the database and accessed various ASP.NET 2.0 admin
    > web pages for populating some of the fields. The issue is, on one
    > particular page that has two dropdown listboxes, where second was is
    > populated with a list of customer numbers after the "group" is selected
    > from the first dropdown appears to be throwing an ASP.NET exception error.
    >
    > Originally, we thought it may have been a database issue. However, I have
    > backed up and given the database to our sister center and it works fine
    > for the on their existing system.
    >
    > For the life of me I cannot get the page to work. I have checked IIS
    > settings, application settings, etc., and cannot find anything. Its not
    > too complicated of a web page and the only IIS configuration was creating
    > a virtual directory/application and assigning .NET 2.0 to it.
    >
    > I have requested that they resend me the ASP.NET code/assemblies since I
    > have no source to look at.
    >
    > I'm uncertain how the same code/database works on another system and
    > throws an index error for me.
    >
    >
    > The error is below.
    >
    > If anyone has any ideas, I'd be more than appreciative.
    >
    > Server Error in '/intranet' Application.
    > --------------------------------------------------------------------------------
    >
    > Index was outside the bounds of the array.
    > 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.IndexOutOfRangeException: Index was outside the
    > bounds of the array.
    >
    > Source Error:
    >
    > An unhandled exception was generated during the execution of the current
    > web request. Information regarding the origin and location of the
    > exception can be identified using the exception stack trace below.
    >
    > Stack Trace:
    >
    >
    > [IndexOutOfRangeException: Index was outside the bounds of the array.]
    > Operations_HBMBlockStatus.Repeater1_ItemCreated(Object sender,
    > RepeaterItemEventArgs e) +1285
    > System.Web.UI.WebControls.Repeater.OnItemCreated(RepeaterItemEventArgs
    > e) +105
    > System.Web.UI.WebControls.Repeater.CreateItem(Int32 itemIndex,
    > ListItemType itemType, Boolean dataBind, Object dataItem) +92
    > System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean
    > useDataSource) +454
    > System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e) +53
    > System.Web.UI.WebControls.Repeater.DataBind() +72
    > System.Web.UI.WebControls.Repeater.EnsureDataBound() +55
    > System.Web.UI.WebControls.Repeater.OnPreRender(EventArgs e) +12
    > System.Web.UI.Control.PreRenderRecursiveInternal() +86
    > System.Web.UI.Control.PreRenderRecursiveInternal() +170
    > System.Web.UI.Control.PreRenderRecursiveInternal() +170
    > System.Web.UI.Control.PreRenderRecursiveInternal() +170
    > System.Web.UI.Control.PreRenderRecursiveInternal() +170
    > System.Web.UI.Page.ProcessRequestMain(Boolean
    > includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2041
    >
    >
    >
    >
    > --------------------------------------------------------------------------------
    > Version Information: Microsoft .NET Framework Version:2.0.50727.1433;
    > ASP.NET Version:2.0.50727.1433
     
    Jeff Winn, Jun 24, 2008
    #2
    1. Advertising

  3. dm3281

    dm3281 Guest

    I actually found out that the problem wasn't the repeater control or
    anything.

    Somewhere in the code it was getting the identity of the user and splitting
    it into array by slash separator, such as domainname\username. Evidently
    the next line of code was trying to assign the username only to another
    string. I didn't have nt authentication enabled and was using anonymous by
    default. I turned on NT authentication, answered authentication dialogue,
    and then I was off to the races.




    "Jeff Winn" <> wrote in message
    news:...
    > That's called a bug :)
    >
    > Based on the stack trace you've shown the problem is when the
    > Operations_HBMBlockStatus page's Repeater1 ItemCreated event is being
    > raised. The index out of range exception occurs when trying to access the
    > index of a collection that is outside the bounds of the collection.
    >
    > For example: You have an array consisting of 2 objects, and the code tries
    > to access the 3rd.
    >
    > You sister site might be hiding the exception by logging it or ignoring
    > them somehow, I'd need to see the code to say for sure (which I don't
    > want). It's not a problem with how your server is configured, the page
    > wouldn't have started rendering if that was the case. If push comes to
    > shove and you have to look at the code (assuming they haven't obfuscated
    > it) go download Lutz Roeder's .NET Reflector and look at the disassembled
    > code.
    >
    > "dm3281" <> wrote in message
    > news:...
    >> Hi all --
    >>
    >> I have a strange issue.
    >>
    >> I have obtained a scripted database and compiled ASP.NET 2.0 application
    >> from a sister site that I'm trying to implement locally. I have
    >> successfully created the database and accessed various ASP.NET 2.0 admin
    >> web pages for populating some of the fields. The issue is, on one
    >> particular page that has two dropdown listboxes, where second was is
    >> populated with a list of customer numbers after the "group" is selected
    >> from the first dropdown appears to be throwing an ASP.NET exception
    >> error.
    >>
    >> Originally, we thought it may have been a database issue. However, I
    >> have backed up and given the database to our sister center and it works
    >> fine for the on their existing system.
    >>
    >> For the life of me I cannot get the page to work. I have checked IIS
    >> settings, application settings, etc., and cannot find anything. Its not
    >> too complicated of a web page and the only IIS configuration was creating
    >> a virtual directory/application and assigning .NET 2.0 to it.
    >>
    >> I have requested that they resend me the ASP.NET code/assemblies since I
    >> have no source to look at.
    >>
    >> I'm uncertain how the same code/database works on another system and
    >> throws an index error for me.
    >>
    >>
    >> The error is below.
    >>
    >> If anyone has any ideas, I'd be more than appreciative.
    >>
    >> Server Error in '/intranet' Application.
    >> --------------------------------------------------------------------------------
    >>
    >> Index was outside the bounds of the array.
    >> 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.IndexOutOfRangeException: Index was outside the
    >> bounds of the array.
    >>
    >> Source Error:
    >>
    >> An unhandled exception was generated during the execution of the current
    >> web request. Information regarding the origin and location of the
    >> exception can be identified using the exception stack trace below.
    >>
    >> Stack Trace:
    >>
    >>
    >> [IndexOutOfRangeException: Index was outside the bounds of the array.]
    >> Operations_HBMBlockStatus.Repeater1_ItemCreated(Object sender,
    >> RepeaterItemEventArgs e) +1285
    >> System.Web.UI.WebControls.Repeater.OnItemCreated(RepeaterItemEventArgs
    >> e) +105
    >> System.Web.UI.WebControls.Repeater.CreateItem(Int32 itemIndex,
    >> ListItemType itemType, Boolean dataBind, Object dataItem) +92
    >> System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean
    >> useDataSource) +454
    >> System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e) +53
    >> System.Web.UI.WebControls.Repeater.DataBind() +72
    >> System.Web.UI.WebControls.Repeater.EnsureDataBound() +55
    >> System.Web.UI.WebControls.Repeater.OnPreRender(EventArgs e) +12
    >> System.Web.UI.Control.PreRenderRecursiveInternal() +86
    >> System.Web.UI.Control.PreRenderRecursiveInternal() +170
    >> System.Web.UI.Control.PreRenderRecursiveInternal() +170
    >> System.Web.UI.Control.PreRenderRecursiveInternal() +170
    >> System.Web.UI.Control.PreRenderRecursiveInternal() +170
    >> System.Web.UI.Page.ProcessRequestMain(Boolean
    >> includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    >> +2041
    >>
    >>
    >>
    >>
    >> --------------------------------------------------------------------------------
    >> Version Information: Microsoft .NET Framework Version:2.0.50727.1433;
    >> ASP.NET Version:2.0.50727.1433

    >
     
    dm3281, Jun 26, 2008
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Matthew Louden
    Replies:
    4
    Views:
    3,054
    Fahad Al Hadhrami
    Nov 24, 2003
  2. Josh Mitts
    Replies:
    3
    Views:
    604
  3. Dica
    Replies:
    2
    Views:
    597
  4. Matthew Louden

    how ASP.NET page gets user input from another ASP.NET page??

    Matthew Louden, Nov 22, 2003, in forum: ASP .Net Web Controls
    Replies:
    5
    Views:
    151
    Fahad Al Hadhrami
    Nov 24, 2003
  5. Replies:
    3
    Views:
    385
Loading...

Share This Page