Results 1 to 4 of 4

Thread: Customizing the Status Line

  1. #1
    Kenneth McLain Guest

    Customizing the Status Line

    is the a way to customize the status line?

    example:

    Rec [1 to 25] of 35 GridRow=25

    what about:

    Showing #`s 1-25 of 35 records

  2. #2
    John Guest

    Customizing the Status Line (reply)

    Hi Kenneth,

    It turns out that there are session variables that you can output to display your own custom message. Today, they are:

    SV_RECORDCOUNT_unitno = total number of recs
    SV_RECORDPOINTER_5 = current record pointer
    SV_GRIDSTART_5 = first record shown on screen
    SV_GRIDINC_5 = how many records shown on each "page" (dbGridInc).

    So, to display your example: Showing #`s 1-25 of 35 records you would use:

    (after the %> of the ASP-db table with a dbUnit=99)

    Showing #`s <% =Session("SV_GRIDSTART_99") %> -
    <% =Session("SV_GRIDSTART_99") + Session("SV_GRIDINC_99") - 1 %> of
    <% =Session("SV_RECORDCOUNT_99") %> records.

    These variables should be stable and you`re welcome to display them. They`re defined in the documentation. Just look for "SV_GRID" and you`ll see where they`re all defined.

    Hope this helps!

    John





    On 9/17/98 6:18:40 AM, Kenneth McLain wrote:
    > is the a way to customize the status line?

    example:

    Rec [1 to 25]
    > of 35 GridRow=25

    what about:

    Showing #`s 1-25 of 35 records

  3. #3
    Ralph Asbury Guest

    Customizing the Status Line (reply)

    O.K. I got the custom record count to display correctly. But what if I want to use frames? Here`s what I have.

    Left Frame is a Filter form (code is as follows):

    <html>

    <head>
    <title>Brochure Inventory</title>
    <base target="main">
    </head>

    <body bgcolor="#FFFFFF">
    <%
    Set MyDb=Server.CreateObject("ASPdb.Pro")
    MyDb.dbMDB = Server.MapPath("BrochureInventory.mdb")
    MyDb.dbUnit = "2"
    MyDb.dbColor = "4,auto"
    MyDb.dbMode = "dual-horiz"
    MyDb.dbFilterDropFlds = "Subject,,BrochureListing,Subject;Primary,,Brochur eListing,Primary"
    MyDb.dbStartUp = "filter"
    Flds = "Subject,Primary,heading=Choose a Subject, Primary, or a combination of both, then click the <b>Apply Filter</b> button"
    MyDb.dbFilterFlds = Flds & ",Style=Simple"
    MyDb.dbGridTableTag = "BORDER=3"
    MyDb.dbFormTableTag = "BORDER=3"
    MyDb.dbSQL = "SELECT * FROM BrochureListing"
    MyDb.dbGridDisplayFlds = "2,3,4"
    MyDb.dbMemoTextSize = "-1"
    MyDb.dbNavigation = "top"
    MyDb.dbGridInc = "10"
    MyDb.dbGridIndex = "false"
    MyDb.dbMagicCell = "Subject,,#Subject#,index,indexanchor"
    MyDb.dbNavigationIcon = "std"
    MyDb.dbStatusBar = "false"
    MyDb.ASPdbPro
    %>

    <p align="center">Showing Brochures <% =Session("SV_GRIDSTART_2") %> - <% =Session("SV_GRIDSTART_2") + Session("SV_GRIDINC_2") - 1 %> of <% =Session("SV_RECORDCOUNT_2") %> Brochures. </p>
    </body>
    </html>

    Right frame is a blank page.

    Can I get the custom record count to display in the right frame only, after the Apply Filter button is pressed.
    Also, is it possible to NOT have the "Dropdown?" button display. If this button is pressed, then the text entry fields are displayed in the right frame due to the <base target="main"> designation.

  4. #4
    John Guest

    Customizing the Status Line (reply)

    Hi Ralph,

    Easy question first: Check the manual under dbFilterParams and you`ll see:

    "Use DropButtonText=none to hide the toggle button. Default="DropDown ?"

    See? Told you it was easy!

    Now, for the frames stuff...

    Your code looks ok. You`re just dumping the contents of the session variables in the right hand frame. I think the problem however, may be that the right hand frame is not getting "refreshed". When you click on a link in a frame it doesn`t affect the neighboring frames.

    The easiest way to prove this, would just to use IE and right click in that right hand frame and choose "Refresh". If it shows up, then that`s the problem! Solving it might be done by setting the expiration in the header, or by using JavaScript. You could just put a little function in the <BODY> tag that has an OnLoad=... function which refreshes the right hand window. That`s probably the easiest way. If you want to make it simple, just put the whole JavaScript statement right in the OnLoad function (don`t even bother to call a function in the HEAD). For one-liners, this seems to work fine.

    Good luck and feel free to reply and post your results & code snippets here that you used!

    Thanks,
    John


    On 9/17/98 4:54:21 PM, Ralph Asbury wrote:
    > O.K. I got the custom record count to display correctly. But what if I want
    > to use frames? Here`s what I have.

    Left Frame is a Filter form (code is
    > as follows):

    <html>

    <head>
    <title>Brochure Inventory</title>
    <base
    > target="main">
    </head>

    <body bgcolor="#FFFFFF">
    <%
    Set
    > MyDb=Server.CreateObject("ASPdb.Pro")
    MyDb.dbMDB =
    > Server.MapPath("BrochureInventory.mdb")
    MyDb.dbUnit = "2"
    MyDb.dbColor =
    > "4,auto"
    MyDb.dbMode = "dual-horiz"
    MyDb.dbFilterDropFlds =
    > "Subject,,BrochureListing,Subject;Primary,,Brochur eListing,Primary"
    MyDb.db
    > StartUp = "filter"
    Flds = "Subject,Primary,heading=Choose a Subject,
    > Primary, or a combination of both, then click the <b>Apply Filter</b>
    > button"
    MyDb.dbFilterFlds = Flds & ",Style=Simple"
    MyDb.dbGridTableTag =
    > "BORDER=3"
    MyDb.dbFormTableTag = "BORDER=3"
    MyDb.dbSQL = "SELECT * FROM
    > BrochureListing"
    MyDb.dbGridDisplayFlds = "2,3,4"
    MyDb.dbMemoTextSize =
    > "-1"
    MyDb.dbNavigation = "top"
    MyDb.dbGridInc = "10"
    MyDb.dbGridIndex =
    > "false"
    MyDb.dbMagicCell =
    > "Subject,,#Subject#,index,indexanchor"
    MyDb.dbNavigationIcon =
    > "std"
    MyDb.dbStatusBar = "false"
    MyDb.ASPdbPro
    %>

    <p
    > align="center">Showing Brochures <% =Session("SV_GRIDSTART_2") %> - <%
    > =Session("SV_GRIDSTART_2") + Session("SV_GRIDINC_2") - 1 %> of <%
    > =Session("SV_RECORDCOUNT_2") %> Brochures. </p>
    </body>
    </html>

    Right
    > frame is a blank page.

    Can I get the custom record count to display in
    > the right frame only, after the Apply Filter button is pressed.
    Also, is
    > it possible to NOT have the "Dropdown?" button display. If this button is
    > pressed, then the text entry fields are displayed in the right frame due to
    > the <base target="main"> designation.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •