SQL Server :: Recording DateTime?
Aug 4, 2010I want to record the time and date when a user login to my system..How it is possible?..I want to get date and time and want to insert it into a database table.
View 4 RepliesI want to record the time and date when a user login to my system..How it is possible?..I want to get date and time and want to insert it into a database table.
View 4 RepliesI am trying to store a SQL Server datetime into MySQL datetime field, but MySQL stores the date value as all zeros. I use this function to trim the fractional part from the SQL Server datetime, but get the same result when trying to store it in MySQL.
[Code]....
I am trying to get data from mysql database and store in sqlserver database. i am getting the following error
The given value of type MySqlDateTime from the data source cannot be converted to type datetime of the specified target column.
we have to develop a enterprize application in asp.net c# and i have to getting a module of voice recording but i dont have any solution about voice recording in asp.net c# for webapplication.
View 2 RepliesIs there a way to record sound from the user and save it on the server in ASP.Net 2.0 or greater?
View 2 RepliesI want build an application on web which records the audio sound through Mic.
also if you can suggest some third party control which is free.
The technology for Implementation - ASP.NET , C#
How to log MethodName when wrapping Log4net?
I have tons of requests in log4net that show up manually as ": activity". The requests are all manually built and somewhat clumsy. Is there any way for Log4Net to pick up the source function and record that automatically?
I know what i need but i am unsure of the way to acheive it. My idea is to broadcast live event over the internet on website. dont tell basic things like ustream or other streaming websites. I want that my sony 7 MP camera should connect to the PC and broadcast the recording live on my website
View 2 RepliesI need assistance on how to bind Radiobutton to database, so that whatever selection made in Radiobutton will appear in the database
I want to produce an online quiz, that will have the following fuctionality
1. it contain database with , ID, Questions, Option A, B,C, and D, Student Answer.
2.After forming the griedview in connection with the database, i form additonal colum to include Radiobutton where students are to choose the correct option.
3. I was able to configure the gridview which successfully show all the above document but the problem now is how to bind the selected option by students to the database so that i can know wether they choose the right answer or not. i wat the student answer appear in the colum named student answer in the database.
i shall be very grateful , if u can just give simple example that i can perform which shall be able to show the click on radiobutton in database not autopostback in textbox.
I am using a simple Login function and need to record individual field values from MySQL database to compare with inputs.
My connection code:
Dim myConnection As MySqlConnection
Dim myDataAdapter As MySqlDataAdapter
Dim strSQL As String
myConnection = New MySqlConnection("Database=mydatabase;Data Source=xx.xxx.xx.x;port=3362;UId=myID;Password=1234;")
strSQL = "SELECT username,password FROM Login WHERE ID = '" & 1 & "'"
myDataAdapter = New MySqlDataAdapter(strSQL, myConnection)
myDataSet = New Dataset()
myDataAdapter.Fill(myDataSet,"Login")
I have confirmed it is connecting by adding the following GridView.
GridView1.DataSource = myDataSet
GridView1.DataBind()
My problem is isolating the individual field values.
[Code]....
DateTime Server control
I created a UserControl and added a public DateTime property. I want to set this property in Markup (ie. <cc1:MyControl runat="server" id="MyControl1" DateTimeProp="1/1/2010" /> ) however I live in a place with a dd/mm/yyyy date format so it complains if I set something like "20/1/2010". Is there a way to set markup in my local datetime format or do I have to conform to "mm/dd/yyyy"?
View 2 RepliesI have a problem:
I've created usual Controller and View(Edit view) for editing my Entity (EntityFramework)
Here is view example:
<div class="editor-field">
@Html.EditorFor(model => model.BirthDate)
@Html.ValidationMessageFor(model => model.BirthDate)
</div>
BirthDate is Nullable<DateTime>
but during loading my View I get this exception
The model item passed into the dictionary is null, but this dictionary requires a non-null model item of type 'System.DateTime'.
That's because of BirthDate is null in database but it is nullable and I expect that it just leaves the filed empty.
And I have Shared EditorTemplate:
@model System.Nullable<System.DateTime>
@if (Model.HasValue)
I have an XML string which contains Dates formatted "dd/MM/yyyy hh:mm:ss".
I'm loading this XML into a dataset using DataSet.ReadXml().
How can I ensure that this Date is stored in the DataSet as a typed DateTime so that I can Sort, Format and RowFilter on it accordingly.
My test harness is as below:
ASPX Page:
[code]....
obj.From = DateTime.Parse(txtFrom.Text, ci);
And it will give error String was not recognized as a valid DateTime. How it can be solved..
How show local time in datagridview collumn DateTime from database with universal datetime
View 2 RepliesI am struggling to find out the problem with something. Basically on this page:
[URL]
If you look at the nursery diary tab, will see an article, the first article is named "Test article for archives 1". Now the date should be 01 April 2010, but instead its showing as 04 Jan 2010.
I don't understand why. I have been looking at my insert statement and when i insert in the admin section i have a AJax date extender. And it populates the text box like so '01/04/2010'
But then when i check in my database i notice it has been added as '04/01/2010'.
What does this mean?
My insert statement is like this:
<snip>
The insert works perfectly, but the date format is inserted wrong.
I am converting my datetime object with current date and specific time 23:59:59 as shown underneath.
[Code]....
But when I check in my sql table datetime column, it is changes seconds part of time from 59 to 00, so for instance, if I have a datetime, 2010-08-11 23:59:59, it changes this to 2010-08-11 23:59:00. How should I fix this.
I need to check the datetime field in my DB to see if the time that's current set is 12hr's past?What's the command to use? Can I just DATEDIFF?
View 4 RepliesI'm building an asp.net application and have a problem. Im building now a stored procedure in sql server and need the min (1/1/0001) and max(12/31/9999) value of the datetime. Is there some method I can execute to get this dates?
View 1 Repliesin my application two time input will be passing to my sql stored procedures and I need to calculate the timespan between them. how can I do that? is there any way that I can do the following in t-sql?
[Code]....
i want to change a colomn Format in SqlServer from ShortDateString to LongDateString();
View 5 Repliesis there any way to set the datetime format of the datafield created in the table? like (datefield name) Date_Time from mm/dd/yyyy to dd/mm/yyyy with no time display and it wont store time in it. and also when we create a variable in vb.net of datetime datatype such as
dim data_time as DateTime
can we set its date format ?? because i want to change it to dd/mm/yyyy but its mm/dd/yyyy by default
System.DateTime start_time = (System.DateTime)phones_.GetStartTime(callInfo.No[1].e164, callInfo.No[0].e164)[0][0];
View 1 RepliesWhen a post is made to the site/database, it's made as Universal Time. A user can set the site's default timezone from a dropdown menu in the admin area, which saves the selected timezone to a database table (table: DefaultTimezone, column: Timezone). Now, how can I adjust the following code to display the datetime according to the correct timezone, that was set in the database? So if the Timezone column has "US Eastern Standard Time" in it, it would display the published datetime in that format.
<%#Eval("Published", "{0:MMM dd, yyyy - h:mm tt}") %>