Tracking time with Applets

Can I use an applet to determine how long a user has spent on a page
Assuming
(a) User Logs in
(b) Visits Page 1 with timer applet
(c) Jumps to Page 2
What kind of applet do I use to determine how long He spent on Page 1?
Plese help
Thanks

How about having the applet (with some primitive looking code similar to)?
(a) User Logs in
(b) Visits Page 1 with timer appletStart the applet, and do something like
long t1 = System.currentTimeMillis(); (c) Jumps to Page 2Once he/she does this, before stopping the page1 applet,
do something like
long t1 = System.currentTimeMillis();
int timeSpentInSecs = (int) (t2-t1)/1000;Then just before destroying the applet, send back some sort of proprietary message containing the timeSpentInSecs to your server (which hosts these applets).
Primitive perhaps, but should work I think!
Comments/criticisms appreciated.
Regards,
Nirmalya

Similar Messages

  • When I recorded a vocal track 3 hours ago, it recorded perfectly. The syncing was perfectly in time with the rest of the song. I just came back to start working on it again, and it's completely off beat. What gives?

    The syncing was perfectly in time with the rest of the song. I just came back to start working on it again, and it's completely off beat. What gives?
    Also, I'd forgotten about this problem until just now, when I extend a loop (for instance, to play 2x instead of just one) it plays a phantom 3rd time. What I mean by this, is there's no track to tell garage band to play it a 3rd time, but it does anyway. If I copy paste the loop, it doesn't do it. I've got no idea what to do with this one. I'd really appreciate a quick response as I'm in the middle of a recording project :/
    Thanks muchly
    Brian

    Hello Brian,
    The syncing was perfectly in time with the rest of the song. I just came back to start working on it again, and it's completely off beat. What gives?
    this may happen, if you accidentally turn on Auto Quantize for the track in the track editor, also "follow tempo and pitch" may cause it. Have you checked the settings?
    As to your strange loop: is it a software instrument loop or a real instrument loop you are talking about?
    If it is a software instrument loop you can look at it in the track editor and delete any extra beats that are revealed by looping. That sometimes happens if there are long notes at the end of the loop.
    Léonie

  • Help with a Times Table Applet.

    Hey,
    I am a college student and I have been given the task of constructing a times table applet. Basically, I am stuck to the point of where I have no clue of what to do next. Even my college tutor is stuck as to what to do. I was wondering if you could give me any aid in helping me develop this applet fully, so that it is correct and functioning. Here it is:
    import java.io.*;
    import Input.*;
    import java.applet.*;
    import java.awt.*;
    import java.awt.event.*;
    abstract class TimesTableApplet extends Applet implements ActionListener
         public void initialize();{}
         String message="";
         public void init()
         Button btnClick= new Button("Enter");
    add(btnClick);
              //String line = null;
              float table = 0, range = 0, attempts = 0;
              int count = 1, reply = 1, lines = 1;
    TextArea textone;
         while(reply==1)
                   String line = null;
                   table = 0;
                   range = 0;
                   ClrScr.ClrScr();
                   textone = new TextArea("",10,30+12*lines);
                   lines=1;
              while (( table < 1) || (table > 20) && attempts <3)
                   textone = new TextArea("Input table from 1-20:",10,10);
                   table = Input.readFloat();attempts++;
              attempts = 0;
                   while (( range < 1) || (range > 14) && attempts <3)
                        textone = new TextArea("Input range 1-14:,10,20");
                        range = Input.readFloat();attempts++;
              if (( table >= 1) && (table <= 20))
                   if (( range >= 1) && (range <= 14))
                   while (count<=range)
                        textone = new TextArea(count + "x" + table + "=" + count * table);
                        count++;
                        lines++;
                   count=1;
                   textone = new TextArea("Would you like another go? Type '1' for yes");
                   reply = Input.readInt();
         }//end while reply ==1
         }//end init
         public void paint(Graphics g)
         int count =1;
         while ( count <=80)
         System.out.println();
         count++;
    }

    Ok, why did you post this code? we will not be able to compile it because we are missing
    the Input package not did you mention wich jar to find this (nor did google).
    Syntax error in initialize
    Usage of the unknown object ClrScr (static method ClrScr)
    Usage of the unknown object Input (static method readFloat and readInt)
    If your tutor is stuck he or she should find a new job.
    import java.io.*;
    import Input.*;
    import java.applet.*;
    import java.awt.*;
    import java.awt.event.*;
    abstract class TimesTableApplet extends Applet implements ActionListener {
         public void initialize(){
         String message = "";
         public void init() {
              Button btnClick = new Button("Enter");
              add(btnClick);
              //String line = null;
              float table = 0, range = 0, attempts = 0;
              int count = 1, reply = 1, lines = 1;
              TextArea textone;
              while (reply == 1) {
                   String line = null;
                   table = 0;
                   range = 0;
                   ClrScr.ClrScr();
                   textone = new TextArea("", 10, 30 + 12 * lines);
                   lines = 1;
                   while ((table < 1) || (table > 20) && attempts < 3)
                        textone = new TextArea("Input table from 1-20:", 10, 10);
                        table = Input.readFloat();
                        attempts++;
                   attempts = 0;
                   while ((range < 1) || (range > 14) && attempts < 3) {
                        textone = new TextArea("Input range 1-14:,10,20");
                        range = Input.readFloat();
                        attempts++;
                   if ((table >= 1) && (table <= 20))
                        if ((range >= 1) && (range <= 14)) {
                             while (count <= range) {
                                  textone = new TextArea(count + "x" + table + "="
                                            + count * table);
                                  count++;
                                  lines++;
                   count = 1;
                   textone = new TextArea(
                             "Would you like another go? Type '1' for yes");
                   reply = Input.readInt();
              }//end while reply ==1
         }//end init
         public void paint(Graphics g) {
              int count = 1;
              while (count <= 80) {
                   System.out.println();
                   count++;
    }

  • I have an iPhone 4S, iPad and MacBook Air.  I'm looking for an app or program where I can track time spent of specific projects each day and also document details of each project.  Is there anything available that is synced through iCloud?

    I have an iPhone 4S, iPad and MacBook Air.  I'm looking for a program or app that I can sync though iCloud that will allow me to us all of these devices to track time spent on projects each day along with the ability to add specific information about each project.  Any suggestions are appreciated! Thanks!

    I recommend you consider Omnifocus.  It is a task management program which runs on the Mac, Iphone & Ipad. I use it for task management and project management.  It let's you store additional information as well.   I sync all three devices through a Mobile Me account and I can enter data on any device and it is available on all devices.  I believe you can also sync through Dropbox.  I'm not sure that you can sync through iCloud yet.  The link to their website is:  www.omnigroup.com.  There may be less expensive alternatives, but this one meets my needs and syncs very well across all devices.

  • SWP works half the time with Vista 64, plus two installs

    Hey all,
     I understand now that SWP only works fully with vista 32 but I do have it working most of the time with vista 64.(only crashed once) My questions are
    1) For some reason on my uninstall folder it shows SWP twice.
    2) When I tried to uninstall one of them its said I was uninstalling part of windows, so I canceled it.
    3) Since its just for vista 32, will running it on vista 64 cause my computers security to be lower than normaL? I mean can a hacker take advantage of the fact that I'm running SWP on vista 64 even though its only made for vista 32.
    Thanks
    Marc
    Message Edited by marchatzi on 10-12-2009 07:35 PM

    Hi Katrina, I am back again.
    Got my Vista-64Bit PC 2 days back. It has been a long 2 days. Today I am trying to get iTunes and my iPod setup, but I am not sure where to go from here.
    I did download iTunes-for Vista 64Bit and installed. Right away it updated to 8.1. No problems. I then copied my entire collection of songs (the same ones from my OLD PC, and managed by iTunes) from the external drive to the NEW C: Drive and to the exactly same named folder.
    Now I don't know how to proceed.
    In the NEW Vista environment, I don't find the same folder structure that was in the old XP PC. The new Vista PC has the following four places with any reference to iTunes and iPOD.
    1. Muisc/iTunes - has 4 files (iTunes Library. iTunes Library Extras, iTunes Library Genius, iTunes Music Library) and i folder (iTunes Music)
    2. C/PKM/iTUnes/iTUnes Music -- this is my creation, and this is where I have all muisc files/tracks etc, was and to be managed by iTunes from this location.
    3. C:/Program Files (X86)/ Apple Software - has 4 files and 3 folders
    4. C:/Program Files (X86)/ iTunes -- has 4 folders and 9 files.
    5. C:/Program Files (X86)/ iPod -- has 1 folder (bin) and 1 file.
    I do NOT see any files with *.itl type extensions.
    I had also exported my Playlists (the file name was music.xml)
    Katrina, where do I go from here? -- need to be able to use the librayr from my old PC, all Ratings from my OLD PC, and my playlists form Old PC, and of course the total libary from the old PC.
    I do have the complete file structures for the OLD PC where iTunes and Apple had saved files and folders - there were three places in addition to my own creation of the location where I ahd saved all the music files. Please let me know if you would like to see the folder structures.
    Thanks.

  • How to include ojdbc.jar with applet in apex

    Hi,
    I am integrating applet with apex. I need to use ojdbc.jar to connect to Database. How can i include this jar. I tried uploading it as a static file. But i am not sure how to embed it with applet code in region source of a page. I am using following code to embed the applet.
    <applet code="TestApplet.class" archive="#APP_IMAGES#Test.jar" width="500" height="500">
    </applet>
    Please suggest how to include the ojdbc.jar.
    Regards,
    Shweta

    Thank you all for help, from your posts I was able to get the datepicker working with a different version of jQuery (but not jQueryUI) included on the page. There are two methods:
    1. Include the new library before #HEAD# and change the reference to a different variable, for example:
    <script src="jquery-1.6.4.min.js" type="text/javascript"></script>
    <script type="text/javascript">
      var jq164 = jQuery;
    </script>
    #HEAD#2. Include the new library after #HEAD# and enable noConflict() mode, for example:
    #HEAD#
    <script src="jquery-1.6.4.min.js" type="text/javascript"></script>
    <script type="text/javascript">
      var jq164 = jQuery.noConflict(true);
    </script>In both examples above, $, jQuery and apex.jQuery point to apex jQuery, while jq164 points to the new one.
    However, I couldn't manage to include a newer version of jQueryUI. I only found a page ([url http://stackoverflow.com/questions/6358961/using-multiple-jquery-ui-versions]http://stackoverflow.com/questions/6358961/using-multiple-jquery-ui-versions) that says you have to specify a different context for each version of jQueryUI included on the same page. I haven't yet had time to look at this, so if anyone already knows how to do it, it would be really nice to share it with us.
    Regards,
    Jure

  • Posted 2 times with no reply - please help

    Hi,
    I'm trying to write an applet that uses a rewritten version of ISNetworks SCP. My applet is used to scp a single file to a server. I dynamically need to name the file(when written on server), so the html that calls the applet is dynamically generated (in a servlet) & feeds the applet the filename(as a param). It works great the first time around. But I want users to be able to reuse this applet as they need. My applet is signed, so the security warning pops up the first time it is used. The next time the applet is run -- it just freezes (it & the browser). I have searched the forums& I see people have had the same type of problem for years (at least back to 1997) --- the jar is cached & the old applet is reused instead of the applet being reloaded. I see no answers in the Forum. The only fix so far is to close down the browser(ie or netscape) totally & restarting again. Here is my applet code
    package heather;
    import java.io.*;
    import java.applet.Applet;
    import java.awt.*;
    import java.awt.event.*;
    import mindbright.ssh.*;
    public class SCAROUpload extends Applet {
    String filename;
    Frame frame;
    AUSSHSCPDialog dialog;
    SSHPasswordAuthenticator pssAuth;
    public void init() {
    pssAuth = new SSHPasswordAuthenticator(AUStats.USER, AUStats.PSSWRD);
    frame = new Frame();
    frame.addWindowListener(new WindowAdapter() {
    public void windowClosing(WindowEvent e) {
    dialog.dispose();
    frame.dispose();
    System.runFinalization();
    System.gc();
    frame.addNotify();
    frame.validate();
    public void start() {
    filename= getParameter("filename");
    dialog = new AUSSHSCPDialog(frame, pssAuth, filename); // the scp dialog
    dialog.show();
    I've tried the following
    - making the applet runnable & running it both with & without a 'start' button
    - launching from within a new window from a JSP
    - launching from a new window - with target="_blank" with in my html link
    Anyone got an answer for this problem? Any help is appreciated!!
    Heather

    I do not have the complete libraries and code to compile your code.
    One thing that comes to mind, if you are using anything Static, test without it. If the Applet reloads fine, then make sure you are using the Static correctly.

  • Printing with applet

    hi
    i am trying to print some text with applet but it is not working here is my code
    sMsg="printing a applet is tough job";
    // Find the default service
    DocFlavor flavor = DocFlavor.BYTE_ARRAY.AUTOSENSE;
    PrintService service[]= PrintServiceLookup.lookupPrintServices(flavor, null);
    // Create the print job
    byte[] b=sMsg.getBytes();
    DocPrintJob job = service[0].createPrintJob();
    Doc doc = new SimpleDoc(b, flavor, null);
    try{
    job.print(doc, null);
    }catch(Exception e){System.out.print(e.getLocalizedMessage());}
    it is not doing anything not even the error is displayed
    when i execute this code i get dialog box which ask me to allow this applet to print or not but after that ,nothing happens.
    plz help me.
    thanks in advance.

    Hans,
    I came across a similar problem a few months ago. I came up with a work-around, and although it's not great, it met the demands of my current project.
    A normal applet can't write files to a user's computer because that could create some big security problems. However, an applet can communicate with the server on which it's located. SO, I created a servlet that resides on the same server. When the user wants to print something from the applet, he clicks a Print button which opens a URLConnection and sends the data to the servlet. The servlet then creates an HTML document on the server and formats the data nicely. Then, back in the applet, I used this line to open a new browser window and show the HTML file:
    getAppletContext().showDocument(new URL(theUrl), "_blank")
    The user can then use the browser's print function to print the data.
    I know it's kind of a roundabout way, but I was pressed for time. Let us know if you come up with something better.
    -sheepy.

  • Is it possible to import Tracking Codes with Cisco WebEx Meetings Server 2.5?

    Is it possible to import Tracking Codes with Cisco WebEx Meetings Server 2.5?

    Hi,
    In documentation, you can find only what is possible and supported in the product. We don't document what is not supported. 
    At this time, there is no feature request submitted for this as I assume no one requested such a feature. If your customer really needs this feature, I advise you to reach out to your/their Cisco Account Manager, explain the feature you would like to see, so they can reach out to Product Management and see if this could be built in the next product version.
    I hope this helps.
    -Dejan

  • HANA procedure call n times with different parameters

    Hi,
    I am implementing some procedures on sql script and due to parallelization reasons i would like to call the same procedure n times with different parameters being the procedure name one of the parameters.
    Which method would you advise me (xsjs, ...)?
    Thanks in advance

    This is a known issue. We plan to have a fix in a future release but there is currently no ETA that I can share with you. I would recommend that you log an SR with support so that we can track the fact that this issue is affecting you.
    Chris

  • On XP Machine dedicated to Lookout 6.5. The Hypertrends are not moving at proper pace according to the scale at the bottom of the trend graph. After 60 seconds it is 40 seconds behind, so the trace makes up the time with a straight line an repeats.

    On XP Machine dedicated to Lookout 6.5.  The Hypertrends are not moving at proper pace according to the scale at the bottom of the trend graph.  After 60 seconds it is 40 seconds behind, so the trace makes up the time with a straight line and then repeats.  Even without any traces on the graph, it does the same thing.
    I've uninstalled and reinstalled the 6.5 software.  Nothing else runs on this machine.  It is dedicated to Lookout.  I've installed a gauge object, with the same datapoint that the hypertrend is trying to graph, that updates very rapidly with no problem, so doesn't appear to be a network problem.
    I'm only tracking one datapoint, at this time, until this issue is solved.  Help please?

    Here is the screen shot.
    Definitions for this post:
     - "streaming data" = Data coming in over ethernet from datapoint that is being polled.
     - "1 scale-second" = 1 second of time based on the scale on the bottom of the graph
    Remember that data continues to trace.  However, according to the scale at the bottom of the graph, the graph traces 60 seconds of streaming data in @10 scale-seconds, then displays .01 second of streaming data over 50 scale-seconds.  The .01 second of data is the long straight lines that you see between the rapid data traces that appear to be 50 scale-seconds.
    Even without any datapoints being traced, the graph clicks forward 1 scale-second every 6 real-time seconds.  It does this for @10 seconds then clicks forward  @50 scale seconds, instantly.  Then repeats, as you can see in the graph.
    The gauge that is on the same control panel, that you see in the screen shot, is tracking the same data point as the graph.  It is polling the data point at real time and never stops updating, so I know that the network is streaming just fine.
    513.850.9509 - if I can help clear things up.
    Attachments:
    LookoutFunkyGraph.jpg ‏347 KB

  • Using JMF with applet

    Hello,
    I've got an applet that consumes a lot of CPU. I'm studying to migrate this applet to a pda, but it's not enough cpu for it. I'm reading JMF docs and I decide to generate a movie with the output of an applet. �If it's possible? My idea is to create the movie on the server. I can modify my applet to avoid the use of the applet inheritance and then render the output to an standard movie format. After I will send the movie to the browser
    You can see the applet here. Click on View route 3D under the flash movie.
    http://www.tmb.net/vullanar/en_US/resultatcerca.jsp?tipusrepre=0&origenx=31514.420&origeny=82758.000&descripcioorigen=L1+-ARCDE+TRIOMF&destix=34704.550&destiy=87378.460&descripciodesti=L2+-ARTIGUES-SANTADRI%C0&tipustransport=0&numtransbords=2&tempscaminant=20&velocitatcaminant=1&tipushora=1&dia=27&mes=05&hora=12&minut=22&idioma=en_US&operador=TMB&poblacioorigen=1&poblaciodesti=1
    Thanks in advance,
    David B.

    passionforjava2 wrote:
    ...I have issues with applet unable to transmit voice using JMF. i know it is a security issue. As the error on the console says
    java.lang.RuntimeException: No permission to capture from applets
    Error : Couldn't create DataSourceWhen JMF is installed, it generally offers a checkbox to allow or deny 'capture in applet'. By default it is not checked, and if the user goes with that recommendation, I am not sure that anything will overrule that.
    In a folder iPhone/myphone/What is the URL where we can visit this applet?
    .. i have applet embedded html file along with .jar files with required classed and applet signed. Are you prompted to trust the digitally signed code? You can see the dialog I mean by visiting the applet linked from [http://pscode.org/test/docload/].
    ..Along with that .jar i do have jmf.jar and java.policy.applet file and jmf.properties file . Forget the policy files, they are a waste of time, and completely impractical for end users.

  • Nano software bug- Track time...

    I just noticed whilst listening to my Nano the track times (both counting upwards and counting the remaining time) skip from time to time by two seconds.
    Does anyone elses Nano misbehave like this?!

    StephenR wrote:I could try updating every album with MP3Tag (www.mp3tag.de/en), although I'm sure I've done that with a few and I think there's still a problem.Product name: Zen Sleek Photo Media Explorer- Version: 5.30.08- Language ID: English- Software ID: ZEN_SLEEK_PHOTO_MEDIA_EXPLORER- Installed path: C:\Programme\Creative\Creative Zen Sleek Photo- Number of components: 0
    Try updating some tags to test with MP3 Library. I've used this a lot in the past and it has always worked for me.
    Also can you try transferring with some other software? e.g. MediaSource
    Normally it's just that the tags aren't read properly, and it's either a tag version or transfer application problem. I'm sure MP3 Tag has caused problems in the past.

  • Ipod touch stolen: can apple reset settings/track it with the serial number?, Ipod touch stolen: can apple reset settings/track it with the serial number?

    Ipod touch stolen: can apple reset settings/track it with the serial number?, Ipod touch stolen: can apple reset settings/track it with the serial number?

    This question has been asked multiple times, no Apple CANNOT track an iPod with it's Serial Number.

  • ITunes track time issue

    I am using iTunes 8.02.20 on Windows Vista Ultimate Service Pack 1 and since I installed this version of iTunes when I import a CD the time listed on the track is correct. Once imports when I look at the same file in the library I see the track time as 789:57:13 listed as the track time on all the tracks imported.
    Any suggestions would be great. thanks!

    Bummer, sounds like it might be some bug, then, if itunes 7 is OK.
    How about your import settings - are you using MP3, AAC, AIFF, or what?
    If MP3, are you using VBR?
    Does it work with any other import setting, so you could report it to Apple?

Maybe you are looking for