Is there a way to use edited XML from local machine while debugging?

I wanted to check if bug is inherently caused from the raw XML content, before requesting Content team for modification! Also: I emailed 'Cobalt Content Specialists-Cases' team. I have not heard from them! Who should I request for the content change?

Best Answer

  • One solution: In order to check if the problem is at the content, I needed to modify the value of the XML. I successfully edit the value in the Visual Studio but the size of XML was big enough to delay the execution to copy and paste your chosen XML in the field. So, first I loaded the XML of the document which was being passed on in the text editor then modified the field of XML then loaded in Visual Studio. Then read it using StreamReader Add following lines in XMLcomponent.cs file at the Document project after line 58. using (StreamReader streamReader = new StreamReader(@D:\data\correctedXML.txt)) { documentContent.Xml = streamReader.ReadToEnd(); } It looks like this: ![alt text][1] Then load and check the content! Things you need to note: The copied XML will have double quotation mark! Delete the quotation mark. Make sure your corrected XML does not have “\n”. When you copy and paste, it usually copies unwanted characters too. Be careful with it. I found it easier to view with Text Visualizer then copy and paste the whole thing. You can save file as txt file because it gets converted into XML in later execution. I am sure there are lots of ways to execute but this was the way I was able to do it. Good luck. [1]:
    https://techoverflow.int.thomsonreuters.com/upfiles/loadXML.PNG

Answers

  • If the content is cases content, that is the correct team. They may have missed your email over the holidays, try emailing again. As far as editing XML, can you just make the changes you want to try in the debugger?
  • I can get the XML file using Easel. While debugging, it will go through XSL in Visual Studio but (raw)XML files are pulled from the Novus.
  • Rabin, I just replied to a comment of yours on another discussion, but I will reply here as well. If you attach the debugger and add a breakpoint just after the XML is retrieved from Novus, you should be able to manually update the document's XML to be your modified XML and then let the Document module process it the rest of the way.
  • Hey Joel, Can you tell me specific file and function to look out for! I followed this article(
    http://nsawiki.int.westgroup.com/wiki/index.php5/Newbies_Intro_to_Document#XML_End_Point_Example) to load local XML. However, now I am facing with "the breakpoint will not currently be hit" problem! So haven't got chance to load local XML. I will keep updating!