Professional Web Applications Themes

Setting a value from a dataset as a variable in asp.net - Dreamweaver AppDev

My page loads and creates a dataset, and also collects data from the url I want to compare the data from the url with value from the recordset (i have an SQL statement that sorts the data to one record, being the lowest in the list of records) REM Retrieve parameters from the query string Dim m_from as string = Request('Originator') Dim m_to as string = Request('Destination') Dim m_body as string = Request('Body') Dim m_rbid as string = Request('RBID') Dim m_date as string = Request('Date') Dim m_time as string = Request('Time') REM Just testing by outputting to page Response.Write('from: ' ...

  1. #1

    Default Setting a value from a dataset as a variable in asp.net

    My page loads and creates a dataset, and also collects data from the url I
    want to compare the data from the url with value from the recordset (i have an
    SQL statement that sorts the data to one record, being the lowest in the list
    of records) REM Retrieve parameters from the query string Dim m_from
    as string = Request('Originator') Dim m_to as string =
    Request('Destination') Dim m_body as string = Request('Body') Dim
    m_rbid as string = Request('RBID') Dim m_date as string = Request('Date')
    Dim m_time as string = Request('Time') REM Just testing by
    outputting to page Response.Write('from: ' + m_from + ' ')
    Response.Write('to: ' + m_to + ' ') Response.Write('body: ' + m_body + '
    ') Response.Write('rbid: ' + m_rbid + ' ') Response.Write('date: ' +
    m_date + ' ') Response.Write('time: ' + m_time + ' ') REM
    Apply logic here REM Compare the incoming bid with the lowest
    current bid from the database Dim varLobid = I want to put the
    dataset value here, but using DataSet1.FieldValue('Body', container) just
    gives an error, saying expected ')' and various other odd error's depending how
    i try and write it If m_body < varLobid then Any help greatly appreciated!

    rix1505 Guest

  2. #2

    Default Re: Setting a value from a dataset as a variable inasp.net

    Originally posted by: rix1505
    My page loads and creates a dataset, and also collects data from the url I
    want to compare the data from the url with value from the recordset (i have an
    SQL statement that sorts the data to one record, being the lowest in the list
    of records) REM Retrieve parameters from the query string Dim m_from
    as string = Request("Originator") Dim m_to as string =
    Request("Destination") Dim m_body as string = Request("Body") Dim
    m_rbid as string = Request("RBID") Dim m_date as string = Request("Date")
    Dim m_time as string = Request("Time") REM Just testing by
    outputting to page Response.Write("from: " + m_from + " ")
    Response.Write("to: " + m_to + " ") Response.Write("body: " + m_body + "
    ") Response.Write("rbid: " + m_rbid + " ") Response.Write("date: " +
    m_date + " ") Response.Write("time: " + m_time + " ") REM
    Apply logic here REM Compare the incoming bid with the lowest
    current bid from the database Dim varLobid = I want to put the
    dataset value here, but using DataSet1.FieldValue("Body", container) just
    gives an error, saying expected ')' and various other odd error's depending how
    i try and write it If m_body < varLobid then Any help greatly appreciated!



    Cirwon Guest

  3. #3

    Default Re: Setting a value from a dataset as a variable inasp.net

    Well, I have found a partial answer through trial and error.

    You can assign the value to a hidden asp text box and use the on click event
    to process your code.

    <asp:TextBox ID="txtYEMAIL" Visible="false" runat="server" Text=<%#
    dsGETEMAIL.FieldValue("EMAIL", Container) %> />

    Unfortunatly I haven't found a way to do this in the page on load event.

    Cirwon Guest

Similar Threads

  1. Need help with setting a variable using xml
    By GDrider in forum Macromedia Flash Data Integration
    Replies: 1
    Last Post: April 28th, 03:52 AM
  2. converting data from a dataset to a variable
    By baz0hara in forum Macromedia Dynamic HTML
    Replies: 1
    Last Post: October 26th, 11:22 AM
  3. Assigning a table value from a dataset to a variable
    By blitzed2010 in forum Dreamweaver AppDev
    Replies: 1
    Last Post: April 29th, 07:37 PM
  4. Pass Dynamic Variable in MM:DataSet
    By ralerta in forum Dreamweaver AppDev
    Replies: 0
    Last Post: April 8th, 07:11 PM
  5. Setting a variable name with a variable in a loop
    By DAYohn in forum Coldfusion - Advanced Techniques
    Replies: 4
    Last Post: March 17th, 08:40 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not 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