Web Analytics Made Easy -
StatCounter Page Auto refresh - CodingForum

Announcement

Collapse
No announcement yet.

Page Auto refresh

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Page Auto refresh

    Hi,

    I am trying to auto refresh a jsp page, however I loose my parameters ie

    http://localhost:8080/Custom/proper...p?Propkey=18488,

    when the page refreshes

    http://localhost:8080/Custom/proper...ty.jsp?Propkey=

    What I want to do is load the next parameter after 18488, next being 18489.

    I have created a stored proc that takes the current parameter and finds the next parameter ie:

    CREATE proc CustomPropertyiGetNextKey
    @PreviousPropertyKey int,
    @ThisPropertyKey int output
    as
    select
    @ThisPropertyKey = min(PropertyKey)
    from
    propertyi..tblProperties with (nolock)
    where
    propertykey > @PreviousPropertyKey
    and deleted = 0

    select @ThisPropertyKey

    I want to exec this proc each time my page refreshes, taking the previous parameter and finding the next

    Currently using this Javascript code:

    <script language="Javascript">
    var URL = "[email protected]"
    var speed = 5000
    function reload()
    {
    location = URL
    }
    setTimeout("reload()", speed);
    </script>

    I am still new at JSP, Servlets and Javascript, can anyone advise me, but of a steep challange for me.
Working...
X