Need some help on fixing a playback issue

I have this code(sorry that it's messy it's not actually mine, but i do have to fix it ><)...this script controls a player. The player has a playhead. The problem with the playhead is
1) When the user drags the playhead when it's paused, the playhead will continue moving...i can't figure out how to stop it! (However if the player is playing, dragging the playhead should not pause it.
2) If the user drags the playhead while paused and clicks play...the player will turn the sound on...but not continue playing....
I have a feeling it's a simple fix but i know very little about actionscript. You can see i tried to fix it in the comment /* section but failed horribly...
Any advice on how to fix this bug?
Many thanks in advance...here is the code
var isPlaying:Boolean = false;
var currentclip:MovieClip;
var intervalID:Number;
var intervalID2:Number;
var plen:Number = 450;
var sX:Number = -231.75;
var eX:Number = 248.25;
var clipTotalFrames:Number;
var clipCurrentFrame:Number;
var mySound:Sound;
var soundPosition:Number = 0;
var audioInterval:Number = 0;
var vol:Number;
var isFading:Boolean = false;
function initapp () : Void {
          mySound = new Sound();
          mySound.attachSound("talk");
          mySound.onSoundComplete = function () {
                    soundPosition = 0;
                    playAudio();
          clearAllClips();
          createButtons();
          initUIControls();
          uiclip.playicon._visible = true;
          uiclip.pauseicon._visible = false;
          clicktoplay.onRelease = function () {
                    seletTab("b1");
                    this._visible = false;
// AUDIO Controls
function playAudio () : Void {
          trace("called");
          mySound.start(soundPosition,0);
          soundPosition = 1;
function stopAudio () : Void {
          soundPosition = Math.round(mySound.position/1000);
          mySound.stop();
function fadeOutAudio () : Void {
          vol = 100;
          audioInterval = setInterval(fadeOut, 100);
          isFading = true;
function fadeOut() : Void {
          vol -= 8;
          mySound.setVolume(vol);
          // put an if condition to restrict the increment in volume after it reaches to 100
          if (vol<=0) {
                    clearInterval(audioInterval);
                    mySound.setVolume(0);
                    uiclip.volumeButton.gotoAndStop(2);
                    mySound.stop();
                    soundPosition = 0;
                    stopAudio();
                    isFading = false;
                    soundPosition = 0;
                    trace("soundPosition = " + soundPosition);
function manualPP () : Void {
          if (mySound.getVolume() == 0) {
                              mySound.setVolume(100);
                              uiclip.volumeButton.gotoAndStop(1);
                              playAudio();
                    } else {
                              mySound.setVolume(0);
                              uiclip.volumeButton.gotoAndStop(2);
                              stopAudio();
// END AUDIO Controls
function initUIControls () : Void {
          uiclip.playButton.onRelease = function () {
                    clearInterval(intervalID);
                    clearInterval(intervalID2);
                    doPlayPause();
                    manualPP();
                    doPlayHead("play");
          uiclip.playhead.onPress = function () {
                    clearInterval(intervalID);
                    clearInterval(intervalID2);
                    doPlayHead();
                    uiclip.playicon._visible = true;
                    uiclip.pauseicon._visible = false;
                    currentclip.stop();
                    isPlaying = false;
                    intervalID2 = setInterval(scrubPlayHead, 10);
                    startDrag(this, false, -231.75, this._y, 218.25, this._y);
          uiclip.playhead.onRelease = uiclip.playhead.onReleaseOutside = function () {
                    stopDrag();
                    clearInterval(intervalID2);
                    /*if (uiclip.pauseicon._visible == false) {
                    //mySound.setVolume(0);
                    //doPlayPause();
                    doPlayHead("play");
                    //currentclip.stop();
                    trace("play icon is visible? if won");
                    else {
                    currentclip.stop();
                    //mySound.setVolume(100);
                    uiclip.playicon._visible = false;
                    uiclip.pauseicon._visible = true;
                    trace("else won");
                    doPlayPause();
                    //doPlayHead("play");
          doPlayPause();
          doPlayHead("play");
          uiclip.volumeButton.onRelease = function () : Void {
                    if (mySound.position == 0) return;
                    if (mySound.getVolume() == 0) {
                              mySound.setVolume(100);
                              this.gotoAndStop(1);
                              playAudio();
                    } else {
                              mySound.setVolume(0);
                              this.gotoAndStop(2);
                              stopAudio();
function doPlayHead (action:String) : Void {
          if (action == "play") {
                    intervalID = setInterval(playPlayHead, 10);
          } else {
                    clearInterval(intervalID);
function playPlayHead () : Void {
          playHeadCalculator();
function playHeadCalculator () : Void {
          clipTotalFrames = currentclip._totalframes;
          clipCurrentFrame = currentclip._currentframe;
          var posPercent:Number = (clipCurrentFrame / clipTotalFrames) * 100;
          var newXplus = (posPercent * .01) * plen;
          uiclip.playhead._x = sX + newXplus;
          uiclip.mybarmask._x = uiclip.playhead._x - 456.5;
          if (currentclip._currentframe == currentclip._totalframes) {
                    currentclip.stop();
                    clearInterval(intervalID);
                    clearInterval(intervalID2);
                    doPlayPause();
                    if (currentclip._name == "reqclip") {
                              fadeOutAudio();
function scrubPlayHead () : Void {
          var posPercent:Number = ((uiclip.playhead._x + 232) / plen) * 100;
          var newXplus = Math.round((posPercent * .01) * currentclip._totalframes);
          currentclip.gotoAndStop(newXplus);
          uiclip.mybarmask._x = uiclip.playhead._x - 456.5;
          //trace("scrubbed the playhead");
function resetPlayHead () : Void {
function doPlayPause () : Void {
          if (isPlaying) {
                    uiclip.playicon._visible = true;
                    uiclip.pauseicon._visible = false;
                    currentclip.stop();
                    isPlaying = false;
                    clearInterval(intervalID);
                    clearInterval(intervalID2);
          } else {
                    uiclip.playicon._visible = false;
                    uiclip.pauseicon._visible = true;
                    if (currentclip._currentframe != currentclip._totalframes) {
                              currentclip.play();
                    } else {
                              currentclip.gotoAndPlay(2);
                    isPlaying = true;
function createButtons () : Void {
          for (var i:Number = 1; i < 5; i++) {
                    uiclip["b" + i].isSelected = false;
                    uiclip["b" + i].ID = "b" + i;
                    uiclip["b" + i].onRelease = function () {
                              seletTab(this.ID);
                    uiclip["b" + i].onRollOver = function () {
                              if (this.isSelected == false) {
                                        // this.gotoAndStop(2);
                    uiclip["b" + i].onRollOut = uiclip["b" + i].onReleaseOutside = function () {
                              if (this.isSelected == false) {
                                        // this.gotoAndStop(1);
          uiclip.b1.isSelected = true;
          uiclip.b1.gotoAndStop(2);
          intclip._visible = true;
          intclip.gotoAndStop(1);
          currentclip = intclip;
function seletTab (idname:String) : Void {
          var skipReset = false;
          switch (idname) {
                    case "b1" :
                              if (intclip == currentclip) {
                                        skipReset = true;
                              break;
                    case "b2" :
                              if (benclip == currentclip) {
                                        skipReset = true;
                              break;
                    case "b3" :
                              if (reqclip == currentclip) {
                                        skipReset = true;
                              break;
                    case "b4" :
                              if (faqclip == currentclip) {
                                        skipReset = true;
                              fadeOutAudio();
                              break;
          if (skipReset == false) {
                    if (isPlaying) {
                              uiclip.playicon._visible = true;
                              uiclip.pauseicon._visible = false;
                              currentclip.stop();
                              isPlaying = false;
                    clearAllClips();
                    doPlayHead();
          clearInterval(intervalID);
          clearInterval(intervalID2);
          switch (idname) {
                    case "b1" :
                              intclip._visible = true;
                              intclip.gotoAndPlay(2);
                              currentclip = intclip;
                              uiclip.b1.isSelected = true;
                              uiclip.b1.gotoAndStop(2);
                              break;
                    case "b2" :
                              benclip._visible = true;
                              benclip.gotoAndPlay(2);
                              currentclip = benclip;
                              uiclip.b2.isSelected = true;
                              uiclip.b2.gotoAndStop(2);
                              break;
                    case "b3" :
                              reqclip._visible = true;
                              reqclip.gotoAndPlay(2);
                              currentclip = reqclip;
                              uiclip.b3.isSelected = true;
                              uiclip.b3.gotoAndStop(2);
                              break;
                    case "b4" :
                              faqclip._visible = true;
                              faqclip.gotoAndPlay(2);
                              currentclip = faqclip;
                              uiclip.b4.isSelected = true;
                              uiclip.b4.gotoAndStop(2);
                              break;
          isPlaying = true;
          uiclip.playicon._visible = false;
          uiclip.pauseicon._visible = true;
          trace(idname + " - " + isFading + " - " + soundPosition);
          if (idname != "b4" && isFading == true) {
                    clearInterval(audioInterval);
                    mySound.setVolume(0);
                    uiclip.volumeButton.gotoAndStop(2);
                    stopAudio();
                    soundPosition = 0;
                    isFading = false;
          if (idname != "b4" && soundPosition == 0) {
                    mySound.setVolume(100);
                    playAudio("talk");
                    uiclip.volumeButton.gotoAndStop(1);
          doPlayHead("play");
function clearAllClips () : Void {
          for (var i:Number = 1; i < 5; i++) {
                    uiclip["b" + i].isSelected = false;
                    uiclip["b" + i].gotoAndStop(1);
          benclip._visible = false;
          benclip.gotoAndStop(1);
          reqclip._visible = false;
          reqclip.gotoAndStop(1);
          intclip._visible = false;
          intclip.gotoAndStop(1);
          faqclip._visible = false;
          faqclip.gotoAndStop(1);
          isPlaying = false;
initapp();

Yea...I was afraid of that....
Well I have someone who will try to help me out tonight. Hopefully he will be able to make heads or tails of this. I wish the guy that coded this didn't just stick everything in one piece so it would be easier to break it up in my head.

Similar Messages

  • The backup disk image "/Volumes/Data/David Witkowski's Mac Pro.sparsebundle" is already in use.  Whenever Time Machine starts to backup to Time Capsuel I get the previous error message. I need some help to fix this.

    The backup disk image “/Volumes/Data/David Witkowski’s Mac Pro.sparsebundle” is already in use.  Whenever Time Machine starts to backup to Time Capsuel I get the previous error message Where can I find this disk image?. I need some help to fix this.
    Thanks,
    David W

    There are multiple answers and solutions if you look just to the right under the heading of More Like This.

  • Need some help in fixed WLAN in my N81

    Hi All,
    I have an N81. When i connect to WLAN, it is getting configured. But when I try to access the internet through that WLAN accesspoint, i get an error message "Connection not available"  i am sure the WLAN is working fine, as WLAN is from my router and my frnd tried the same frm is Nokia express music to connect to the WLAN and browse.
    Kindly help me to fix this issue.
    Thanks and Regards
    Jaianandh 

    Check if some other app (e-mail?) is already using the connection.
    ‡Thank you for hitting the Blue/Green Star button‡
    N8-00 RM 596 V:111.030.0609; E71-1(05) RM 346 V: 500.21.009

  • Messed up my I Tunes, need some help with fixing it, details in first post.

    Okay, so I was doing some maintence on my computer, organising files, etc. and i accidentally moved a file labled itunes onto my desktop, which caused all my songs in my itunes to go away, i put the file back, and all the song titles are there now, but it says that none of them can play because it can't find the origional file or something like that. can anyone help me?

    More details, please...did you ever stop and restart itunes in the middle of this?

  • My iPhone 3g has 2 white horizontal lines i don't know where did it came from. I turn it off then on but its still there. the lines spreads everyday. I dont know how to fix it. need some help guys.

    my iPhone 3g has 2 white horizontal lines i don't know where did it came from. I turn it off then on but its still there. the lines spreads everyday. I dont know how to fix it. need some help guys.

    If you take a screenshot (Press the home button and Lock button at the same time), does it appear on the screenshot? Zoom in on the screenshot and see if it's still there.
    If not, then your display is failing. I would recommend taking it to an Apple Store if you can, if you can't then to an authorised Apple reseller.
    If it does appear on the screenshot when you zoom into the spot, then it's a really weird software issue! You might have to backup and restore the device.
    Let me know!
    xeni

  • Need some help with the Select query.

    Need some help with the Select query.
    I had created a Z table with the following fields :
    ZADS :
    MANDT
    VKORG
    ABGRU.
    I had written a select query as below :
    select single vkorg abgru from ZADS into it_rej.
    IT_REJ is a Work area:
    DATA : BEGIN OF IT_REJ,
            VKORG TYPE VBAK-VKORG,
            ABGRU TYPE VBAP-ABGRU,
           END OF IT_REJ.
    This is causing performance issue. They are asking me to include the where condition for this select query.
    What should be my select query here?
    Please suggest....
    Any suggestion will be apprecaiated!
    Regards,
    Developer

    Hello Everybody!
    Thank you for all your response!
    I had changes this work area into Internal table and changed the select query. PLease let me know if this causes any performance issues?
    I had created a Z table with the following fields :
    ZADS :
    MANDT
    VKORG
    ABGRU.
    I had written a select query as below :
    I had removed the select single and insted of using the Structure it_rej, I had changed it into Internal table 
    select vkorg abgru from ZADS into it_rej.
    Earlier :
    IT_REJ is a Work area:
    DATA : BEGIN OF IT_REJ,
    VKORG TYPE VBAK-VKORG,
    ABGRU TYPE VBAP-ABGRU,
    END OF IT_REJ.
    Now :
    DATA : BEGIN OF IT_REJ occurs 0,
    VKORG TYPE VBAK-VKORG,
    ABGRU TYPE VBAP-ABGRU,
    END OF IT_REJ.
    I guess this will fix the issue correct?
    PLease suggest!
    Regards,
    Developer.

  • Need some help! My iPhone 4 cannot play music through it's built in speaker, only with headphones. I also cannot adjust volume, it only shows "ringer". I really do not know when it starts. I already clean the jack and dock,reset it. Update it to IOS 7.1.1

    Need some help! My iPhone 4 cannot play music through it's built in speaker, only with headphones. I also cannot adjust volume, it only shows "ringer". I really do not know when it starts. I already clean the jack and dock,reset it and still cannot be fixed. I updated it to IOS 7.1.1 recently only, does it have connection with the inconvenience I am experiencing right now? What should I do? Thanks!

    Hi Melomane1024,
    If you are still having issues with your iPhone’s speaker, you may want to look at the steps in this article -
    iPhone: No sound or distorted sound from speaker
    http://support.apple.com/kb/TS5180
    Thanks for using Apple Support Communities.
    Best,
    Brett L

  • Need some help with guitar setup...

    jeez, never thought i'd be asking a question like this after playing for like 20 years, but i need some help with a guitar setup for mac. i'm gonna list out a lot of crap here that prolly doesn't affect anything at all, but here goes.
    Imac 17inch G4 - latest updated OS X... 10.4, or 5, or whatever. garageband 3.0
    digitech gnx-3
    alesis sr-16
    sure mic's
    yamaha e203 keyboard
    here's the setup:
    yamaha is on its own on a usb uno midi interface, sure's connected to gnx's xlr port, alesis connected to gnx's jam-a-long input, '87 kramer vanguard connected to gnx's guitar input. currently running headphones out on gnx to line in on mac.
    here's the problem:
    everything works beautifully, but my guitar sounds like crap. if i plug headphones into the gnx, it sounds beautiful. that makes me think its some kind of level issue between the gnx's output, and the mac's input, but nothing seems to fix it.
    by sounding like crap, i mean way too much bass. sound is muddy, blurry, not crisp... aka crap. i've tried altering both output and input on mac and gnx, and i cant get a combination that works. the gnx has a s/pdif out, can the mac accept that as input? might that help? short of running the gnx to my marshal half stack and mic'ing that, anyone have any suggestions, or use a similar setup?
    any help would be greatly appreciated!

    anyone? ... any suggestions? I think it might be an issue with the gnx pre-amping the signal as it goes out, and then the mac amping it on the way in, giving me a buttload more signal than i need, but since i cant find a happy level, i'm not really sure. i really dont want to resort to mic'ing my marshall... even with the volume almost off, my jcm900 is WAY too loud for apartment use. its not like i really NEED the guitar to sound perfect, i only use garageband to sketch out ideas for songs between myself and bandmates, but its really annoying to not have my customary crisp distortion. my bass player keeps telling me to use the built in amps, but, not to dis a practically free program, but the built in amps blow, at least after 10 years of marshall tube amplification they do. if anyone has any suggestions that might be helpfull on how i might resolve this, i would be your best friend for life and go to all your birthday parties

  • Need some help with Xcode

    I'm new to xcode and need some help.
    i have written app and it easily launches etc.
    but when i add background image to the ui app doesnt launch even though it says that there are no issues.
    it highlights these lines in green and says:"thread 1 programm received signal:"SIGABRT"":
        return NSApplicationMain(argc,  (const char **) argv);

    I figured out how to solve our problem. I was using a Web View, and I had to add the Webkit.framework to my project to fix it.
    I am not sure what framework if for images...sorry...
    If you can find the framework, just add it to fix the problem...
    Hope I helped!
    Thanks,
    Adam B

  • HT204291 When am watching live news on air play it shows only for  one minute 30 seconds I need some help?

    When am watching live news on air play it only shows for one minute 30 seconds ,, I need some help?

    First of all, Hunt--thanks for responding!
    "First, where are you playing the MPEG-2, that you see that jitter?"
    On both a MacBook Pro, an Acer laptop and my Mac Tower. I would love to think that it is a problem with the playback system, and that if I merely send the file off to the duplicator they won't have the same problem. Maybe that is the case...I don't know if I have a choice rather than sending it off to see. But it happens in the same spots, in the same way, on all three of the players so I'm a little reluctant to have faith.
    "Another thing that can cause jitter in an MPEG-2 is the Bit-Rate - higher the Bit-Rate, the better the quality, but the larger the file. For a DVD, one is limited by the total Bit-Rate (both Audio & Video), but with longer prodcutions, some users choose too low a Bit-Rate. If this is the issue, one would need to go back to the original Project and do a new Export/Share."
    Of course, but in the case there is no more 'original project.' It is gone like the wind, stolen along with his computer and backups.
    I think I am stuck using one of two files as my master: a DVD he burned where I only see the stutter/vibration/jitter once, or the mpeg2 file where I see it three times. Hopefully, the duplication house can rip if off of one of them and not see the jitter. I know that in audio, my personal filed, you can do a lot to enhance already existing sound--EQ, compression, tape saturation emulation software, etc. I guess I'm hoping there is some kind of analog to the video world that address jitter after a source has been printed--if indeed the source has been printed to be jittery.
    Thanks,
    Doug

  • My airport problem has returned big time --Need some Help!!

    Aloha once again:
    I though that this was fixed by simply changing channels on my airport router, but that fix only lasted for a few days, but now it's back and even worse. Let me give you some background on this problem. Here's my original message concerning the problem:
    I have my Airport Router connected to the Internet via DSLcable. I then tie my two computers into the internet via their airport cards. For about 6 months this system has been working just fine. Recently my desktop computer quit listening to the router and can no longer connect to the internet. It shows no signal strength and the name of the network on the Airport is not seen in the "connect to internet" panel. The same Airport works just fine on my LapTop and I am using it right now to get this message off to the internet.
    I have fixed permissions, removed the airport card and cleaned the connector, the antenna plug and removed the system configuration folder from library preferences all to no avail!
    This problem has been hounding me, intermittently, for over a year now What can I do to remedy this??? HELP!!!!
    Dan Page
    Maui, Hawaii
    The suggestion to change channels, that came from this original request, worked but just for a very short time. Now I have to shut down my computer overnight to get connected and then it only lasts for several hours and the connection quits.
    I thought maybe heat was a problem, but the last time it happened I opened the computer and played a large fan right on the card. This did not help. I shut it down for the night and it was fine the next morning for about 2 hours.
    One new data point; if I turn off just the airport on my laptop computer overnight, that will fix the problem for a short time also.
    Still need some help!!!
    Dan

    First, power off both the Time Capsule and AirPort Express.
    Wait a few minutes, then power up the Time Capsule first, and let it run for a few minutes.
    Temporarily, move the AirPort Express to the same room or close proximity to the AirPort Express and power it up.
    If the Express powers up correctly, power it off again and move it approximately half the distance between the Time Capsule and the general area that needs more wireless coverage. Try to minimize obstructions like walls, ceiling, heavy furniture, etc as much as possible. 
    Please report on your results.

  • Need some help with downloading PDF's from the net.

    need some help with downloading PDF's from the net.  Each time I try to click on a link from a website, if it takes me to a new screen to view a pdf, it just comes up as a blank black screen?  any suggestions?

    Back up all data.
    Triple-click the line of text below to select it, the copy the selected text to the Clipboard (command-C):
    /Library/Internet Plug-ins
    In the Finder, select
    Go ▹ Go to Folder
    from the menu bar, or press the key combination shift-command-G. Paste into the text box that opens (command-V), then press return.
    From the folder that opens, remove any items that have the letters “PDF” in the name. You may be prompted for your login password. Then quit and relaunch Safari, and test.
    The "Silverlight" web plugin distributed by Microsoft can also interfere with PDF display in Safari, so you may need to remove it as well, if it's present.
    If you still have the issue, repeat with this line:
    ~/Library/Internet Plug-ins
    If you don’t like the results of this procedure, restore the items from the backup you made before you started. Relaunch Safari again.

  • We have a set of oracle clients running on T5220 zones that need some help

    Greetings all -
    We have a set of oracle clients running on T5220 zones that need some help.
    If, for example, I execute the query "select (all) from dba_objects", trace output reports 90% of the elapsed time spent under "SQLNet message from client".
    Here are OS details for the clients: Solaris 10 5/08 s10s_u5wos_10 SPARC
    Running "uname -a" from the client gives:
    (SunOS bmc-ste-app 5.10 Generic_127127-11 sun4v sparc SUNW,SPARC-Enterprise-T5220)
    Here are OS details for the dataserver: Enterprise Linux Enterprise Linux Server release 5.2
    Running "uname -a" from the dataserver gives:
    (2.6.18-92.1.6.0.2.el5 #1 SMP Thu Jun 26 17:44:55 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux)
    The RDBMS is 10.2.0.4
    Again, please note, there is no application in the picture here. We are just running a simple catalog query (select * from dba_objects) from sqlplus. Why the wait on something like this? The wait also occurs when a different query is used (select (all) from SYS.COL$ where rownum < 50000). And it doesn't matter if I used the full client or the instant client. I still get the same high-wait.
    We had thought - maybe this is a network thing - so we put a test client on the same subnet as the dataserver. This helped - but not enough. The wait is still way too high even with firewalls taken out of the equation.
    We've also looked at arraysize, SDU, kernel settings. And we've spent time going over tkprof, truss and sqlnet-tracing.
    Has anyone ever had to solve this HIGH WAIT ON CLIENT issue? Is there a work around or some tweak I'm missing.
    Is anyone configured like we are (linux dataserver, solaris clients)? If so - did you see anything like this?
    tia -
    Jim
    Edited by: jim1768 on Mar 31, 2010 1:47 PM
    Edited by: jim1768 on Mar 31, 2010 2:12 PM
    Edited by: jim1768 on Mar 31, 2010 2:13 PM

    Hello,
    We have the exact same issue. Did you ever solve this issue? We have a t5220 and have just upgraded our 11.5.10.2 11i system on it from 9.2.0.8 32-bit sparc to 11.2.0.1 64-bit sparc. Things should be faster but arent, and our consultant has tracked it down to high wait times when the apps tier using forms connects to the database tier on the same box. So even though the t5220 is both server and client, there is something about the client sql connection.through TNS that his having trouble. Thanks for any information. We've also created an S/R with Oracle.
    Note: I am well aware of the other issues with the CMT server series but this particular issue seems independent of the regular / known issues and remains a mystery to us. Other known issues with the CMT servers for SPARC:
    Metalink Note 781763.1 (Migration from fast single threaded CPU machine to CMT UltraSPARC T1 & T2)
    http://blogs.sun.com/glennf/resource/Optimizing_Oracle_CMT_v1.pdf
    http://blogs.sun.com/glennf/tags/throughput
    http://blogs.sun.com/glennf/entry/getting_past_go_with_sparc
    http://www.oracle.com/apps_benchmark/doc/E-Bus-11i-PAY_ORA_SUN-T5220.pdf (this paper has some oracle init settings at the end. The kernel settings have been included in the OS upgrade)
    http://blogs.sun.com/mandalika/entry/siebel_on_sun_cmt_hardware

  • Need to try to find Pi, need some help

    I have need to try to find some of the values of Pi,
    but when i try math.PI i only get down to like 8 decimals.
    I need some help.
    Not sure were to start either!
    Message was edited by:
    Aten

    You're just adding terms together. There's a series of them, so you need a loop. Each pass through the loop could add one more term. Note that each term has a denominator that is bigger by 2, and it's either added or subtracted (or to look at it another way, you're adding negatives alternately).
    The main issue is how accurate you want it to be. You can't add the digits together forever. So you have to choose a stopping point. You can stop based on a time period (when you've run out of time, stop adding new terms) or on precision (when two subsequent values are close enough to each other, stop).
    You'll probably want to use java.math.BigDecimal.
    If you give some more details about the assignment I can make some more suggestions.
    Why don't you give it a try and see how it works?

  • HT1222 I need some help.... I Have the iPhone 4S and downloaded the new software (6.0) and everything seems great so far except when I try to open a link in safari from a different app (messages, Facebook, ext..) it glitches and won't load. Any advice?

    I need some help.... I Have the iPhone 4S and downloaded the new software (6.0) and everything seems great so far except when I try to open a link in safari from a different app (ie..messages, Facebook, ect..) it glitches and won't load. The blue loading bar will just jump back and forth and the page will not load properly if at all....

    It sounds like you may have multiple problems, but none of them are likely to be caused by malware.
    First, the internet-related issues may be related to adware or a network compromise. I tend to lean more towards the latter, based on your description of the problem. See:
    http://www.adwaremedic.com/kb/baddns.php
    http://www.adwaremedic.com/kb/hackedrouter.php
    If investigation shows that this is not a network-specific issue, then it's probably adware. See my Adware Removal Guide for help finding and removing it. Note that you mention AdBlock as if it should have prevented this, but it's important to understand that ad blockers do not protect you against adware in any way. Neither would any kind of anti-virus software, which often doesn't detect adware.
    As for the other issues, it sounds like you've got some serious corruption. I would be inclined to say it sounds like a failing drive, except it sounds like you just got it replaced. How did you get all your files back after the new drive was installed?
    (Fair disclosure: I may receive compensation from links to my sites, TheSafeMac.com and AdwareMedic.com, in the form of buttons allowing for donations. Donations are not required to use my site or software.)

Maybe you are looking for

  • Can I edit a Clip Notes PDF?

    Hello, I'm using Adobe Premiere Pro CS3 to export QuickTime files to PDF. Since the URL is entered with the Clip Notes dialog, is there a way to change this URL in the PDF after it has been created? I do have Acrobat Professional. I did figure out th

  • Which version lightroom for non-intel mac 10.5.8

    Which Version of Lightroom works best with a (non-Intel) Mac 10.5.8?  Thank You.

  • "database logon" option for schedule report

    When scheduling a report, Crystal report has the "database logon" option in "shcedule" property page. But I can't find the "database logon" option for webi report or deski report. Is this by design.

  • GridControl & rowSetInfo

    I'm a bit new to this game, so apologies if the following seems trivial... I've developed a simple client / server application where the client GUI is accessing details from a data module server. Both were built using the JDeveloper wizards. The clie

  • Cannot upgrade to OSx Lion no Recovery

    I purchased and tried to install the OSx Lion upgrade. My mac is running Mac OSx 10.6.8 and I have bootcamp with Windows 7 It seems that there is some sort of problem in upgrading the OS when bootcamp is installed, but I am not sure of which would be