Subject: Really need help
Posted By: izyani Post Date: 1/4/2006 9:53:19 PM
Dear All,

I already create an ASP Page..

<%
'Author : Yani
'Date    : 29 Dec 2005
'Purpose: To read out.txt file

dim nextAspPage
nextAspPage=resetPINOut.asp

dim nextAspPage1
nextAspPage=generateKeyPairOut.asp

dim nextAspPage2
nextAspPage=insertCertificateOut.asp

dim nextAspPage3
nextAspPage=deleteCertificateOut.asp

dim nextAspPage4
nextAspPage=insertURLOut.asp

dim nextAspPage5
nextAspPage=deleteURLOut.asp


If session("check") = true then
    'Read the data(respond from server) filename : ->out.txt
    Dim writefs
    Dim wfile
 
    Set writefs = Server.CreateObject("Scripting.FileSystemObject")
    Set wfile = writefs.OpenTextFile("c:\out.txt")
    filecontent = wfile.ReadAll
    wfile.close

    strLength=Len(filecontent)

    'check length
    If strLength=24 Then
    dataOut=filecontent
    session("content") = dataOut

    Else
        Set readfs = Server.CreateObject("Scripting.FileSystemObject")
        Set a = readfs.CreateTextFile("c:\error.txt", True)
        a.WriteLine (filecontent)
        a.Close
    End If
    
    'to indicate which file to execute
    If session("filename") = true then
        response.redirect nextAspPage
    Elseif session("filename1") = true then
        response.redirect nextAspPage1
    Elseif session ("filename2") then
        response.redirect nextAspPage2
    Elseif session("filename3") then
        response.redirect nextAspPage3
    Elseif session("filename4") then
        response.redirect nextAspPage4
    Else
        response.redirect nextAspPage5
    End If
    
End If

%>

but I got this error..

Error Type:
Microsoft VBScript runtime (0x800A01A8)
Object required: 'resetPINOut'
/ResetPINin/readFile.asp, line 8


anyone could hep me to fix it?

thank you

Reply By: jbenson001 Reply Date: 1/4/2006 11:46:02 PM
Try posting in the ASP forum.. this forum is for ASP.NET

Reply By: planoie Reply Date: 1/5/2006 9:12:48 AM
If you intend this to be a string assignment, you need quotes:

nextAspPage="resetPINOut.asp"

-Peter
Reply By: mat41 Reply Date: 1/5/2006 6:02:04 PM
FYI: Next time point point out line 8 in your code. This helps others help you quicker.  Imagine if it was line 808. Dont know about others but I wouldnt count your lines.

BTW: You need to put all these pages names within quotes like planoie has suggested above.  your next error will be here:

nextAspPage=generateKeyPairOut.asp
Should be:
nextAspPage="generateKeyPairOut.asp"




Wind is your friend
Matt
Reply By: mat41 Reply Date: 1/5/2006 6:05:02 PM
jbenson001
This is not the .net area

izyani
Ignore that post, you are in the correct area.


Wind is your friend
Matt

Go to topic 38322

Return to index page 402
Return to index page 401
Return to index page 400
Return to index page 399
Return to index page 398
Return to index page 397
Return to index page 396
Return to index page 395
Return to index page 394
Return to index page 393