Help background timer
I want to program alarms that go off when the my app is NOT active or currently running.
TimerTask myTask = new myTimerFunc(); myTimer = new Timer(); myTimer.scheduleAtFixedRate(myTask, 6000, 6000);
The timer is triggered if the application is active, but as soon as I leave the timer app does not work.
How the timer running in the background?
You must leave your app on (at least this is what I do).
UiApplication.getUiApplication () .requestBackground ();
Tags: BlackBerry Developers
Similar Questions
-
I need help understanding Time Machine.
I've got 2 MacBooks, 1 desktop computer Mac G5 and an external HD to 3 TB (Seagate). Can I save all 3 HDs to an external HD? And what will happen if I delete entire folders of an original HD? The backup will keep all those the next time I'm back up? And he keeps them forever?
Tutorials video, references, etc. you must help my understanding is appreciated.
Thank you
Steve
Here are some basics:
Use Time Machine to back up or restore your Mac - Apple Support
-
Although I've owned a mac for years, I started using Time Machine a few months ago only.
For two weeks, I said that my backup disk was full. Today, I got the message that the backup failed and that yesterday was the most recent upward. a double click on the backup disk, I see the records dating back to November. However, when I get Time machine, I can only highlight yesterday.
So, a few questions.
1. the November record is really an existing back-up? Why do I see there, but not in Time Machine?
2. I have several external hard drives that I use for Time Machine and I am interested in finding someone to help me with the best solution to achieve my goal. That is, to remove the 300 GB of photos I have on my internal hard drive to an external hard drive, while still supporting upward from my internal hard drive and a multimedia hard drive for Time Machine.
I hope I can say this is not confusing.
I have an internal 500 GB running 10.11.1 HD because I have pictures of some 300 GB internal hard disk, I only 6.66 GB of available space.
I have 3 external drives available that I can use for the back upward. 1 TB, I got for Christmas and is not used for anything and 2 500 GB HDs... one of them is currently used for Time Machine. The other has a backup is no longer necessary, so I can be erased.
In addition to using Time Machine to back up, I also pay a monthly fee for Crash Plan. Even though this was my home folder files, it does not back up the operating system. I can, however, point it to back up an external hard drive.
Finally, these are my questions. To free up space on my internal hard drive, can I (should) move the photos off my internal HD (I don't use iphoto) and put them on an external HD and then have my internal HD and HD with photos backed up with TM? Would it not be better to transfer my photos on a 500 GB HD and then use the 1 TB (without this partitioning) to back up both the internal and external HDs?
I hope that what I am asking is logical. Thanks to all those who want to take part of my ramblings and give a meaning to me.
Respectfully,.
Cayleen
What I do with my Mac sounds a bit like what you ask to do with yours. I have:
-Photos and movies on an external drive (500 GB on a 2 TB disk)
-The rest of my data on the drive internal (approximately 300 GB on a 1 TB drive
-The internal and external are saved on a third drive (3 TB) used for Time Machine.
Everything works very well.
-
Hi all
I want a table to check-in, like this, using now()
However, when I insert Now() in C2, all cells will change
Someone help me with this? million thanks
now it a function that returns the date and time when the service is updated. This means that whenever the table recalculates and then value now() returns will also be updated.
What you ask, is a timestamp. Strictly speaking, the numbers do not have a time stamp.
You can create a simple and easy to use work around by creating a table cell that contains the now() function
any time you want to enter a timestamp, select cell A1 in the single cell table,
copy
now select the cell where you want the timestamp
and use the menu option "Edition > paste formula results" or use the combination of keys
+ + v -
need a little help with time calculation
Hello
I tried to implement oauth2 and youtube api. I can connect and can recover the access_token and other oauth required as expires_in json values.
What I'm trying to do is drive if my access token is valid or not before making another call to their api - youtube gives a value - expires_in that normally contains 3600, which I suppose is seconds. I'm trying to add this time now using clock_gettime(), but I don't get correct values for my calculation - nowTime + expiresInt.
Anyone can point out the problem with my code please? It could be a bad way to do it, but I thought that I spent a few hours on this subject before asking for help.
Thank you.
token = c.value("access_token").toString().toStdString(); refreshtoken = c.value("refresh_token").toString().toStdString(); saveValueFor("access_token", QString::fromStdString(token)); string expires = c.value("expires_in").toString().toStdString(); saveValueFor("refresh_token", QString::fromStdString(refreshtoken)); struct timespec* start; clock_gettime(CLOCK_REALTIME, start); int nowTime = start->tv_sec; std::stringstream str(expires); int expiresInt; str >> expiresInt; nowTime += expiresInt; stringstream nowTimeString;//create a stringstream nowTimeString << nowTime;//add number to the stream
Now you install milliseconds and seconds.
-
So I want to create a timer that displays an image after 6 seconds. Here is an example of my code:
var timer1:Timer; //start handleTimerTick function after 1 second timer1 = new Timer(1000); timer1.addEventListener(TimerEvent.TIMER,handleTimerTick); timer1.start(); private function handleTimerTick():void { this.addChild(icon); }
but the right icon wouldn't show. Any help? Or are there better ways to do this?
I don't know if it's a typo or not, but the function should be:
handleTimerTick(e:TimerEvent):void
aside from that, nothing seems to be wrong. looks like your icon code?
-
IRQL_NOT_LESS_OR_EQUAL appeared when I was running just chrome, MUtorrentz, download a movie... nothing else has been charged on the cpu. But it showed the error... Do not know what to do? IM-tense... IAM not a technophile. so please someone help me :'(:(
Here are the Minidump and msinfo32 onedrive zipped file:
https://onedrive.live.com/?CID=3CFADFC6344DFA0A&ID=3CFADFC6344DFA0A%21104
Thanks ananya sister. but now, I found that it was fake OS so I re turned into windows 7 Home Edition premium, the version is authentic. BT, it is over heating and battery time down 3.45 hours to 2 hours only :(:(:(:(Aidez_moi pelase)
-
Help from time to time sync problem with my 5ESXi
Hello world
Hope you all are doing great! Hope you can help. I did some research but I'm still confused.
Currently, I just installed the 5ESXi on a Dell Server freeware. A host of virtual machine, I installed 2 servers vm Windows 2008R with VM Tools installed, which one of them would be the domain controller. I would ask:
1.) how to set up the time setting for the virtual machine to Windows server? At present, the ' comments Syncronize time withhost "is not checked (which is default).
2.) on the host of VM - Configuration - Configuration at the time of the... Should what settings I configure? Right now, I checked on "Activate" the NTP client. In OPTIONS, what options should I choose (starts automatically... Start and stop the host... Start and stop manually... etc)?
3.) associated with #2, I would add the NTP source in Options?
I am very concerned about the time on the server vm domain controller... and I hope that would help you in this...
Thank you very much ahead of it.Takami Chiro
Here are the best practices for time synchronization VMware...
http://KB.VMware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalID=1318
1.) how to set up the time setting for the virtual machine to Windows server? At present, the ' comments Syncronize time withhost "is not checked (which is default).
You'll want to fill #2 below before enabling this option, but I would recommend going with this method of time synchronization instead of having every hour to synchronize VM with a domain controller...
2.) on the host of VM - Configuration - Configuration at the time of the... Should what settings I configure? Right now, I checked on "Activate" the NTP client. In OPTIONS, what options should I choose (starts automatically... Start and stop the host... Start and stop manually... etc)?
In general, I put each ESXi host to synchronize time with a domain controller. You'll want to start and stop with the host country, but you will first need to set some time synchronization servers in the options. You can choose dns names or IP addresses.
3.) associated with #2, I would add the NTP source in Options?
Yes, you must add an NTP source before you can activate start/stop with the host.
Once you choose to synchronize time with a domain controller, I'll make sure that your domain controllers are the synchronization of time with another source of time. You can find time servers NTP free on internet, I usually go with one of them. Microsoft has one that you can use as well.
Here are two sites that I have used before:
I hope this helps...
Ben
-
Hello, at the moment I am working on a first person shooter, not one of those seen on youtube where the cannon moves and the background remains in place, but vice versa. Right now I'm trying RADIUS it therefore, when you press the 'UP' button, you will open a menu where you can not shoot, aim.etc I got 1 problem, how I rig it so when I close upwards, the bottom stops moving? The code I am using for the background is:
{onClipEvent (enterFrame)}
Mouse.Hide ();
This ._x =-_root._xmouse + 400;
This ._y =-_root._ymouse + 200;
}Help, please!
BTW, you can chech on the beta version of this game at Newgrounds.com, by user: HarryboEntertainment
Control the execution of the code is to introduce a conditional.
{onClipEvent (enterFrame)}
{if (allowMovement)}
Mouse.Hide ();
This ._x =-_root._xmouse + 400;
This ._y =-_root._ymouse + 200;}
}When you press the UP key you set the variable allowMovement set to false, and whatever you do to resume play would be it true once again. You may need to adjust the targeting of the variable.
-
Banner XML. Need help with timer
Hello everyone. So, I want to create a banner of xml, but each image to have its own clock, defined in the xml file. for example, I want my first image to disappear after 5 seconds, the 2nd after 3 seconds, the 3rd after 2 sec etc..
my xml looks like this:
[CODE]
<? XML version = "1.0" encoding = "utf-8"? >
< drag DELAY = "2" >
< URL = "images/1. jpg of image" DESCRIPTION = "Lorem" DELAY = "5" / > "
< URL = "images/2.jpg of image" DESCRIPTION = "Nam blandit" DELAY = "2" / > "
< URL = "images/3.jpg of image" DESCRIPTION = "Cras" DELAY = "3" / > "
< URL = "images/4.jpg of image" DESCRIPTION = "Nulla sed" DELAY = "10" / > "
< URL = "images/5.jpg of image" DESCRIPTION = 'Vivamus.' " DELAY = "1" / >
< / slide >
[/ CODE]The action script code looks like this:
[CODE]
Import fl.transitions.Tween;
Fl.transitions.easing import. *;
var _delay:int = 0;
var _total:int = 0;
var _images:XMLList = null;
var _loaders:Array = new Array();
var _counter:int = 0;
var _next:int = 0;
var _timer:Timer = null;
var _tween:Tween = null;
var _container:Sprite = new Sprite();
var _text:TextField = new TextField();
var _loader:URLLoader = new URLLoader();
_loader. Load (new URLRequest ("data.xml"));
_loader.addEventListener (Event.COMPLETE, complete, false, 0, true);
function Complete(e:Event):void
{
var _xml:XML = new XML (e.target.data);
_loader. RemoveEventListener (Event.COMPLETE, complete);
_loader = null;
_xml.image = _images;
_Total = _images.length ();
LoadImages();
}
function loadimages (): void
{
for (var i: int = 0; i < _total; i ++)
{
_delay = _images[i].@DELAY;
trace (_delay)
var _url:String = _images[i].@URL;
var _loader:Loader = new Loader();
_loader. Load (new URLRequest (_url));
_loader.contentLoaderInfo.addEventListener (Event.COMPLETE, ImageLoaded);
_loaders.push (_loader);
}
}
function ImageLoaded(e:Event):void
{
_Counter ++;
If (_counter is _total)
{
SetupSlider();
}
}
function SetupSlider (): void
{
addChild (_container);
_TEXT. Selectable = false;
_Text.width = 450;
_TEXT. Height = 50;
_Text.x = 0;
_Text.y = 0;
addChild (_text);
NextImage();
_Timer = new Timer(_delay*1000,0);
_Timer.addEventListener (TimerEvent.TIMER, TimerListener);
_Timer.start ();
}
function TimerListener(e:TimerEvent):void
{
love ++;
If (love == _total)
{
love = 0;
}
NextImage();
}
function NextImage (): void
{
if(_container.numChildren>0)
{
_container.removeChildAt (0);
}
_loaders [love] .alpha = 0;
_container.addChildAt(_loaders[_next],0);
_tween = new Tween(_loaders[_next],"alpha",Strong.easeOut,0,1,1,true);
_TEXT. Text = _images[_next].@DESCRIPTION;
}
[/ CODE]I defined in the XML of the deadlines for each photo, but I can understand how to transmit the delays to the timer. Please help me. Thank you very much.
Oops, it should run this timer once only, not repeatedly. Try:
Import fl.transitions.Tween;
Fl.transitions.easing import. *;var _delay:int = 0;
var _total:int = 0;
var _images:XMLList = null;
var _loaders:Array = new Array();
var _counter:int = 0;
var _next:int = 0;
var _timer:Timer = null;
var _tween:Tween = null;
var _container:Sprite = new Sprite();
var _text:TextField = new TextField();var _loader:URLLoader = new URLLoader();
_loader. Load (new URLRequest ("data.xml"));
_loader.addEventListener (Event.COMPLETE, complete, false, 0, true);function Complete(e:Event):void
{
var _xml:XML = new XML (e.target.data);
_loader. RemoveEventListener (Event.COMPLETE, complete);
_loader = null;
_xml.image = _images;
_Total = _images.length ();LoadImages();
}function loadimages (): void
{
for (var i: int = 0; i< _total;="">
{var _url:String = _images[i].@URL;
var _loader:Loader = new Loader();
_loader. Load (new URLRequest (_url));
_loader.contentLoaderInfo.addEventListener (Event.COMPLETE, ImageLoaded);
_loaders.push (_loader);
}
}function ImageLoaded(e:Event):void
{
_Counter ++;If (_counter is _total)
{
SetupSlider();
}}
function SetupSlider (): void
{
addChild (_container);
_TEXT. Selectable = false;
_Text.width = 450;
_TEXT. Height = 50;
_Text.x = 0;
_Text.y = 0;
addChild (_text);
NextImage();}
function TimerListener(e:TimerEvent):void
{
love ++;
If (love == _total)
{
love = 0;
}NextImage();
}function NextImage (): void {}
If {(_container.numChildren>0)}
_container.removeChildAt (0);
}
_loaders [love] .alpha = 0;
_container.addChildAt(_loaders[_next],0);
_tween = new Tween(_loaders[_next],"alpha",Strong.easeOut,0,1,1,true);
_TEXT. Text = _images[_next].@DESCRIPTION;
_delay = _images[_next].@DELAY;
_Timer = new Timer(_delay*1000,1);
_Timer.addEventListener (TimerEvent.TIMER, TimerListener);
_Timer.start ();
} -
I tried to get more information on the use of this command.
I get the timer (var someTimer:Timer new timer (1000, 1))
the timer will delay calling a function for a second, once.
In other examples I've seen the use of
someTimer.delay = 150
The timer has already a delay of 1 second (1000).
Is - this delay County substitute (1000) with a new delay (150)?
OR
He puts a delay (150) before it triggers the timer (in 1000)
IF its what I'm not clear on why you would want/need of a delay on the clock
(have a timer on a timer)
OR
I'm wrong on both accounts, and I really need help! =]
Someone can help me to understand better, or have links to a place that would be?
Thank you
It is changing the delay to 1000ms to 150ms IF 1000 ms did not occur when the delay is changed. otherwise, your timer event will trigger its an event and change the delay won't hurt.
-
Hello world
I got the coding among the online tutorial timer but I need to change the encoding.
For the moment I make such as the timer countdown to 10 seconds.
How it that when the timer has brought 0, the timer stops counting?
Copy and paste the code. If this does not work, try to send your .fla file that will help me to guide you.
-
Help with time operations invloving the SQL query
I created 2 tables in my SQL. One is the user_info_table table that stores the connection time and time zone of login for each user. The other is the post_table that stores user postid, who makes the post time post and time zone for each message.
CREATE TABLE user_info ( user_id VARCHAR(20), login_date DATE, login_time_zone VARCHAR(20), PRIMARY KEY (user_id) );
Some examples of data for my paintings is as below.CREATE TABLE post_table ( post_id VARCHAR(20), user_id VARCHAR(20), datepost DATE, time_zone VARCHAR(20), PRIMARY KEY (post_id), FOREIGN KEY (user_id) REFERENCES user_info(user_id) ON DELETE CASCADE ) ;
I need to write a SQL query which - is the user whose time difference between the time of the connection and the last time when he or she wrote a post is the smallest. I need to consider the time zones here as well.INSERT INTO user_info VALUES( 'u1', to_date('9/17/2009 20:00','MM/DD/YYYY mi:ss'), -2 ); INSERT INTO user_info VALUES( 'u2', to_date('9/17/2009 19:55','MM/DD/YYYY mi:ss'), -4 ); INSERT INTO post_table VALUES( 'p1', 'u1', to_date('9/17/2009 20:50','MM/DD/YYYY mi:ss'), 6 ); INSERT INTO post_table VALUES( 'p2', 'u2', to_date('9/17/2009 20:30','MM/DD/YYYY mi:ss'), -5 ); INSERT INTO post_table VALUES( 'p3', 'u2', to_date('9/18/2009 6:00','MM/DD/YYYY mi:ss'), 2 ); INSERT INTO post_table VALUES( 'p4', 'u1', to_date('9/17/2009 21:00','MM/DD/YYYY mi:ss'), -3 );
I am not sure if time_zone must be of type VARCHAR or TIMESTAMP then have created as a VARCHAR in my paintings.
Someone help me please to form this query.
PS: How can I tags < code > user in this forum to write sql statements.
Published by: user11994430 on October 9, 2009 17:59You can do this by adding a clause of "HAVING" as shown below. However, with your test defined data it returns ZERO rows because for all users of the MAX (DATEPOST) IS LESS than MAX (LOGIN_DATE)
SELECT USER_ID FROM ( SELECT USER_ID , DENSE_RANK() OVER (ORDER BY POST_LOGIN_DIFF) RNK FROM ( SELECT USER_INFO.USER_ID , MAX(DATEPOST) - MAX(LOGIN_DATE) AS POST_LOGIN_DIFF FROM USER_INFO JOIN POST_TABLE ON POST_TABLE.USER_ID = USER_INFO.USER_ID GROUP BY USER_INFO.USER_ID HAVING MAX(DATEPOST) > MAX(LOGIN_DATE) ) ) WHERE RNK = 1
-
I'm next to me, I hope that there is a way to get back them.
I was told my someone from tech apple to my iPhotos on an external hard disk to make more space on my MacBook Air, which seemed to work fine. We also have this same external hard drive my Time Machine.
I noticed a small box from time to time come and say something like, Time Machine is running out of space to record new data, you want to delete things until March 2013 etc. He asked me a few times and I said yes, all the way until June 2014. Now just disappeared in my iPhotos to find some pictures of my daughter when she was a baby (in 2012) and there is nothing there before 2014. I'm completely panic, is there something I can do?
Thank you, Kate
PS
This is the first time I've posted here, this is the right place to ask this question?
Can specify you:
You have time machine back ups and an iPhoto library on the same application - no time machine back ups of the library?
-
I tried enabling to TIS using nodes of property for the appropriate channel and by disabling the TIS for strings, I don't want to use. When I do that, I get the following error:
niScope read Cluster.vi:1
internal software error has occurred in the extended software. Please contact the support of National Instruments. Name of the component: nihsdru
File name: p:\Measurements\highSpeedDigitizers\hsd\driver\trunk\1.10\source\redirection\tHardware.cpp
Line number: 1038State code:-223425
Any ideas what to do?
Thank you, but I managed to fix it with the help of a few colleagues.
Maybe you are looking for
-
I downloaded an app from a worker ID mobile shop and I am still registered my ID and I am using the application normally but I wonder if he could access this application and see my pictures and conversations! Any help please?
-
"Toshiba Places" does not work
My Toshiba RL958 TV is now a failure load Toshiba places after worked OK since I bought it. The Wired internet connection is good because the Media Guide Downloads okay and I updated the firmware with a download. I also did a factory reset before I u
-
Hello I recently bought the report generation tool kit and trying to familiarize myself with its use. I encountered a problem trying to 'get the last line' during playback of an excel worksheet. The attached vi and .xls appears to be to the row and c
-
Printer HP Officejet 6500 E 709 series wireless with HP Touchsmart computer ok (windows 7) until recently.
-
strange error with configure snapshot controlfie
If I put the path snapshot controlfile to the db name hardcoded in the path, it works:CONFIGURE SNAPSHOT CONTROLFILE NAME TO ' / var/backup/IDB00246/snapcf_%d.f';From control file and SPFILE Autobackup 10 December 14room handle=/var/backup/IDB00246/c