logo

Sharepoint & InfoPath

Posted by Kerrie Jones in SharePoint

Wednesday, November 04, 2009 7:00:59 PM

I am trying to submit the contents of a repeating table in an InfoPath form to a new SharePoint list.  Everything works well until I try and manipulate one of the date fields.

I have a Date Picker “DateEnd” with a data type of text and a format of dd/mm/yyyy. 

If I pass the date as shown below everything is fine

 

Dim PickEnd As String = rows.Current.SelectSingleNode("my:PickEnd", NamespaceManager).Value

However what I need to do is add 24 hours to the time.  So as a test I have tried all of the following options.

'**NO RESULT 1

Dim PickEnd As Date = rows.Current.SelectSingleNode("my:PickEnd", NamespaceManager).Value

 

'**NO RESULT 2
Dim x As Date = CType(rows.Current.SelectSingleNode("my:PickEnd", NamespaceManager).Value, Date)
Dim PickEnd As String = x

 

'**NO RESULT 3
Dim PickEnd As String = CType(rows.Current.SelectSingleNode("my:PickEnd", NamespaceManager).Value, Date)

 

 

'**NO RESULT 4

Dim Workdate As Date

Workdate = rows.Current.SelectSingleNode("my:PickEnd", NamespaceManager).Value

Workdate = Workdate.AddSeconds(1)

PickEnd = Workdate.ToString

 

In saying “NO RESULT”, I get no data in my new list.  How can I manipulate the date prior to sending it to the list?  The “PickEnd” field in the new list is defined as Date/Time.


Biography
Kerrie has not submitted biographical details.

Site Rank:  Not applicable - Current Winnings:  $0.00

Reply Reply Using Power Editor

Didn't Find The Answer You Were Looking For?

EggHeadCafe has experts online right now that may know the answer to your question.  We pay them a bonus for answering as many questions as they can.  So, why not help them and yourself by becoming a member (free) and ask them your question right now?
Ask Question In Live Forum








  $1000    Adam Houldsworth - $187  |  Jonathan VH - $139  |  Kirtan Patel - $117  |  F Cali - $116  |  Huggy Bear - $88  |  more Neado  |  Free Icons  |  Privacy  |   (c) 2010