master/detail page problem

Discussion in 'ASP General' started by Raphael Gluck, Oct 21, 2003.

  1. Hi Everyone

    I am having some problems with a master detail page i have set up to
    catalogue brochures from my site.
    On my master page www.tripakltd.com/brochures.asp users are invited to
    select from a list of brochure categories, then once they press the submit
    button they will be taken to a different page www.tripakltd.com/library.asp
    The problem i am having, is that when I tell the detail page about the
    variable from the master page as a % as opposed to a hard number, i.e 1 or 2
    I get an error, Therfore for the purpose of displaying the page i have put
    in a hard number (rsLibrary__icategoryid = "1" as opposed to ="%") but of
    course this only returns to me brochures that belong to categoryID.
    How do i fix this problem? all my other master/detail pages seem, to work,
    save this one.

    To simplify the problem i have created two pages with just the code ( i.e no
    graphics, or templates etc..) that carry the same technology, and have
    included the relevant source code on the same page, with a .txt extension
    www.tripakltd.com/brochures1.asp and www.tripakltd.com/brochures1.txt
    www.tripakltd.com/library1.asp and www.tripakltd.com/library1.txt

    Can anyone help me sort out this problem?

    I would greatly appreciate it,

    Thanks so much

    Raphael
    Raphael Gluck, Oct 21, 2003
    #1
    1. Advertising

  2. If I get you right I htink the problem is that your select box does not have
    a name......set the select as CategoryID and then the value should get
    posted to the library.asp page.

    Thats if I understand the question right.

    Stu

    "Raphael Gluck" <> wrote in message
    news:...
    > Hi Everyone
    >
    > I am having some problems with a master detail page i have set up to
    > catalogue brochures from my site.
    > On my master page www.tripakltd.com/brochures.asp users are invited to
    > select from a list of brochure categories, then once they press the submit
    > button they will be taken to a different page

    www.tripakltd.com/library.asp
    > The problem i am having, is that when I tell the detail page about the
    > variable from the master page as a % as opposed to a hard number, i.e 1 or

    2
    > I get an error, Therfore for the purpose of displaying the page i have put
    > in a hard number (rsLibrary__icategoryid = "1" as opposed to ="%") but of
    > course this only returns to me brochures that belong to categoryID.
    > How do i fix this problem? all my other master/detail pages seem, to work,
    > save this one.
    >
    > To simplify the problem i have created two pages with just the code ( i.e

    no
    > graphics, or templates etc..) that carry the same technology, and have
    > included the relevant source code on the same page, with a .txt extension
    > www.tripakltd.com/brochures1.asp and www.tripakltd.com/brochures1.txt
    > www.tripakltd.com/library1.asp and www.tripakltd.com/library1.txt
    >
    > Can anyone help me sort out this problem?
    >
    > I would greatly appreciate it,
    >
    > Thanks so much
    >
    > Raphael
    >
    >
    Stuart Palmer, Oct 21, 2003
    #2
    1. Advertising

  3. Raphael Gluck

    Ray at Guest

    Hi,

    I think the problem is that you're trying to pull in the product ID from the
    querystring collection, but the form you're using is POSTing the data. So,
    use Request.Form instead of Request.Querystring.

    Ray at work


    "Raphael Gluck" <> wrote in message
    news:...
    > Hi Everyone
    >
    > I am having some problems with a master detail page i have set up to
    > catalogue brochures from my site.
    > On my master page www.tripakltd.com/brochures.asp users are invited to
    > select from a list of brochure categories, then once they press the submit
    > button they will be taken to a different page

    www.tripakltd.com/library.asp
    > The problem i am having, is that when I tell the detail page about the
    > variable from the master page as a % as opposed to a hard number, i.e 1 or

    2
    > I get an error, Therfore for the purpose of displaying the page i have put
    > in a hard number (rsLibrary__icategoryid = "1" as opposed to ="%") but of
    > course this only returns to me brochures that belong to categoryID.
    > How do i fix this problem? all my other master/detail pages seem, to work,
    > save this one.
    >
    > To simplify the problem i have created two pages with just the code ( i.e

    no
    > graphics, or templates etc..) that carry the same technology, and have
    > included the relevant source code on the same page, with a .txt extension
    > www.tripakltd.com/brochures1.asp and www.tripakltd.com/brochures1.txt
    > www.tripakltd.com/library1.asp and www.tripakltd.com/library1.txt
    >
    > Can anyone help me sort out this problem?
    >
    > I would greatly appreciate it,
    >
    > Thanks so much
    >
    > Raphael
    >
    >
    Ray at, Oct 21, 2003
    #3
  4. Thanks for those ideas
    I thought they looked just right to sort it, but when i tried, it still
    didnt work.
    Do you have any other ideas?

    Thanks so much


    Raphael
    Raphael Gluck, Oct 21, 2003
    #4
  5. Hi Ray
    I tried chaging it to Request.Form but still it only works with the "1" and
    not with the "%"

    Do you have any other idea what the cause may be?

    Thanks very much

    Raphael
    Raphael Gluck, Oct 21, 2003
    #5
  6. Raphael Gluck

    Ray at Guest

    The name of your select box is "select" not "categoryID."

    You need to learn how to debug things. (I don't mean that the way it
    sounds.) If you try to go right from point A to point Z and you don't get
    there, you have to look at B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q,
    R, S, T, U, V, W, X, and Y.


    So, you have a form with a select box. The first thing you'd want to do to
    debug this is to verify that the value from the select is being passed.
    Here's what you'd do in library1.txt.


    <%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
    <!--#include file="Connections/Tripak.asp" -->
    <%
    Dim rsLibrary__icategoryid
    rsLibrary__icategoryid = "%"
    If (Request.Form("CategoryID") <> "") Then
    rsLibrary__icategoryid = Request.Form("CategoryID")
    End If

    RESPONSE.WRITE RSLIBRARY_ICATEGORYID
    RESPONSE.END

    What's that tell you?

    It'll tell you that rsLibrary__icategoryID is always %.
    Then you wonder why that is. And you look at that code and you realize that
    it must be because the If line is never true.
    Then you wonder why that is. And you realize that is must mean that
    Request.Form("CategoryID") is never <> "".
    Then you wonder why that is. And you look at the form and realize that you
    didn't name your select "CategoryID."

    Or, you do something like
    <%
    For each x in Request.form
    Response.write x & " = " & request.form(x) & "<br>"
    Next
    RESPONSE.END
    %>

    And you see all the form values. And then you notice that there is no
    request.form("CategoryID"), at which time you realize that you named the
    select wrong.

    Ray at work





    "Raphael Gluck" <> wrote in message
    news:%...
    > Hi Ray
    > I tried chaging it to Request.Form but still it only works with the "1"

    and
    > not with the "%"
    >
    > Do you have any other idea what the cause may be?
    >
    > Thanks very much
    >
    > Raphael
    >
    >
    Ray at, Oct 21, 2003
    #6
  7. Hi Ray,

    Thanks i just changed the Select box, and called it CustomerID and now it
    works,

    But you are right to admonish me. I must learn!
    This was done with a WSYWYG editor (dreamweaver MX) and i really must chuck
    it .
    I have done in principal. I am not using it to go further. I am now catching
    up by going backwards and learning the basics, so as to move forwards.

    Thanks very much

    Raphael
    Raphael Gluck, Oct 21, 2003
    #7
  8. Hi Raphael,
    The solution I suggested was the solution you finally said fixed it.....what
    did you try that didn't work based on my suggestion? Interesting for me as
    if I am not explaining ideas right then it's pointless me suggesting stuff.
    :eek:)

    Stu

    "Raphael Gluck" <> wrote in message
    news:...
    > Thanks for those ideas
    > I thought they looked just right to sort it, but when i tried, it still
    > didnt work.
    > Do you have any other ideas?
    >
    > Thanks so much
    >
    >
    > Raphael
    >
    >
    Stuart Palmer, Oct 21, 2003
    #8
  9. Raphael Gluck

    Adrienne Guest

    Gazing into my crystal ball I observed "Raphael Gluck"
    <> writing in
    news:eGT2mT#:

    > Hi Ray,
    >
    > Thanks i just changed the Select box, and called it CustomerID and now
    > it works,
    >
    > But you are right to admonish me. I must learn!
    > This was done with a WSYWYG editor (dreamweaver MX) and i really must
    > chuck it .
    > I have done in principal. I am not using it to go further. I am now
    > catching up by going backwards and learning the basics, so as to move
    > forwards.
    >
    > Thanks very much
    >
    > Raphael
    >
    >


    May I suggest http://www.chami.com/html-kit . Free, syntax highlighting,
    save your snippets, save your templates, plugins, HTML-Tidy plugin, other
    plugins.

    --
    Adrienne Boswell
    Please respond to the group so others can share
    http://www.arbpen.com
    Adrienne, Oct 22, 2003
    #9
    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. Jon Paal

    Master Detail page problem

    Jon Paal, Nov 19, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    494
    Jon Paal
    Nov 19, 2005
  2. Mark Olbert

    Master Page Button and Detail Page Button

    Mark Olbert, Jan 30, 2006, in forum: ASP .Net
    Replies:
    4
    Views:
    611
    Mark Olbert
    Feb 3, 2006
  3. asmj
    Replies:
    0
    Views:
    492
  4. Arun Kumar Menon

    Master Detail detail

    Arun Kumar Menon, Aug 6, 2003, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    188
    Arun Kumar Menon
    Aug 6, 2003
  5. Frederik Borg

    ASp.net data binding: Master-detail-detail

    Frederik Borg, Jun 9, 2006, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    348
    Frederik Borg
    Jun 9, 2006
Loading...

Share This Page