<p>Has anybody used C# to write a sample screen scraper for IBM as400?</p>

[{'answer_id': 64928, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': 0, 'selected': False, 'text': "<p>I wrote one in C many years ago for a project at Frigidaire.  The internal card would cause all sorts of fun with memory leaks but I eventually found a solution by allocating arrays at the boundary of the communication card.  This was over 8 years ago, I'm sure today's cards are much better and/or using native comm to read the AS400 screens.</p>\n"}, {'answer_id': 121028, 'author': 'Mike Wills', 'author_id': 2535, 'author_profile': 'https://Stackoverflow.com/users/2535', 'pm_score': 0, 'selected': False, 'text': '<p>You might want to look at the new features in PHP. The latest version of PHP has a 5250 processor that allows you to create a webapp that acts like it is interacting with the green-screen. <a href="http://www.zend.com/en/products/platform/i5os/5250" rel="nofollow noreferrer">5250 Bridge Info</a></p>\n\n<p>I realize that you wanted C#, but I haven\'t seen anything supported that directly interacts with the screens. Maybe write a PHP app to connect to the 5250 and connect your C# from there.</p>\n'}, {'answer_id': 303594, 'author': 'Joshua Turner', 'author_id': 820, 'author_profile': 'https://Stackoverflow.com/users/820', 'pm_score': 2, 'selected': False, 'text': '<p><a href="http://www.codeproject.com/KB/cs/all_ehllapi.aspx" rel="nofollow noreferrer">http://www.codeproject.com/KB/cs/all_ehllapi.aspx</a></p>\n\n<p>I\'ve modified this example and it works just fine.</p>\n'}, {'answer_id': 35151471, 'author': 'Abhishek Tomar', 'author_id': 4208247, 'author_profile': 'https://Stackoverflow.com/users/4208247', 'pm_score': 2, 'selected': False, 'text': "<p>When using interop.AutOIATypeLibrary and interop.AutPSTypeLibrary for building a class library. It throws error as below\nUnable to cast COM object of type 'AutPSTypeLibrary.AutPSClass' to interface type 'AutPSTypeLibrary.IAutPS'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{891FC4A1-7DD8-11D0-9112-0004AC3617E1}' failed due to the following error: No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE))</p>\n\n<p>I am using VS2017, Framework 4.5. Interop Dlls are registered using regasm.exe in framework64, Reference added</p>\n\n<p>Above Dlls works fine, while creating project with Console Application/Win form application.</p>\n"}, {'answer_id': 54542089, 'author': 'Ashetynw', 'author_id': 9911023, 'author_profile': 'https://Stackoverflow.com/users/9911023', 'pm_score': 1, 'selected': False, 'text': '<p>I work with these libraries every day. Feel free to message me if you need anything.</p>\n\n<p>Example:</p>\n\n<pre><code>using AutOIATypeLibrary;\nusing AutPSTypeLibrary;\n\nnamespace MyNamespace\n{\n    public class Program \n    {\n         public AutPS PS = new AutPS();\n         public AutOIA OI = new AutOIA();\n         static void Main()\n        {\n            PS.SetConnectionByName("A");\n            OI.SetConnectionByName("A");\n             // Gets a string from the presentation space at row 1, col 1, length 5\n            PS.GetText(1, 1, 5); \n\n            // Gets the entire screen as a string. parse as needed.\n            PS.GetText(1, 1, PS.NumRows * PS.NumCols);\n\n            // Searches for a literal string in the presentation space by going forward from your row/col\n            PS.SearchText("LiteralString".ToUpper(), PsDir.pcSrchForward, 1, 1);\n        }\n    }\n}\n</code></pre>\n'}]
['https://Stackoverflow.com/questions/64848', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/-1/']