<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Repeating Questions</title><link>https://www.infopathdev.com:443/forums/thread/2961.aspx</link><pubDate>Fri, 11 Aug 2006 22:50:53 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:2961</guid><dc:creator>Greg Collins</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/2961.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=2961</wfw:commentRss><description>I think the problem is a fundamentally misunderstanding of how to use the current() function.&lt;br /&gt;&lt;br /&gt;The current() function returns a "node". Thus, my:Employee[my:SomeNode] is an invalid statement and will not give you a valid result.&lt;br /&gt;&lt;br /&gt;You need to do something with that node that gets returned by the current() function. That is why my:Employee[. = current()] works. This statement says that you want the employee node who's value has the same value as the node returned by the current() function.</description></item><item><title>Re: Repeating Questions</title><link>https://www.infopathdev.com:443/forums/thread/2960.aspx</link><pubDate>Fri, 11 Aug 2006 18:48:08 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:2960</guid><dc:creator>TarogStar</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/2960.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=2960</wfw:commentRss><description>Ok, it sounds like I need to be more direct.&lt;br /&gt;Question1&lt;br /&gt;More specifically here is the xpath that works in setting the value from another control, which is a drop down with EMPNO:&lt;br /&gt;xdXDocument:GetDOM("Rates")/dfs:myFields/dfs:dataFields/d:sysemprate/@HOURLY_RATE[../@EMPNO = xdXDocument:get-DOM()/my:myFields/my:DirectLabor/my:DirectLaborGroup/my:Employee[. = current()]] * ../../../my:Multiplier&lt;br /&gt;&lt;br /&gt;and here is the xpath that doesn't work to set the default:&lt;br /&gt;&lt;br /&gt;xdXDocument:GetDOM("Rates")/dfs:myFields/dfs:dataFields/d:sysemprate/@HOURLY_RATE[../@EMPNO = xdXDocument:get-DOM()/my:myFields/my:DirectLabor/my:DirectLaborGroup/my:Employee] * ../../../my:Multiplier&lt;br /&gt;&lt;br /&gt;If I try using the same code in the default as the value that I set it with, I always get NaN, but with the above xpath, all the values match the last chosen EMPNO drop down box, not the one in the row they are in.  I have tried: my:DirectLaborGroup/my:Employee[current()] and my:DirectLaborGroup[current()]/my:Employee and they do not work.&lt;br /&gt;&lt;br /&gt;Can someone please tell me where to put current() or if there is some other function or trick that I need to use so that when I change the multiplier field, it updates all the rows in this repeating table under DirectLaborGroup.&lt;br /&gt;&lt;br /&gt;Question 2&lt;br /&gt;I know how to get the URL, I already do that, but I cannot find anywhere how I connect to a sharepoint list using jscript where I can give the URL as a parameter.  Can someone PLEASE point me to an example or documentation on how to do this.  Right now I connect to a static secondary connection, which works fine for a single form, but when I need to make this work for hundreds, redoing the data connection and republishing every time, it is not practical.</description></item><item><title>Re: Repeating Questions</title><link>https://www.infopathdev.com:443/forums/thread/2959.aspx</link><pubDate>Wed, 09 Aug 2006 16:35:45 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:2959</guid><dc:creator>Shiraz Cupala</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/2959.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=2959</wfw:commentRss><description>Yes it sounds like you might need to do a more sophisticated XPATH in your default value.&lt;br /&gt;&lt;br /&gt;For the second question you can get the URL of the template from the InfoPath OM and then use code to query the appropriate SharePoint list.</description></item><item><title>Re: Repeating Questions</title><link>https://www.infopathdev.com:443/forums/thread/2958.aspx</link><pubDate>Wed, 09 Aug 2006 14:15:38 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:2958</guid><dc:creator>TarogStar</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/2958.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=2958</wfw:commentRss><description>Thank you for a quick answer.  I have a few difficulties however.&lt;br /&gt;Question 1&lt;br /&gt;I have tried to set the default value as you have suggested before, however it always takes the wrong values, as there is a bit of a complication.  The number that is multiplied is from a secondary data source that is filtered by a drop down list in the repeating table.  If I set a default value to that number, when I change the multiplier they are all the same, and they also have problems when I change drop down box values.  Currently I have the drop down box set the value in a rule, and that works fine while filling the form, but changing the multiplier ruins the values.  Possibly I need to apply come xpath trick in the default value?&lt;br /&gt;&lt;br /&gt;Question 2&lt;br /&gt;I have not seen a way to access a sharepoint list data with a script.  The getListItems service would seem to be the way to go, but the data source cannot be hard coded like the example.  I have searched this site and the internet in general, and I have not seen a reference to this.  The other portion I can code fine, but if you could point me to a resource for this specifically, I would appreciate it.</description></item><item><title>Re: Repeating Questions</title><link>https://www.infopathdev.com:443/forums/thread/2957.aspx</link><pubDate>Wed, 09 Aug 2006 02:50:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:2957</guid><dc:creator>Shiraz Cupala</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/2957.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=2957</wfw:commentRss><description>Welcome to our forum TarogStar.  I will try to answer both your questions.&lt;br /&gt;&lt;br /&gt;Question 1: repeating table calculated value&lt;br /&gt;For this one have you tried to set the default value of the node in question to be your formula?  That should set the value properly and will recalc when any of the variables changes including the multiplier.  Be sure to leave the checkbox below the default value field checked so it will recalc.&lt;br /&gt;&lt;br /&gt;Question 2: Populating repeating table from wss list&lt;br /&gt;This will indeed require code to copy the values from your secondary data source query and insert them as new rows into the repeating table.  Look in our resources section to find tutorials and programming references to learn about the InfoPath object model and programming concepts.</description></item><item><title>Repeating Questions</title><link>https://www.infopathdev.com:443/forums/thread/1483.aspx</link><pubDate>Wed, 09 Aug 2006 00:27:30 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:1483</guid><dc:creator>TarogStar</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/1483.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=1483</wfw:commentRss><description>I have looked around this site, and found quite a bit of good information, but I have not found the answers to these questions.  If it is already answered, a pointer in the right direction is appreciated.&lt;br /&gt;First Question:&lt;br /&gt;I have a repeating table where values are determined by multiplying a number outside the table with a number on the row where the total is decided.  I have not been able to find a way to update all the rows with the proper information when the one multiplier is changed.  I have tried using rules and playing with the xpath, but nothing seems to work by row, all the rows recieve the same value, i may just not understand xpath well enough to form it correctly.&lt;br /&gt;&lt;br /&gt;Second Question:&lt;br /&gt;I have another repeating table that I would like partially populated by information from a dynamically accessed sharepoint list.  It must be dynamic because there will be hundreds of lists and the correct one is determined by the URL the form is opened from.  I have already parsed the URL to set some default fields.  This repeating table also must submit data in other columns in this same table.  It is to compare budgeted hours with actual hours, and the budgeted hours will all be available on the specific sharepoint site, so the list must have the same number of rows as the sharepoint list, and also include inputs for the user to type the actual hours into, with totals for each row and a grand total (totals fields are no problem).  I'm sure this will require scripting to access the list and to add the rows with the proper values.</description></item></channel></rss>