Re: BUG? OR NOT A BUG?

Discussion in 'ASP .Net' started by John, Sep 20, 2005.

  1. John

    John Guest

    Bruce,

    Firstly, thanks a heck of a lot for your reply.

    I've since discovered that the issue I previously described only happens
    when the rendering is a label object (i.e. every time a label is rendered as
    a column, at 2 to the ordinal position).

    That aside, I am new to Javascript. Could you please provide a link of an
    example of how to look for td's undare the current tr that my Javascript is
    in?

    Regards
    John.


    "Bruce Barker" <> wrote in message
    news:%...
    > if you use the dom, you can not assume the node ordering for the table (0
    > = cell 0, 1 = cell 1). you should scan the table for tr, then look under
    > the tr children for td's. there is a table api that may be better suited
    > to what you are doing.
    >
    > -- bruce (sqlwork.com)
    >
    >
    >
    >
    >
    > "John" <> wrote in message
    > news:%...
    >> Hi all,
    >>
    >> This is a Javascript issue for me but it is (I feel, think, expect)
    >> brought on as a result of ASP.NET and in particular VS2005.
    >>
    >> My app uses a GridView and I bind some labels and textboxes to the grid
    >> and render to user.
    >>
    >> The first column which is not bindable is simply an image. The users
    >> clicks this image and a popup appears. The user selects something on that
    >> popup (it's a lookup page) and then Javascript within that popup
    >> populates an object and returns it to the parent page --> so far fine...
    >>
    >> The receiving (i.e. parent) page receives the object and then attempts to
    >> populate column values ON THE SAME ROW --> problem!
    >>
    >> The very next column (i.e. immediately to the right of the image) is
    >> populated. Columns after that are not. I'm using the following notation:
    >> oSourceParent.children(1).firstChild.innerText = o.Code;
    >>
    >> The above works fine but the following doesn't:
    >>
    >> oSourceParent.children(2).firstChild.innerText = o.Code;
    >>
    >> It seems to me that every subsequent cell being generated by ASP.NET 2.0
    >> is creating a double end cell (i.e. </TD></TD>).
    >>
    >> Now when I change the Javascript to:
    >>
    >> oSourceParent.children(3).firstChild.innerText =
    >> ode; -------------> It sets the value correctly
    >>
    >> Any takes on this? If it is a bug, does that mean MS will fix down the
    >> line and my code will break at that point?
    >>
    >> Regards
    >> John.
    >>

    >
    >
    John, Sep 20, 2005
    #1
    1. Advertising

  2. John

    Bruce Barker Guest

    http://www.mozilla.org/docs/dom/technote/tn-dom-table/


    -- bruce (sqlwork.com)


    "John" <> wrote in message
    news:...
    > Bruce,
    >
    > Firstly, thanks a heck of a lot for your reply.
    >
    > I've since discovered that the issue I previously described only happens
    > when the rendering is a label object (i.e. every time a label is rendered
    > as a column, at 2 to the ordinal position).
    >
    > That aside, I am new to Javascript. Could you please provide a link of an
    > example of how to look for td's undare the current tr that my Javascript
    > is in?
    >
    > Regards
    > John.
    >
    >
    > "Bruce Barker" <> wrote in message
    > news:%...
    >> if you use the dom, you can not assume the node ordering for the table (0
    >> = cell 0, 1 = cell 1). you should scan the table for tr, then look under
    >> the tr children for td's. there is a table api that may be better suited
    >> to what you are doing.
    >>
    >> -- bruce (sqlwork.com)
    >>
    >>
    >>
    >>
    >>
    >> "John" <> wrote in message
    >> news:%...
    >>> Hi all,
    >>>
    >>> This is a Javascript issue for me but it is (I feel, think, expect)
    >>> brought on as a result of ASP.NET and in particular VS2005.
    >>>
    >>> My app uses a GridView and I bind some labels and textboxes to the grid
    >>> and render to user.
    >>>
    >>> The first column which is not bindable is simply an image. The users
    >>> clicks this image and a popup appears. The user selects something on
    >>> that popup (it's a lookup page) and then Javascript within that popup
    >>> populates an object and returns it to the parent page --> so far fine...
    >>>
    >>> The receiving (i.e. parent) page receives the object and then attempts
    >>> to populate column values ON THE SAME ROW --> problem!
    >>>
    >>> The very next column (i.e. immediately to the right of the image) is
    >>> populated. Columns after that are not. I'm using the following notation:
    >>> oSourceParent.children(1).firstChild.innerText = o.Code;
    >>>
    >>> The above works fine but the following doesn't:
    >>>
    >>> oSourceParent.children(2).firstChild.innerText = o.Code;
    >>>
    >>> It seems to me that every subsequent cell being generated by ASP.NET 2.0
    >>> is creating a double end cell (i.e. </TD></TD>).
    >>>
    >>> Now when I change the Javascript to:
    >>>
    >>> oSourceParent.children(3).firstChild.innerText = ode; ------------->
    >>> It sets the value correctly
    >>>
    >>> Any takes on this? If it is a bug, does that mean MS will fix down the
    >>> line and my code will break at that point?
    >>>
    >>> Regards
    >>> John.
    >>>

    >>
    >>

    >
    >
    Bruce Barker, Sep 21, 2005
    #2
    1. Advertising

  3. John

    John Guest

    Will check out - thanks a lot...

    "Bruce Barker" <> wrote in message
    news:...
    > http://www.mozilla.org/docs/dom/technote/tn-dom-table/
    >
    >
    > -- bruce (sqlwork.com)
    >
    >
    > "John" <> wrote in message
    > news:...
    >> Bruce,
    >>
    >> Firstly, thanks a heck of a lot for your reply.
    >>
    >> I've since discovered that the issue I previously described only happens
    >> when the rendering is a label object (i.e. every time a label is rendered
    >> as a column, at 2 to the ordinal position).
    >>
    >> That aside, I am new to Javascript. Could you please provide a link of an
    >> example of how to look for td's undare the current tr that my Javascript
    >> is in?
    >>
    >> Regards
    >> John.
    >>
    >>
    >> "Bruce Barker" <> wrote in message
    >> news:%...
    >>> if you use the dom, you can not assume the node ordering for the table
    >>> (0 = cell 0, 1 = cell 1). you should scan the table for tr, then look
    >>> under the tr children for td's. there is a table api that may be better
    >>> suited to what you are doing.
    >>>
    >>> -- bruce (sqlwork.com)
    >>>
    >>>
    >>>
    >>>
    >>>
    >>> "John" <> wrote in message
    >>> news:%...
    >>>> Hi all,
    >>>>
    >>>> This is a Javascript issue for me but it is (I feel, think, expect)
    >>>> brought on as a result of ASP.NET and in particular VS2005.
    >>>>
    >>>> My app uses a GridView and I bind some labels and textboxes to the grid
    >>>> and render to user.
    >>>>
    >>>> The first column which is not bindable is simply an image. The users
    >>>> clicks this image and a popup appears. The user selects something on
    >>>> that popup (it's a lookup page) and then Javascript within that popup
    >>>> populates an object and returns it to the parent page --> so far
    >>>> fine...
    >>>>
    >>>> The receiving (i.e. parent) page receives the object and then attempts
    >>>> to populate column values ON THE SAME ROW --> problem!
    >>>>
    >>>> The very next column (i.e. immediately to the right of the image) is
    >>>> populated. Columns after that are not. I'm using the following
    >>>> notation:
    >>>> oSourceParent.children(1).firstChild.innerText = o.Code;
    >>>>
    >>>> The above works fine but the following doesn't:
    >>>>
    >>>> oSourceParent.children(2).firstChild.innerText = o.Code;
    >>>>
    >>>> It seems to me that every subsequent cell being generated by ASP.NET
    >>>> 2.0 is creating a double end cell (i.e. </TD></TD>).
    >>>>
    >>>> Now when I change the Javascript to:
    >>>>
    >>>> oSourceParent.children(3).firstChild.innerText = ode; ------------->
    >>>> It sets the value correctly
    >>>>
    >>>> Any takes on this? If it is a bug, does that mean MS will fix down the
    >>>> line and my code will break at that point?
    >>>>
    >>>> Regards
    >>>> John.
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    John, Sep 21, 2005
    #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. RedEye
    Replies:
    2
    Views:
    578
    Jason Kester
    Dec 13, 2005
  2. Michel Joly de Lotbiniere

    Bug Parade Bug 4953793

    Michel Joly de Lotbiniere, Nov 30, 2003, in forum: Java
    Replies:
    4
    Views:
    638
    Michel
    Dec 2, 2003
  3. Andrea Desole
    Replies:
    2
    Views:
    1,184
    Andrea Desole
    Aug 9, 2006
  4. Good Night Moon
    Replies:
    9
    Views:
    275
    Rick DeNatale
    Jul 25, 2007
  5. Kyle Schmitt

    Bug or not a bug? array*=int

    Kyle Schmitt, Oct 29, 2008, in forum: Ruby
    Replies:
    6
    Views:
    96
    Kyle Schmitt
    Oct 30, 2008
Loading...

Share This Page