<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Howard Xin on Medium]]></title>
        <description><![CDATA[Stories by Howard Xin on Medium]]></description>
        <link>https://medium.com/@HowardXin?source=rss-8b9b459891c2------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*5uvZ5DjXVxlIocCrVx7Beg.png</url>
            <title>Stories by Howard Xin on Medium</title>
            <link>https://medium.com/@HowardXin?source=rss-8b9b459891c2------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 23 May 2026 16:25:52 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@HowardXin/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com" rel="hub"/>
        <item>
            <title><![CDATA[Read/write values from Excel data source file in Coded UI Test]]></title>
            <link>https://medium.com/@HowardXin/read-write-values-from-excel-data-source-file-in-coded-ui-test-de822bc95cfa?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/de822bc95cfa</guid>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Tue, 16 May 2017 19:04:16 GMT</pubDate>
            <atom:updated>2017-05-16T19:04:16.353Z</atom:updated>
            <content:encoded><![CDATA[<p>Reading DataSource and then writing back with updated data will NOT work, because every iteration the test [TestMethod] is executed with the <em>original</em> Data Source. Updated data from last iteration will be overwritten in each iteration. You end up with only one row of updated data from the very last iteration.</p><p><strong>Solution</strong>: (No real solution unless Microsoft makes changes, but rather a workaround)</p><p>Manually make a copy of the Data Source file before running the test, then while still utilizing Data Source,</p><pre>data.xlsx</pre><pre>Scenario SecondCol Result</pre><pre>89       23        Value</pre><pre>11       800       Value</pre><pre>888      111       Value</pre><ol><li>Load data from the copied file</li><li>Update the data</li><li>Overwrite the copied file</li></ol><p>The following is an example, data.xlsx is the Excel Data Source file, newdata.xlsx is the copy you make before running tests.</p><pre>[TestMethod]<br>[DataSource(&quot;System.Data.Odbc&quot;, &quot;Dsn=Excel Files;Driver={Microsoft Excel Driver (*.xls)};dbq=|DataDirectory|\\data.xlsx;defaultdir=.;driverid=790;maxbuffersize=2048;pagetimeout=5;readonly=false&quot;, &quot;Sheet1$&quot;, DataAccessMethod.Sequential)] // This is working Excel.xlsx connection!!! Excel (ODBC, Dsn)<br><br>public void ExcelReadWrite()<br>{<br>    //Open copied Excel file and create Excel object<br>    string projectName = System.Reflection.Assembly.GetExecutingAssembly().GetName().Name;<br>    string dir = Environment.CurrentDirectory + @&quot;\..\..\..\&quot;;<br>    string targetFilename = &quot;newdata.xlsx&quot;;<br>    string targetFile = dir + projectName + @&quot;\&quot; + targetFilename;<br><br>    object missing = Type.Missing;<br>    object misValue = System.Reflection.Missing.Value;<br>    Excel.Application excel = new Excel.Application();<br>    Excel.Workbook wb = excel.Workbooks.Open(targetFile, true, false);<br>    Excel.Worksheet ws = wb.Sheets[1];<br>    Excel.Range wr = ws.UsedRange;<br>    int rowCount = wr.Rows.Count;<br>    int colCount = wr.Columns.Count;<br><br>    //make some example data update for current iteration <br>    int row = TestContext.DataRow.Table.Rows.IndexOf(TestContext.DataRow); //current iteration data row. zero base<br>    int generatedData = Convert.ToInt32(TestContext.DataRow[0]) + Convert.ToInt32(TestContext.DataRow[1]); //read from DataSource<br>    ws.Cells[row + 2, 3] = generatedData; //Worksheet, not zero base, and header row counts<br>    // ======================================================<br>    ws = wb.ActiveSheet;<br>    excel.DisplayAlerts = false;<br><br>    wb.SaveAs(targetFile, Excel.XlFileFormat.xlWorkbookDefault, misValue,<br>                                         misValue, misValue, misValue,<br>                                         Excel.XlSaveAsAccessMode.xlExclusive, misValue,<br>                                         misValue, misValue, misValue, misValue);<br>    wb.Close(missing, missing, missing);<br>    excel.Quit();<br>}</pre><p>Don&#39;t try to copy the Data Source file within [TestInitialize] as that will be executed before every iteration as well.</p><p><a href="http://stackoverflow.com/a/44006849/2719588">Read/write values from Excel data source file</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=de822bc95cfa" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[.xlsx Excel files as Data Source in Coded UI test]]></title>
            <link>https://medium.com/geekward-note/xlsx-excel-files-as-data-source-in-coded-ui-test-dd0ab0f55ac9?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/dd0ab0f55ac9</guid>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[codedui]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Tue, 02 May 2017 20:47:54 GMT</pubDate>
            <atom:updated>2017-05-03T19:36:51.498Z</atom:updated>
            <content:encoded><![CDATA[<p>I want to use “.xlsx” format Excel file as Data Source in my hand coding Coded UI test. The best information I get is found in MSDN: <a href="https://msdn.microsoft.com/en-us/library/ee624082.aspx">Creating a Data-Driven Coded UI Test</a>, which has useful information regarding of various data format as below, but it doesn’t mention about the “.xlsx” format.</p><p>After some more googling and experiment, I finally managed to get it to work. In order to save time for me and someone who might face the same challenge again, I think it’s beneficial to document the connection strings and some key points to pay attention to here as later reference.</p><p>The following are the data source strings found in the MSDN page:</p><p><strong>Data Source Types and Attributes</strong></p><ul><li>CSV</li></ul><pre>[DataSource(“Microsoft.VisualStudio.TestTools.DataSource.CSV”, “|DataDirectory|\\data.csv”, “data#csv”, DataAccessMethod.Sequential), DeploymentItem(“data.csv”), TestMethod]</pre><ul><li>Excel</li></ul><pre>[DataSource(“System.Data.Odbc”, “Dsn=ExcelFiles;Driver={Microsoft Excel Driver (*.xls)};dbq=|DataDirectory|\\Data.xls;defaultdir=.;driverid=790;maxbuffersize=2048;pagetimeout=5;readonly=true”, “Sheet1$”, DataAccessMethod.Sequential), DeploymentItem(“Sheet1.xls”), TestMethod]</pre><ul><li>Test case in Team Foundation Server</li></ul><pre>[DataSource(“Microsoft.VisualStudio.TestTools.DataSource.TestCase”, “<a href="http://vlm13261329:8080/tfs/DefaultCollection;Agile">http://vlm13261329:8080/tfs/DefaultCollection;Agile</a>&quot;, “30”, DataAccessMethod.Sequential), TestMethod]</pre><ul><li>XML</li></ul><pre>[DataSource(“Microsoft.VisualStudio.TestTools.DataSource.XML”, “|DataDirectory|\\data.xml”, “Iterations”, DataAccessMethod.Sequential), DeploymentItem(“data.xml”), TestMethod]</pre><ul><li>SQL Express</li></ul><pre>[DataSource(“System.Data.SqlClient”, “Data Source=.\\sqlexpress;Initial Catalog=tempdb;Integrated Security=True”, “Data”, DataAccessMethod.Sequential), TestMethod]</pre><p>I know I can convert the “.xlsx” format into the old format “.xls”, but I rather have more options than less.</p><p>Here is the Attributes:</p><p><strong>Data Source Types and Attributes</strong></p><ul><li>Excel, “.xlsx” format</li></ul><pre>[TestMethod][DataSource(&quot;System.Data.Odbc&quot;, &quot;Dsn=Excel Files;Driver={Microsoft Excel Driver (<strong>*.xls</strong>)};dbq=|DataDirectory|\\<strong>data.xlsx</strong>;defaultdir=.;driverid=790;maxbuffersize=2048;pagetimeout=5;readonly=true&quot;, &quot;<strong>Sheet1$</strong>&quot;, DataAccessMethod.Sequential)]</pre><p>where “<strong>data.xlsx</strong>” is the Excel file you want to use as Data Source, “<strong>Sheet1$</strong>” is the worksheet you are using in the Excel file. Using this to replace the normal [TestMethod] attribute before the test method.</p><p>If this is not working, check the following:</p><ol><li>Add “data.xlsx” Excel file to your CodedUI Project:<br>Right Click Project -&gt; Add -&gt; Existing Item… -&gt; Add</li><li>Check “data.xlsx” Properties in VS, make sure to set “Copy to Output Directory” Property to “Copy always” or “Copy if newer”</li><li>If you get a connection error, it’s most likely due to the fact that you don’t have the 2007 Office System Driver installed for the OLEDB provider. (Thanks to <a href="http://blog.danbrust.net/2013/10/10/installing-microsoft-office-data-connectivity-components/#.WQc2p_nyvIU">blog.danbrust.net </a>and <a href="http://incyclesoftware.com/2015/06/coded-ui-testing-with-excel-xlsx-files/">incyclesoftware</a>), you can download it from the following Microsoft link:<br><a href="http://www.microsoft.com/en-us/download/details.aspx?id=23734">Link 2007 Office System Driver: Data Connectivity Components</a></li></ol><p>This will install the Office 2007 drivers. Since the Access and Excel file formats haven’t changed since 2007, these drivers work just fine with Office 2010, 2016, etc.</p><p>Another comment for CSV file: if CSV file is not working, check the encoding. It should be ANSI or UTF-8 <strong><em>without </em></strong>BOM.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dd0ab0f55ac9" width="1" height="1" alt=""><hr><p><a href="https://medium.com/geekward-note/xlsx-excel-files-as-data-source-in-coded-ui-test-dd0ab0f55ac9">.xlsx Excel files as Data Source in Coded UI test</a> was originally published in <a href="https://medium.com/geekward-note">jot down note</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Switch from Wordpress]]></title>
            <link>https://medium.com/@HowardXin/switch-from-wordpress-bfe6970486d6?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/bfe6970486d6</guid>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Tue, 02 May 2017 17:43:59 GMT</pubDate>
            <atom:updated>2017-05-02T17:46:43.034Z</atom:updated>
            <content:encoded><![CDATA[<p>Wordpress is blocked from work network from publishing and all admin features. So I need to switch to something else in order to note down something in the moment I need to.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bfe6970486d6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My Sites loading forever]]></title>
            <link>https://medium.com/@HowardXin/my-sites-loading-forever-abcd268f881f?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/abcd268f881f</guid>
            <category><![CDATA[general]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Mon, 01 May 2017 15:05:56 GMT</pubDate>
            <atom:updated>2017-05-02T18:10:30.679Z</atom:updated>
            <content:encoded><![CDATA[<p>After a few years, I decide to post something on one of my WordPress site, but don’t remember my site url. I can login to my account, thanks to LastPass, but WordPress doesn’t load my sites. Clicking My Sites link on the banner, it’s “Loading My Sites…” forever.</p><p>Well, it turned out to be that it’s a problem with the company network I am working with. It doesn’t have problem from my home network.</p><p>Is there anything I can do with this restriction? As for some thoughts or solutions, it’s better to note them down right away.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=abcd268f881f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My Sites loading forever]]></title>
            <link>https://medium.com/geekward-note/my-sites-loading-forever-e89c40f759a3?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/e89c40f759a3</guid>
            <category><![CDATA[general]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Mon, 01 May 2017 15:05:56 GMT</pubDate>
            <atom:updated>2017-05-02T19:06:34.338Z</atom:updated>
            <content:encoded><![CDATA[<p>After a few years, I decide to post something on one of my WordPress site, but don’t remember my site url. I can login to my account, thanks to LastPass, but WordPress doesn’t load my sites. Clicking My Sites link on the banner, it’s “Loading My Sites…” forever.</p><p>Well, it turned out to be that it’s a problem with the company network I am working with. It doesn’t have problem from my home network.</p><p>Is there anything I can do with this restriction? As for some thoughts or solutions, it’s better to note them down right away.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e89c40f759a3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/geekward-note/my-sites-loading-forever-e89c40f759a3">My Sites loading forever</a> was originally published in <a href="https://medium.com/geekward-note">jot down note</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My .vimrc settings]]></title>
            <link>https://medium.com/geekward-note/my-vimrc-settings-723d26d92cca?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/723d26d92cca</guid>
            <category><![CDATA[general]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Tue, 05 Nov 2013 16:37:43 GMT</pubDate>
            <atom:updated>2017-05-02T19:06:34.526Z</atom:updated>
            <content:encoded><![CDATA[<p>I added these lines at the end of my .vimrc (_vimrc in Windows)</p><p>[code lang=”text” light=”true”]<br>set expandtab<br>set shiftwidth=4<br>set tabstop=4<br>set smartindent<br>set number<br>color slate<br>set guifont=peep:h11:cOEM<br>set linespace=0<br>set guioptions=egrLtm<br>[/code]</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=723d26d92cca" width="1" height="1" alt=""><hr><p><a href="https://medium.com/geekward-note/my-vimrc-settings-723d26d92cca">My .vimrc settings</a> was originally published in <a href="https://medium.com/geekward-note">jot down note</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My .vimrc settings]]></title>
            <link>https://medium.com/@HowardXin/my-vimrc-settings-b1fa27b38788?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/b1fa27b38788</guid>
            <category><![CDATA[general]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Tue, 05 Nov 2013 16:37:43 GMT</pubDate>
            <atom:updated>2017-05-02T18:10:28.154Z</atom:updated>
            <content:encoded><![CDATA[<p>I added these lines at the end of my .vimrc (_vimrc in Windows)</p><p>[code lang=”text” light=”true”]<br>set expandtab<br>set shiftwidth=4<br>set tabstop=4<br>set smartindent<br>set number<br>color slate<br>set guifont=peep:h11:cOEM<br>set linespace=0<br>set guioptions=egrLtm<br>[/code]</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b1fa27b38788" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Add or Remove the menu bar and toolbar from gvim]]></title>
            <link>https://medium.com/@HowardXin/add-or-remove-the-menu-bar-and-toolbar-from-gvim-97506f841b30?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/97506f841b30</guid>
            <category><![CDATA[info]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Mon, 10 Jun 2013 00:01:42 GMT</pubDate>
            <atom:updated>2017-05-02T18:10:40.748Z</atom:updated>
            <content:encoded><![CDATA[<p>In _vimrc file:</p><p>“ Add menu bar<br>set guioption+=m</p><p>“ Add toolbar<br>set guioptions+=T</p><p>“ Remove menu bar<br>set guioptions-=m</p><p>“ Remove toolbar<br>set guioptions-=T</p><p>While already in gvim, enter command line mode, for example:</p><p>:set guioptions-=m</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=97506f841b30" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Add or Remove the menu bar and toolbar from gvim]]></title>
            <link>https://medium.com/geekward-note/add-or-remove-the-menu-bar-and-toolbar-from-gvim-ed51d17b6766?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/ed51d17b6766</guid>
            <category><![CDATA[info]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Mon, 10 Jun 2013 00:01:42 GMT</pubDate>
            <atom:updated>2017-05-02T19:06:57.637Z</atom:updated>
            <content:encoded><![CDATA[<p>In _vimrc file:</p><p>“ Add menu bar<br>set guioption+=m</p><p>“ Add toolbar<br>set guioptions+=T</p><p>“ Remove menu bar<br>set guioptions-=m</p><p>“ Remove toolbar<br>set guioptions-=T</p><p>While already in gvim, enter command line mode, for example:</p><p>:set guioptions-=m</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ed51d17b6766" width="1" height="1" alt=""><hr><p><a href="https://medium.com/geekward-note/add-or-remove-the-menu-bar-and-toolbar-from-gvim-ed51d17b6766">Add or Remove the menu bar and toolbar from gvim</a> was originally published in <a href="https://medium.com/geekward-note">jot down note</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Retrieve App Logs from Stackato Client]]></title>
            <link>https://medium.com/@HowardXin/retrieve-app-logs-from-stackato-client-21105c7b3a22?source=rss-8b9b459891c2------2</link>
            <guid isPermaLink="false">https://medium.com/p/21105c7b3a22</guid>
            <category><![CDATA[jobs]]></category>
            <dc:creator><![CDATA[Howard Xin]]></dc:creator>
            <pubDate>Thu, 23 May 2013 20:35:47 GMT</pubDate>
            <atom:updated>2017-05-02T18:10:29.963Z</atom:updated>
            <content:encoded><![CDATA[<h3>The stackato client is used for interacting with the system from the command line.</h3><ol><li><a href="http://www.activestate.com/stackato/download_client">Download the client</a> for your platform (Windows, OS X, Linux x86, Linux x64)</li><li>Unzip the archive in a convenient directory.</li><li>Add the the executable to your system/shell $PATH by:</li><li>moving it to a directory in your $PATH,</li><li>creating a symlink from a directory in your $PATH, or</li><li>creating a shell alias for the executable.</li><li>Confirm that the client is installed correctly by running stackato -v or stackato help.</li></ol><p>To connect the stackato client from you favorite command line interface, you will need to specify the API Endpoint, which is the hostname prepended with “api.”: api.stackato-pry5.local</p><h4>Target and Login</h4><p>PS C:\stackato&gt; <strong>stackato target api.stackato-pry5.local</strong><br>Successfully targeted to [<a href="https://api.us.fixmocloud.com/">https://api.stackato-pry5.local</a>]<br>PS C:\stackato&gt; <strong>stackato login</strong><br>Attempting login to [<a href="https://api.us.fixmocloud.com/">https://api.stackato-pry5.local</a>]<br>Email: <strong>&lt;your email account&gt;@foobar.com</strong><br>Password: <strong>******************</strong><br>Successfully logged into [<a href="https://api.us.fixmocloud.com/">https://api.stackato-pry5.local</a>]<br>Reset current group: OK</p><h4>Group and Apps</h4><p>PS C:\stackato&gt; <strong>stackato group f5qa</strong><br>Successfully set current group to [f5qa]<br>PS C:\stackato&gt;<strong> stackato apps</strong></p><figure><img alt="stackatoclient" src="https://cdn-images-1.medium.com/max/853/0*x9iLQ7q0WsT233tp.png" /></figure><h4>Stackato Logs</h4><p>To view and application log stream, use the stackato logs command:</p><pre>PS C:\stackato&gt; stackato logs [myapp]<br>PS C:\stackato&gt; <strong>stackato logs f5qarc4-console</strong></pre><p>To limit the number of lines displayed, use the — num option:</p><p>PS C:\stackato&gt; stackato logs [myapp] — num 50<br>To view log stream as it is updated, use the — follow option:</p><p>PS C:\stackato&gt; stackato logs [myapp] — follow</p><blockquote>Note stackato logs buffers only 400 lines of the log stream history (i.e. lines generated prior to it being run). If you need earlier log lines, use the stackato files command to fetch the relevant log file from the logs/ directory</blockquote><p>You can save whatever you get to your local machine by using redirection operators:</p><p>PS C:\stackato&gt; <strong>stackato logs f5qarc4-relay — num 50 &gt;&gt; relaylog01.txt</strong><br>PS C:\stackato&gt; <strong>stackato logs f5qarc4-relay — follow</strong></p><h4>Stackato Files</h4><p>PS C:\stackato&gt; stackato files [appname] [path] [–all]</p><p>PS C:\stackato&gt; <strong>stackato files f5qarc4-relay /logs</strong><br>staging.log 16B<br>stderr.log 1.4K<br>stdout.log 67.9M<br>stdout.log.1.gz 6.8M<br>stdout.log.2.gz 6.9M<br>stdout.log.3.gz 7.0M<br>stdout.log.4.gz 7.0M<br>stdout.log.5.gz 8.4M<br>stdout.log.6.gz 7.3M<br>stdout.log.7.gz 7.4M<br>stdout.log.8.gz 7.4M<br>stdout.log.9.gz 8.8M<br>PS C:\stackato&gt; <strong>stackato files f5qarc4-relay /logs/stderr.log &gt;&gt; relay-stderr.log</strong><br>PS C:\stackato&gt;</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=21105c7b3a22" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>