.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Sharepoint date calculations = WRONG

Posted By:      Posted Date: September 12, 2010    Points: 0   Category :SharePoint
Can someone show me how to create a calculated column that displays the date only? I'm using the microsoft absence planner. I am simply trying to display a date without the time. I'm getting inconsistent results. Someone suggested that I simply add a day but that is not consistent. I created a calcualted column to show me the day that Sharepoint thinks the time value has. The results are disappointing to say the least someone suggested this formula since it seems to be always off by a day: StartDate is a calculated column = =DATE(YEAR([Start Time]),MONTH([Start Time]),DAY([Start Time]+1)) *sometimes this formula displays the right info, sometimes not The last column is just = Day_[Start Time] so I can try and figure out what is going on :( Attendance item      System Account      Other      6/28/2010 12:00 AM      6/29/2010      28 Attendance item      System Account      Jury Duty      9/29/2009 12:00 AM      9/30/2009      29 Attendance item      System Account      Jury Duty      9/29/2009 12:00 AM      9/30/2009 &nbs

View Complete Post

More Related Resource Links

SharePoint Search returns wrong date

Hi i am running a Sharepoint 2010 enterprise search indexing a file folder structure with emails(.eml) and attachments(.doc(x), pdf, xls(x), ...). The search results shows a date like first full index time or something like that, but not the date of file creation or any other attributes of the file. My questions: - what may be the reason of the wrong date? - is there a possibility use another attribute for displaying that is more relevante? Please help Kind regards Werner Durrer    

"Date&Time" column in list - set actual time and sharepoint's proposes wrong hour (eg. 17:00 instea


I created new column in list - Date and time (Date and time format: Date&Time, Default value: Today's Date)

The problem is, when I create new item in list, the default time is always set as next full hour, eg. now it's 13:15 or 13:31 ora 13:57 and in aspx form it's all the time 14:00. Obviously, I can change that date with 5 minut precision (13:05, 13:10, 13:15 etc.), but it's kind of annoying.

CalendarExtender wrong date from database



I'm about to go NUTS :)

I have 2 CalendarExtenders on page. And I want to show the date that I get from SQL SEVER:

select -> SELECT convert(datetime,  begin) as Begin, convert(datetime, end) as End FROM Table

The date field, on base,  is a char(8)  and the record is like YYYYMMDD. That's why I convert it to datetime.

But, on code behind when I do this :

CalendarExtender1.SelectedDate = DateTime.Parse(objDataEvento.Rows(0)(2))
CalendarExtender2.SelectedDate = DateTime.Parse(objDataEvento.Rows(0)(3)) 

Depend of the date, It's showing minus 1 day on page.

Like: If, on base, the date is 08/12/2010, on page it's showing 07/12/2010.

WHYYYYYYYYYYYY ??????????????? Cry Smile




Filter items with a date column with parameters start date and end date on a sharepoint list?

If I have alist with a view that has the columns Title, Status and Status Date and the view has some items. How Can I add a filter with two parameters, start date and end date, to only show records with status date equal to or greater than parameter start date and status date is less than or equal to parameter end date? This is a sharepoint online site and I can't create and deploy custom code, can use SPD though. Do I need to use SPD or is this something I can do in the list settings? Thanks in advance.   Edit: I had a look here http://www.endusersharepoint.com/2009/09/29/sharepoint-date-filter-filtering-a-list-by-greater-than-or-equal-to-date/ but I don't have the Date Filter web part.

Is it possible to use multiple date fields to have an event show more than once on a Sharepoint 2007

Hello, Is it possible to use multiple sets of start and end times to have events display multiple times in a sharepoint calendar? To clarify: - I have the standard fields of "Start Time" and "End Time" in my calendar list. - Events show on the calendar just fine. - Would like to create additional fields called "Start Time 2" and "End Time 2" within the same record and have the event show multiple times on the calendar. - The recurrence functionality of sharepoint will not meet my needs because the pattern I need to use is not in one of the allowed choices. Thanks in advance, John

Problem with incoming mail to SharePoint Library - what is wrong with this?

I configured my incoming mail to a SharePoint 2010 library according to these instructions. http://intellects.in/2010/04/04/configuring-sharepoint-2010-document-libraries-with-exchange-server-2010-to-receive-mails-from-internalexternal-world/ I'm able to receive mail at the Exchange mailbox set up for the document library, but am unable to receive the document in the library itself.  I'm thinking it's because I have a problem with my naming - but I'm not sure how to solve it: I have a SharePoint box and an Exchange box. I've configured the SMTP virtual server with default domain of  server.domain.com .  I've also assigned it an alias of domain2.net I've configured incoming email in SharePoint Central Administration to use the address of mylist@domain2.net so that users can have a friendly url for sending documents to lists and libraries. I've created an Attended Domain in Exchange 2010 and set up an email address policy that speicifes all mailboxes receive an domain2.net address.  I have an MX record for the domain2.net address with a DNS server pointing to the Exchange box. I've created an SMTP Send Connector that points to the FQDN server.domain.com of my virtual server on my SharePoint box. With that connector, I've chosen to route mail through the same FQDN of server.domain.com , that of my SharePoint/IIS SMTP Virtual Server box. When I confi

How to get "Current Date" on SharePoint Designer for Invoice Ageing Data View Report??

Hi Experts, I would like to know how can i get/show "Current Date" in SharePoint Designer ?? Any good tutorial ? FYI, I need this "Current Date" for my Ageing Data View Report, Purpose To offset with "Invoice Receive Date" to get total days of payment payable for the invoice. Please assists, Thanks

how to get the current date and time using sharepoint designer workflows

hi, how to send an email using sharepoint designer workflow when an item equals to end time. How to get the current date and time.I am able to capture the date but not the time  the time is showing as 12:00:00 AM. First i have create an variable  and storing the date and time in that variable and i am comparing the variable value with end time. If both are equal then i want to send an mail to attendees

SharePoint 2010 Export list Items to Excel, wrong url in iqy file

Hi, I have a SharePoint 2010 Environment that uses https://portal.<something>.com. Exporting to Excel of a list uses wrong URL. When I go to the a list, select the list to show the "office ribbon" and then select export to excel, excel will show the error "Excel cannot connect to the SharePoint List". When I take a look at the IQY file that is created it contains the wrong url: http://portal.<something>.com instead of https://portal.<something>.com Changing the URL in the IQY file manualy to https://portal.<something>.com and then opening it will excel is working fine, list data is exported to excel then. Alternate access mapping is configured to use https://portal.<something>.com as default, export to access is working normaly. I already deleted the http://portal.<something>.com alternate access mapping once to see if this fixes the problem. No fix, even not after IISreset or rebooting the server. Where or how is the export to Excel IQY file created and where is it possible to fix the URL it is putting in the IQY file? Grtz, Arjan

Office SharePoint - Mutual Authentication Failed. The servers password is out of date at the domain

I have a SharePoint Server 2010 site setup with SSL. (https://sitename.com) Whenever someone tries to save an Excel or Word document to the site through Save As or Save To SharePoint they get "Mutual Authentication Failed. The servers password is out of date at the domain controller". The desktop experience feature is installed and the webclient service is running. They also receive certificate is not available and if they wait a little bit or hit OK it will show the directory and not the website like on a regular http site.  

i get date in wrong format - need help


i get date from xml in this format:  `7/16/2010 (mm/dd/yyyy)`

i have in my program  `datetime val -  MyDate`.

and when i try to placing   `MyDate = Convert.ToDateTime(7/16/2010)` 

i got error.

how i can fix it ?

thank's in advance

MDX Calculations error - The 'Date Calculations' dimension contains more than one hierarchy, there


Hi all,

I am using http://www.obs3.com/pdf/A%20Different%20Approach%20to%20Time%20Calculations%20in%20SSAS.pdf to make a seperate dimension for the data calculations, which works in my Sales cube. But when I use the same dimension in an other cube (Called 'Procurement') and copy the MDX in the calculations tab, I am getting some errors:

Error    57    MdxScript(Procurement) (9, 8) The 'Date Calculations' dimension contains more than one hierarchy, therefore the hierarchy must be explicitly specified.        0    0   

But the 'Date Calculations' dimension does not have a hierarchy!

Now I don't know why I am getting these errors, could you guys help me out so I can understand them and fix the problem?

Thanks you in advance,


update list text or date value via sharepoint designer using JAVA


Hi All,

Bit of a noob question - but tried all sorts and can't get this to work - also first time i've ever used sharepoint.

(I'm using sharepoint designer 2007) I have a form, on the form i select a type (drop box choice) and it hides or displays a related field, I want to auto populate the field when it displays, below is the java i have currently. 

Please advise how to populate (date field) with tommorows date, and also if it was a text field with the word "testdre"

<script type="text/javascript">
  function hideFieldsOnStart()
   //hide the control at start
   var control = getTagFromIdentifierAndTitle("input","TextField","Urgent Change Justifacation");
   //add an onchange event to the dropdown
   getTagFromIdentifierAndTitle("select","DropDownChoice","Change Type").onchange = function() {ChangeEvent()};
  function ChangeEvent()
   //get the dropdown

how to make start date,end date and people and group readonly using sharepoint designer



how to make start date,end date and people and group readonly using sharepoint designer(sharepoint 2007).

I have created calendar list in that i have people and group column .

In edit mode i want start date ,end date and people and group column read only.


very urgent

Sharepoint attachments with time/date stamp


I am not a sharepoint guru, so please feel free to talk to me like I'm a beginner.

We have a web part that allows attachments and the boss wants to time/date stamp the attachments so he knows which one is the most recent. I know this happens with ease in a regular doc library, but not sure how to implement in a simple web part.

Thanks in advance for any advice.

SharePoint 2010 Date Column Not Indexing (or not searchable)


I have a 2010 Record Center.  Indexing and search functions seem to be working.  However dates do not appear in search results.  The column is marked for indexing.  Crawling is working and I do get other text type results.  I have tried switching the column to Date & Time in the detailed column settings.  With or withouth the time, it does not come up. 

There is an interesting twist.  On SOME, the search returns the AllItems.aspx PAGE (not the documents) with the date highlighted in the result item description.

SharePoint 2010 Date Columns are not Indexing (or searchable)


I have a 2010 Record Center.  Indexing and search functions seem to be working.  However, searching dates does not produce results.  The date column is marked for indexing.  Crawling is working and I do get other text type results.  I have tried switching the column to Date & Time in the detailed column settings.  With or withouth the time, it does not come up in the results. 

There is an interesting twist.  On SOME, the search returns the AllItems.aspx PAGE (not the document or list item itself) that it resides on with the searched date highlighted in the result item description.

North to the Future
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend