You must Sign In to post a response.
  • Category: .NET

    How to set the time using asp .net c# application

    In my application i have 4 modules where first moudle has 20 questions second module has 15 questions third module has 15 questions fourth module has 10 questions
    now i need to set the time for these modules in such a way that first module of exam is for 15min (for 20 ques), second module 15 min (for 15 que), third module 15 min (for 15 que) and fourth module 10min (for 10ques) if the above time is completed but still the candidate is pending the test then user should get a msg that time limit is finished and hence the test was submitted how can i do this using asp .net c#
  • #769556
    Hi Bhavya,

    You need to set a timer on your master screen . You can use readymade Jquery plugins for this or can use simple setInterval of javascript. As soon as timer exhaust, meaning when time elapse you can do needful.

    Anjali Bansal

    Anjali Bansal

    ~Give your best and lead the world

  • #769698
    try to check with below script and place countdowntime control on master page or in module page itself.

    <script type="text/javascript">
    var timeleft = 15; //module one time for 20 questions
    var downloadTimer = setInterval(function(){
    document.getElementById("countdowntimer").textContent = timeleft;
    if(timeleft <= 0)

    on every last question of module click, try to reinitialize the timeleft variable value with relevant time in minutes.

    Hope this works.

    B.Ramana Reddy

  • Sign In to post your comments