DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: how to convert the type of session variable

  1. #1
    venkat Guest

    how to convert the type of session variable


    hai
    i tried to increment the value of a session variable
    i declared like this
    <% session("marks")%> =0

    i tried to increment
    markss = <%session("marks")

    markss = markss+1

    marls<% response.write(markss)
    it writes in the browser as marks 10

    any suggestion

  2. #2
    Sachin Guest

    Re: how to convert the type of session variable

    use CInt Function if it is holding Integer or CSng if holding Single/Float:-

    markss = Cint(Session("marks"))

    Tia
    Sachin
    "venkat" <venkatesan_ram@eudoramail.com> wrote in message
    news:3b57c8dc$1@news.devx.com...
    >
    > hai
    > i tried to increment the value of a session variable
    > i declared like this
    > <% session("marks")%> =0
    >
    > i tried to increment
    > markss = <%session("marks")
    >
    > markss = markss+1
    >
    > marls<% response.write(markss)
    > it writes in the browser as marks 10
    >
    > any suggestion




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