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 9 (86 items) 1 2 3 4 5 Next > ... Last » Re: Get File Names I'm using the following namespaces: using System; using Microsoft.Office.Interop.InfoPath.SemiTrust; using System.Collections.Generic; using System.IO; using System.Security; using System.Runtime.InteropServices; using System.Diagnostics.CodeAnalysis; using System.Security.Cryptography; using System.Text; I still get ... Posted to Code (Forum) by Lawson on 10-30-2010 Re: Get File Names I used your code in following way: {IXMLDOMNode A = thisXDocument.DOM.selectSingleNode("/my:myFields/my:field1"); //Get the text of the Contract Number node.String Data1 = A.text; IXMLDOMNode B = thisXDocument.DOM.selectSingleNode("/my:myFields/my:field2"); //Get the text of the Contract Number node.String Data2 = B.text; ... Posted to Code (Forum) by Lawson on 10-30-2010 Re: Get File Names Hey, no worries. I would like to get the file names and corresponding hash values for each file, then I would like to place the names and hash values in a csv file. I can get the file names and the file hash values with the above code. Now I'm just trying to combine the two. Thanks, -Lawson Posted to Code (Forum) by Lawson on 10-29-2010 Re: Get File Names Now that I have the file names, I would also like to get a hash value for each document. I can get a hash value with the following code: // Open a local fileIXMLDOMNode N = thisXDocument.DOM.selectSingleNode("/my:myFields/my:field1"); //Get the textString HashDocument = N.text; FileStream fs = new FileStream(HashDocument, ... Posted to Code (Forum) by Lawson on 10-25-2010 Re: Get File Names Hey, thanks for your help. I found a stray bracket in the code. Once I removed it, everything worked perfectly. Thank you, -Lawson Posted to Code (Forum) by Lawson on 10-25-2010 Re: Get File Names Hey, thank you for your help. I tried using your code, but I get the following errors: Error 1 Invalid token 'foreach' in class, struct, or interface member declaration C:\Users\Lawson\Documents\InfoPath Projects\Hash Test Form 10-22-2010\FormCode.cs 112 17 Hash Test Form 10-22-2010 Error 2 ; ... Posted to Code (Forum) by Lawson on 10-24-2010 Get File Names Hello, I have an IP 2003 form with C# code. I have an event where I would like to read all of the file names from a speceific file folder and then write the file names to a csv file. I am using the following code.DirectoryInfo di = new DirectoryInfo(@"C:\Users\Lawson\Desktop\file\file1\");foreach (FileInfo fi in di.GetFiles()) ... Posted to Code (Forum) by Lawson on 10-23-2010 Re: open a document with C# Hey hilary, this is great. You're awesome 8^ ) I aslo want to create a button that will open a video file in Windows Media Player. Can you point me in the right direction on this subject as well? Thanks, -Lawson Posted to Code (Forum) by Lawson on 06-12-2010 Re: open a document with C# I am using the following code: this.Application.Documents.Open(@"C:\Users\Lawson\Documents\Test.docx"); But I keep getting the following error: Error 1 'Form_Creator_A.FormCode' does not contain a definition for 'Application' C:\Users\Lawson\Documents\InfoPath Projects\Form Creator ... Posted to Code (Forum) by Lawson on 06-12-2010 open a document with C# I have an IP 2003 form with C# code. I would like to code a button that will open a document when it is pressed. Does anybody know how to do this with C# code? Thanks, -Lawson Posted to Code (Forum) by Lawson on 06-12-2010 Page 1 of 9 (86 items) 1 2 3 4 5 Next > ... Last » Copyright © 2003-2019 Qdabra Software. All rights reserved.View our Terms of Use.