List/Menu set value equal to

Ask a Question related to Dreamweaver AppDev, Design and Development.

  1. #1

    Default List/Menu set value equal to

    I have a list/menu that I have manually entered the values to and then applied
    DWMX 04's Dynamic list server behaviour to so that it initially selects the
    value stored in the database. However it's not selecting anything.

    I can output the field value using:
    <%=(registrations.Fields.Item("paymentStatus").Val ue)%>

    The recordset code is:
    <%
    Dim registrations__MMColParam
    registrations__MMColParam = "1"
    If (Request.Form("registrationID") <> "") Then
    registrations__MMColParam = Request.Form("registrationID")
    End If
    %>
    <%
    Dim registrations
    Dim registrations_numRows

    Set registrations = Server.CreateObject("ADODB.Recordset")
    registrations.ActiveConnection = MM_dsn_botr_STRING
    registrations.Source = "SELECT * FROM tbl_Users WHERE registrationID = " +
    Replace(registrations__MMColParam, "'", "''") + ""
    registrations.CursorType = 0
    registrations.CursorLocation = 2
    registrations.LockType = 1
    registrations.Open()

    registrations_numRows = 0
    %>



    The form code is:
    <select name="paymentStatus">
    <option value="Not Yet Received" <%If (Not
    isNull((registrations.Fields.Item("paymentStatus") .Value))) Then If ("Not Yet
    Received" = CStr((registrations.Fields.Item("paymentStatus").V alue))) Then
    Response.Write("SELECTED") : Response.Write("")%>>Not Yet Received</option>
    <option value="Received" <%If (Not
    isNull((registrations.Fields.Item("paymentStatus") .Value))) Then If ("Received"
    = CStr((registrations.Fields.Item("paymentStatus").V alue))) Then
    Response.Write("SELECTED") : Response.Write("")%>>Received</option>
    <option value="Processing" <%If (Not
    isNull((registrations.Fields.Item("paymentStatus") .Value))) Then If
    ("Processing" = CStr((registrations.Fields.Item("paymentStatus").V alue))) Then
    Response.Write("SELECTED") : Response.Write("")%>>Processing</option>
    <option value="Approved" <%If (Not
    isNull((registrations.Fields.Item("paymentStatus") .Value))) Then If ("Approved"
    = CStr((registrations.Fields.Item("paymentStatus").V alue))) Then
    Response.Write("SELECTED") : Response.Write("")%>>Approved</option>
    </select>


    your help is appreciated.

    thanks,
    mark.

    newflavour Guest

  2. Similar Questions and Discussions

    1. How to list menu items in the "Comments" menu?
      well, now i have a problem ,which can not list the submenu of "Comments" and "Tools" menu? Did anyone meet this problem before? Details : I use...
    2. List/Menu Form hides dropdown Menu
      http://2006.maximizer.com/about/customers/index.html when you scroll over 'company' in the main navbar at the top of the page, you'll see what...
    3. List/Menu help
      My submit button is not corresponding to my pull down menu. I have a pull down menu with two values (google, ebay)....as soon as you select one and...
    4. List menu ?
      how to a retrieve the value from a database and put it into a list menu ?
    5. Menu/list ( menu ) in topframe and mouse scrolling
      I've made a menu ( with an arrow next to it and the choices appear when you click that arrow - I forgot what this is called in English :))in the...
  3. #2

    Default Re: List/Menu set value equal to

    ok, while cooking dinner I had a brain wave. What if DW wasn't the issue but my
    DB was.

    Well, I opened the DB and changed the column "paymentStatus" from 'memo' to
    'text' and it now works. This is fine for now, but does anyone have a fix for
    DB columns that are set to 'memo'?

    newflavour Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139