blah blah blah is here! blah blah » Close

0
votes
0 answers

Calculate time between two dates

I am new to this forum and also new to c# programming. I am trying to create a vehicle rental system. Something to make reservations, create rental agreements, etc. I am stuck on something that seems like something that should be fairly eas ...

0
votes
0 answers

multiply time duration

Guys, I'm trying to calculate my total time textbox by the hourly rate textbox. below is an example of how my total time textbox is being output: [code]totalTime.Text = String.Format("{0:D2}:{1:D2}", diff1.Hours, diff1.Minutes) ...

1
votes
1 answers

accepting data over a port.

I have an application that sends data over a port. I need to accept the data (on the same system ) and then write it in a text file. Now the problem is that I don't know how to go about doing it. I am working on Windows XP. And any platf ...

1
votes
1 answers

Time string in textbox.

Hi. I have an application that I need the user to enter a time in this format: "1700" (five o'clock in the afternoon). I have two textboxes and first the user inputs the time started and then the time finished. So it is somethi ...

1
votes
2 answers

Calculate Time

I have 2 lables on my form, label1 and label2, i'm using label1 to capture the current time, then later in the day label2 captures the current time, how can i display the difference in time between label1 and label2 in label3? I'm displa ...

0
votes
1 answers

C# DateTime.TimeOfDay

How do I split DateTime.TimeOfDay into seperate integers for Minute, Second and Hour as well as a Boolean for AM/PM? Thanks, Theo

0
votes
0 answers

Session time out

Hi all Gurus, I have an asp.net application. I need to code a session time out (say after 5 min of inactivity) to redirect any page the user is in to the login page. I like to know if there is a way so I can write a code at once place like ...

1
votes
1 answers

help with getting an accurate DateTime.Now object. I keep getting 12:00am

[code]DateTime CurrTime = DateTime.Now; txtStarted.Text = CurrTime.Date.ToShortTimeString();[/code] The clock on my computer says 2:31pm, but it keeps displaying 12:00a

0
votes
1 answers

using MCI time macros in C#

I am working on building a media player and I need to update a label which shows the current track position. I am using the following command to retrieve the position: mciSendString("status MediaFile length", media_length, 256, ...

Feedback