Using WaitFor1.0 issue

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • JayB

    Using WaitFor1.0 issue

    After searcing the archives and www.aspfaq.com I found software called
    waitfor1.0 that I can use to make my script pause for a few seconds before
    resuming. I'm using this to send email to a list of subscribers on our
    database (about 10,000). I want to send 250 emails, wait for a little bit,
    send another 250 and so on until all emails are sent. If I set it up so it
    pauses for two seconds, it works fine. When I pause it for five seconds, I
    get an error pop-up that says 'The document contains no data'.

    Is this a timeout issue with ASP or may SQL Server (where the data is)? Any
    other suggestions or ideas?

    In the following example I'm simply trying to write the email addresses to
    the browser. This is my test environment and is also where I'm getting the
    error message.

    <%
    Dim rs, ConStr, conn, i, WaitObj

    Set WaitObj = Server.CreateOb ject ("WaitFor.Comp" )
    ConStr = "Provider=SQLOL EDB; Data Source=PCIS; Database=E-News_Test; User
    Id=jerry; Password=jerry"
    set conn = CreateObject("A DODB.Connection ")
    conn.open ConStr
    set rs = conn.execute("E XEC enewsSendTesth" )

    do while not rs.eof
    strCount = strCount + 1
    response.write strCount & ". " & rs("EmailAddres s") & " " & time &
    "<br>"
    rs.movenext
    if i = 249 then
    WaitObj.WaitFor Seconds 5
    i = 0
    else
    i = i + 1
    end if
    loop

    rs.close
    Set conn = nothing
    Set rs = nothing
    Set WaitObj = nothing
    %>

    Thanks,

    --
    JayB


  • JayB

    #2
    Re: Using WaitFor1.0 issue


    "JayB" <jerry280@yahoo .com> wrote in message
    news:3votd.6851 $_t6.5876@news0 1.roc.ny...[color=blue]
    > After searcing the archives and www.aspfaq.com I found software called
    > waitfor1.0 that I can use to make my script pause for a few seconds before
    > resuming. I'm using this to send email to a list of subscribers on our
    > database (about 10,000). I want to send 250 emails, wait for a little bit,
    > send another 250 and so on until all emails are sent. If I set it up so it
    > pauses for two seconds, it works fine. When I pause it for five seconds, I
    > get an error pop-up that says 'The document contains no data'.
    >
    > Is this a timeout issue with ASP or may SQL Server (where the data is)?
    > Any other suggestions or ideas?[/color]

    It was the timeout setting for my IIS. I had to increase it to allow my
    script to finish running (it's located on an internal server, not a public
    web server).

    --
    JayB


    Comment

    • Ray Costanzo [MVP]

      #3
      Re: Using WaitFor1.0 issue

      Please read this. http://www.aspfaq.com/show.asp?id=2291

      Ray at work

      "JayB" <jerry280@yahoo .com> wrote in message
      news:86qtd.6878 $kA6.2755@news0 1.roc.ny...[color=blue]
      >
      > "JayB" <jerry280@yahoo .com> wrote in message
      > news:3votd.6851 $_t6.5876@news0 1.roc.ny...[color=green]
      > > After searcing the archives and www.aspfaq.com I found software called
      > > waitfor1.0 that I can use to make my script pause for a few seconds[/color][/color]
      before[color=blue][color=green]
      > > resuming. I'm using this to send email to a list of subscribers on our
      > > database (about 10,000). I want to send 250 emails, wait for a little[/color][/color]
      bit,[color=blue][color=green]
      > > send another 250 and so on until all emails are sent. If I set it up so[/color][/color]
      it[color=blue][color=green]
      > > pauses for two seconds, it works fine. When I pause it for five seconds,[/color][/color]
      I[color=blue][color=green]
      > > get an error pop-up that says 'The document contains no data'.
      > >
      > > Is this a timeout issue with ASP or may SQL Server (where the data is)?
      > > Any other suggestions or ideas?[/color]
      >
      > It was the timeout setting for my IIS. I had to increase it to allow my
      > script to finish running (it's located on an internal server, not a public
      > web server).
      >
      > --
      > JayB
      >
      >[/color]


      Comment

      • JayB

        #4
        Re: Using WaitFor1.0 issue

        Thanks Ray, I'll take a look!

        --
        JayB

        "Ray Costanzo [MVP]" <my first name at lane 34 dot commercial> wrote in
        message news:u7yda3S3EH A.2568@TK2MSFTN GP11.phx.gbl...[color=blue]
        > Please read this. http://www.aspfaq.com/show.asp?id=2291
        >
        > Ray at work
        >
        > "JayB" <jerry280@yahoo .com> wrote in message
        > news:86qtd.6878 $kA6.2755@news0 1.roc.ny...[color=green]
        >>
        >> "JayB" <jerry280@yahoo .com> wrote in message
        >> news:3votd.6851 $_t6.5876@news0 1.roc.ny...[color=darkred]
        >> > After searcing the archives and www.aspfaq.com I found software called
        >> > waitfor1.0 that I can use to make my script pause for a few seconds[/color][/color]
        > before[color=green][color=darkred]
        >> > resuming. I'm using this to send email to a list of subscribers on our
        >> > database (about 10,000). I want to send 250 emails, wait for a little[/color][/color]
        > bit,[color=green][color=darkred]
        >> > send another 250 and so on until all emails are sent. If I set it up so[/color][/color]
        > it[color=green][color=darkred]
        >> > pauses for two seconds, it works fine. When I pause it for five
        >> > seconds,[/color][/color]
        > I[color=green][color=darkred]
        >> > get an error pop-up that says 'The document contains no data'.
        >> >
        >> > Is this a timeout issue with ASP or may SQL Server (where the data is)?
        >> > Any other suggestions or ideas?[/color]
        >>
        >> It was the timeout setting for my IIS. I had to increase it to allow my
        >> script to finish running (it's located on an internal server, not a
        >> public
        >> web server).
        >>
        >> --
        >> JayB
        >>
        >>[/color]
        >
        >[/color]


        Comment

        Working...