{"id":1132,"date":"2025-02-05T13:25:22","date_gmt":"2025-02-05T19:25:22","guid":{"rendered":"http:\/\/www.multitech.net\/developer\/?page_id=1132"},"modified":"2025-02-05T13:27:42","modified_gmt":"2025-02-05T19:27:42","slug":"c-example-code-2","status":"publish","type":"page","link":"https:\/\/www.multitech.net\/developer\/software\/faxfinder\/c-example-code-2\/","title":{"rendered":"C# Example Code"},"content":{"rendered":"<h4>Overview<\/h4>\n<hr \/>\n<ul>\n<li>\n<div>A very basic C# code sample that will allows to send a fax to the Multitech Fax Finder device using Web Service API.<\/div>\n<\/li>\n<\/ul>\n<h4>Prerequisites<\/strong><\/h4>\n<hr \/>\n<ul>\n<li>Download and Install Visual C# 2008 Express Edition<a href=\"http:\/\/www.microsoft.com\/express\/Downloads\/\"> http:\/\/www.microsoft.com\/express\/Downloads\/<\/a><\/li>\n<li>Download the C# sample source code Sendfax-Csharp.zip <a href=\"https:\/\/webfiles.multitech.com\/engineering\/sample-code\/fax-finder\/c-sharp\/\">here<\/a><\/li>\n<\/ul>\n<p>Note:<\/p>\n<ul>\n<li>The <code>scheldule.xml<\/code> is located under the <code>\/SendFax\/SendFax<\/code> folder.<\/li>\n<\/ul>\n<h4>Modify schedule.xml<\/strong><\/h4>\n<hr \/>\n<p>Load the schedule.xml file into your favorite editor, find the section below, and modify the fax number to point to your recipient fax number:<\/p>\n<p><code><br \/>\n &lt;recipient&gt;<br \/>\n    ...<br \/>\n    &lt;fax_number&gt;<em><strong>5138<\/em><\/strong>&lt;\/fax_number&gt;<br \/>\n &lt;\/recipient&gt;<br \/>\n<\/code><\/p>\n<p>Save it.<\/p>\n<h4>Modify Program.cs<\/strong><\/h4>\n<hr \/>\n<p>Double Clicks on the SendFax.sln to load it into the C# IDE. Modify the following:<\/p>\n<p> Change the user name and password to match yours.<\/p>\n<p><code>request.Credentials = new NetworkCredential(\"<em><strong>admin<\/strong><\/em>\", \"<em><strong>admin<\/strong><\/em>\");<\/code><\/p>\n<p>Change the IP address of the following line to point to your Fax Finder&#8217;s IP address.<\/p>\n<p><code>WebRequest request = WebRequest.Create(\"http:\/\/<em><strong>216.133.69.247<\/strong><\/em>\/ffws\/v1\/ofax\");<br \/>\n<\/code><\/p>\n<p>Change the file path to match yours.<\/p>\n<p><code>FileInfo fileSize = new FileInfo(\"<em><strong>C:\/Users\/test\/Documents\/Visual Studio\/2008\/Projects\/sendFax\/sendFax\/schedule.xml<\/strong><\/em>\");<\/code><\/p>\n<p><code>StreamReader textIn = new StreamReader(new FileStream(\"<em><strong>C:\/Users\/test\/Documents\/Visual Studio 2008\/Projects\/sendFax\/sendFax\/schedule.xml\",<\/em><\/strong>FileMode.Open,FileAccess.Read));<\/code><\/p>\n<p>Save and Run it.<\/p>\n<p>Now, if you web into your FaxFinder device and go to Status &amp; Log -&gt; Fax Status, you should be able to see the Fax Finder is sending out a fax.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Overview A very basic C# code sample that will allows to send a fax to the Multitech Fax Finder device using Web Service API. Prerequisites Download and Install Visual C# 2008 Express Edition http:\/\/www.microsoft.com\/express\/Downloads\/ Download the C# sample source code Sendfax-Csharp.zip here Note: The scheldule.xml is located under the \/SendFax\/SendFax folder. Modify schedule.xml Load the [&hellip;]<\/p>\n","protected":false},"author":16,"featured_media":0,"parent":131,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"footnotes":""},"class_list":["post-1132","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/1132","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/users\/16"}],"replies":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/comments?post=1132"}],"version-history":[{"count":30,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/1132\/revisions"}],"predecessor-version":[{"id":1631,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/1132\/revisions\/1631"}],"up":[{"embeddable":true,"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/pages\/131"}],"wp:attachment":[{"href":"https:\/\/www.multitech.net\/developer\/wp-json\/wp\/v2\/media?parent=1132"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}