Search - InfoPath Dev Sign in | Join | Help InfoPath Dev InfoPath Dev is dedicated to bringing you the information and tools you need to be successful in your Microsoft Office InfoPath development projects. Home Blogs Forums Photos Downloads Search More Search Options Page 1 of 1 (9 items) Re: Button to copy and paste a field on an InfoPath form to the clipboard Hi Jimmy, this is my code now and it works very fine now... [quote] Sub CopySmartKey_OnClick() Dim objXMLNode set objXMLNode = XDocument.DOM.selectSingleNode("/my:myFields/my:SmartKeyValue") XDocument.View.SelectText(objXMLNode) ... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-27-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard [quote user="Jimmy"] In all likelihood the error you're getting is the result of invalid XPath in line 24. In an earlier post you had a node name my:SmartKey, and in this post you have my:SmartKeyValue. Which one is it? And in either case, unless you changed it from the default, the 'F' in my:myFields ... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-27-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard [quote user="Hilary Stoupa"] I'd guess the "//" before my:myfields should be "/". [/quote] Dear Hilary, many thanks for your reply - but sorry - no change - same error... But I found this in the MSE Help: [quote] Note In some cases, calling the ExecuteAction method from the OnClick event ... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-27-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard As no one replies anymore I startet to do my own tests... First of all I simply would like to look if I can read a value given in a field called SmartKey Sub copyButton_OnClick(eventObj) Dim Hello Dim SmartValue set SmartValue = XDocument.DOM.selectSingleNode("//my:myfields/my:Smartkey").text Hello = MsgBox(SmartValue, 0, ... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-26-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard Hi Jimmy, until now no one replied :-( Are you able to make this work with JScript or VBScript? Many thanks in advance... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-24-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard Dear Jimmy, again many thanks for your help... When I open my form I found a section where I can change the setting, but it gives me only JScript or VBScript... Would be great to get a solution... :-) Thanks! Joerg Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-20-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard InfoPath 2003 (11.8165.8221) SP3 do I have to change the setting anywhere that it uses C# instead of JScript? If so - where can I set this up? When I open my form I found a section where I can change the setting, but it gives me only JScript or VBScript... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-20-2008 Re: Button to copy and paste a field on an InfoPath form to the clipboard Dear Jimmy, many thanks to you for helping me out, I now have this code behind my button, where SmartKey is the name of the Field (it is XHTML formated Richtext): function CTRL9_5::OnClick(eventObj) { XPathNavigator nodeToCopy = MainDataSource.CreateNavigator().SelectSingleNode("my:myFields/my:SmartKey", NamespaceManager); if ... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-20-2008 Button to copy and paste a field on an InfoPath form to the clipboard Hi, I'm absolutely new to InfoPath, but I already reached that a from (it content as well) is stored in a form library at our WSS 3.0. Now I would like to have not experienced users (more not experienced than me :-) ) to open the data from the list and watch it with InfoPath and to have a button (I already have this button on the form) and ... Posted to Newbie Questions (Forum) by Joerg Knoerchen on 11-20-2008 Page 1 of 1 (9 items) Copyright © 2003-2019 Qdabra Software. All rights reserved.View our Terms of Use.