Questions tagged [seconds]
333 questions
2
votes
1 answer
Android: Incorrect Date when Converting from Seconds
I'm parsing some date data from an XML string into a hierarchy of model objects. The dates are in a 10-digit seconds format. I use the method below to convert those seconds into Date objects
public static Date getDateFromSecondsString(String…

mahdaeng
- 791
- 4
- 15
- 25
2
votes
7 answers
How can I setup DateTime hour,minute and second?
private void StartAuction()
{
DateTime closeDate;
closeDate = DateTime.Parse(Console.ReadLine());
}
I am able to set the date,month and year but I want the hours,minutes and seconds to setup automatically to the current time of the day. for…

user1281566
- 133
- 1
- 3
- 15
2
votes
2 answers
Seconds to Time in XSLT
I'm not asking a question actually. I signed up stackoverflow to give something back to a community that has helped me so many times.
If you are using XSLT 1.0 there are no built-in time calculations. I came up with this to convert seconds into…

Neil Diamond
- 21
- 1
- 3
2
votes
1 answer
Why is it skipping seconds?? CountDown timer
If I have my counter up over 30 seconds, it often skips a second here and there. I have it counting down, with the display showing. But it chooses to skip random numbers. The numbers it skips are the same number each time. If I change the length of…

Chad Bingham
- 32,650
- 19
- 86
- 115
2
votes
1 answer
ruby on rails time_ago_in_words doesn't display seconds ago
Here is my en.yml locale
en:
datetime:
distance_in_words:
less_than_x_seconds:
one: "1 sec"
other: "%{count} secs"
x_seconds:
one: "1 sec"
other: "%{count} secs"
less_than_x_minutes:
…

stergosz
- 5,754
- 13
- 62
- 133
2
votes
1 answer
Python - Add seconds to time object
I have a time object which looks like this:
time.struct_time(tm_year=2012, tm_mon=8, tm_mday=11, tm_hour=18, tm_min=48, tm_sec=23, tm_wday=5, tm_yday=224, tm_isdst=0)
I was wondering if there was an easy way add seconds to it.
I want to add 4497…

Parth
- 1,226
- 7
- 28
- 49
2
votes
2 answers
c# datetime to sql with including seconds
i am trying to save (using linq) the date and time to an SQL field (datetime data type) using Datetime.Now but the seconds are not coming through. Does anyone know how to rig that up?
Ta.

Grant
- 11,138
- 32
- 94
- 140
2
votes
1 answer
Displaying seconds in 3 decimal places. - java
I am using milliseconds in my java program and converting it to seconds. After my method does this, it returns seconds in a long format.
System.out.println("[" + threadID + "]" + " " + "SeqSum res=" + grandTotal + " secs=" + stopTime);
I have used…

WoLv3rine
- 107
- 1
- 4
- 9
1
vote
1 answer
How to refresh widget every second?
Look at code below I need to update this onUpdate method every second, could anybody give some good example, please? Mainly I need to update codes from CurFreq(context); to views.setTextViewText(R.id.text_widget_batt, prefNameBattery+"%");
public…

Adam
- 2,152
- 4
- 35
- 45
1
vote
2 answers
Why does adding a day to a time change the fractional part of seconds?
pry(main)> time = Time.now
=> 2012-01-20 00:10:44 +0000
pry(main)> (time + 4.days).to_f
=> 1327363844.9709609
pry(main)> time.to_f
=> 1327018244.970961

Peder
- 2,739
- 3
- 31
- 33
1
vote
2 answers
Google Sheets: How to Convert Column Values In mmm:ss or mm:ss Format to Minutes
I currently have a "minutes" column that has values which look like 129:31 or 22:56
The numbers to the left of : are minutes and the numbers to the right of : are seconds. In Google Sheets, how do I take that column of values and convert it to…

PineNuts0
- 4,740
- 21
- 67
- 112
1
vote
3 answers
Oracle Find time from Seconds past midnight
In my Oracle table, I have a column with Number of Seconds since midnight (like 75135) and I want to identify its human readable time format. Do we have any command in Oracle ? please help me on this
Regards,
Manohar

Manohar Amkem
- 35
- 5
1
vote
2 answers
jquery timer write time remaining
I have a paragraph field where I want to put the seconds remaining from this timer:
HTML:
xx seconds remaining
JavaScript: window.setInterval(retrieveLog, 20000); How can I do that?
michele
- 26,348
- 30
- 111
- 168
1
vote
3 answers
PHP convert remaining seconds (from now) into date
Good morning, guys. I was just thinking about the small PHP crawler, that could browse my 2 favourite websites and show me some info about auctions from 1 category.
I haven't started to write anything, because I stuck on the remaining time that…

GeorgeGibellini
- 13
- 2
1
vote
2 answers
Unix time stamp to date and hour in google sheets
I am working in Google Sheets. How can I convert a timestamp in seconds (as type of 1634978274) to the format of 2021-10-23 08:23, e.g. Date, hours; Minutes and how can I store this result in a new column? The original timestamp as such should not…

Baobab
- 55
- 1
- 8