-
If a repeating table within the form can be used as a data source then it would be correct. If I am understanding correctly now, the Me.DataSources("PartsListUpdate") actually refers to an external Data Connection that has the same name. If this is the case, I can create an external data connection ...
-
Or perhaps you are trying to access data in the main data source? Is that the case? In which case you would use something like:
Dim Nav As XPathNavigator = Me.MainDataSource.CreateNavigator()
-
The error is:
An item with the following index does not exist in the collection: PartsListUpdate
This indicates you are referencing a data source incorrectly.
It would appear that this line is throwing the error:
Dim Nav As XPathNavigator = Me.DataSources("PartsListUpdate").CreateNavigator()
Do you see how you are trying to ...
-
The complete xpath is "/dfs:myFields/my:Contain/my:PartsListUpdate". This is not a data connection, it is the repeating table (PartsListUpdate) that receives the data from the (PartsList) repeating table.
-
That error message tells you this line is wrong:
Dim Nav As XPathNavigator = Me.DataSources("PartsListUpdate").CreateNavigator()
Bolded the issue - what is the actual name of the data source?
Do you know how to run your code in debug so you can walk through this while it is running?
-
Does the empty row at the top of the "copy from" (PartsListUpdate) table make a difference?
-
Hilary, Thank you. I have taken this apart piece by piece. I have just tried:
Public Sub CTRL1334_9_Clicked(ByVal sender As Object, ByVal e As ClickedEventArgs)
Dim Nav As XPathNavigator = ...
-
update: I am such an idiot sometimes. Of course it doesn't want duplicate names. I will only have duplicate names during my testing so this problem should go away when released to production. Only one employee per year will get a record created.
-
My guess would be that starting from here:
If Selecta = "True" Then
You'd need to change your XPaths and your namespace. What have you tried?
-
Hilary,
I have tried to modify the code without success. At this point, I don't know if I am missing some "small" detail. This code works from 1 table to the other:
Public Sub CTRL174_23_Clicked(ByVal sender As Object, ByVal e As ClickedEventArgs)
Dim Nav As ...