I have asp questions to response.write


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 5 of 5

Thread: I have asp questions to response.write

  1. #1
    Join Date
    Jun 2006
    Posts
    5

    I have asp questions to response.write

    Hello,

    I am using asp not asp.net please forgive me for posting in the .net section I did not see a plan asp...

    But anyway..

    I am trying to use response.write in a if statement, and I want it to output to a specific column in my table.. when I place the if statment in the section I want it and run it I get a syntax error..
    Can you please help

    my code is a follows for the if statement. I am pulling a result from the SQL server if it matches I have my first response if it does not I have my second response. it sounded simple to me but I am having a boohoo of a time.. Thanks for your help


    <% if (answerRS.Fields.Item("q1").Value) = "1" then
    Response.write = "Correct"
    Else Response.Write = "Incorrect"
    End If%>

  2. #2
    Join Date
    Jun 2004
    Location
    Pakistan
    Posts
    292
    take out the equal signs, it should be Response.write("Correct")
    new to programming but getting ther

  3. #3
    Join Date
    Jun 2006
    Posts
    5
    Thank you

    I tried what you suggested, and I get a error now:
    ------------
    Microsoft VBScript compilation Error '800a03ea'

    Syntax Error

    /smpx/smpxresul3.asp, line 69

    Else Response.write"Incorrect"
    ------------

    There is Triangle underneath the Else too..


    On line 69 I have this piece of code
    ---------
    Else Respoonse.write "Incorrect"
    ----------
    IF you have any other ideas please let me know..

    Thank you

  4. #4
    Join Date
    Feb 2004
    Posts
    126
    Hi mwrightladhs use
    Response.Write("Incorrect") not
    Respoonse.write "Incorrect"
    Patrick

  5. #5
    Join Date
    Jun 2006
    Posts
    5
    Got it, thank you

Similar Threads

  1. Hi! Opening Word Doucment in ASP
    By jatinder_raheja in forum VB Classic
    Replies: 0
    Last Post: 06-02-2005, 03:22 AM
  2. Replies: 8
    Last Post: 01-09-2003, 09:42 PM
  3. ASP questions - mainly printing
    By dandy in forum ASP.NET
    Replies: 0
    Last Post: 08-27-2001, 04:00 PM
  4. Re: Bitten by the ASP
    By Keith Franklin, MCSD in forum Talk to the Editors
    Replies: 18
    Last Post: 09-27-2000, 11:48 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center