<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>talkxe &#187; .NET</title>
	<atom:link href="http://www.riaxe.com/blog/category/net/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.riaxe.com/blog</link>
	<description>riaxe snippets</description>
	<lastBuildDate>Mon, 14 May 2012 07:11:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Console Application in C++ to get Window Titles</title>
		<link>http://www.riaxe.com/blog/net/console-application-in-c-to-get-window-titles/</link>
		<comments>http://www.riaxe.com/blog/net/console-application-in-c-to-get-window-titles/#comments</comments>
		<pubDate>Sun, 25 Dec 2011 06:07:22 +0000</pubDate>
		<dc:creator>Riaxe Admin</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Application]]></category>
		<category><![CDATA[C++]]></category>
		<category><![CDATA[Cosole]]></category>
		<category><![CDATA[Titles]]></category>
		<category><![CDATA[Window]]></category>

		<guid isPermaLink="false">http://www.riaxe.com/blog/?p=188</guid>
		<description><![CDATA[Hi All, I am not a .net guy but compiled this useful script to get the open window titles. ============================================== #include &#60;windows.h&#62;#include &#60;cstdio&#62; BOOL CALLBACK MyEnumWindowsProc(HWND hwnd, LPARAM lparam){    HWND lShellWindow = GetShellWindow();    int&#38; i = *(reinterpret_cast&#60;int*&#62;(lparam));    ++i;    char title[256];    ::GetWindowText(hwnd, title, sizeof(title));     if (hwnd == lShellWindow) return true;    if (!IsWindowVisible(hwnd)) return true;     <a href="http://www.riaxe.com/blog/net/console-application-in-c-to-get-window-titles/" class="more-link">More &#62;</a>]]></description>
			<content:encoded><![CDATA[<p>Hi All, I am not a .net guy but compiled this useful script to get the open window titles.</p>
<p>==============================================</p>
<p>#include &lt;windows.h&gt;<br />#include &lt;cstdio&gt;</p>
<p>BOOL CALLBACK MyEnumWindowsProc(HWND hwnd, LPARAM lparam)<br />{<br />    HWND lShellWindow = GetShellWindow();<br />    int&amp; i = *(reinterpret_cast&lt;int*&gt;(lparam));<br />    ++i;<br />    char title[256];<br />    ::GetWindowText(hwnd, title, sizeof(title));</p>
<p>    if (hwnd == lShellWindow) return true;<br />    if (!IsWindowVisible(hwnd)) return true;</p>
<p>    int lLength = GetWindowTextLength(hwnd);<br />    if (lLength == 0) return true;</p>
<p>    ::printf(title);<br />    ::printf(&#8220;\n&#8221;);<br />    return TRUE;<br />}</p>
<p>int main()<br />{<br />    int i = 0;<br />    ::EnumWindows(&amp;MyEnumWindowsProc, reinterpret_cast&lt;LPARAM&gt;(&amp;i));<br />    return 0;<br />}</p>
<p>&nbsp;</p>
<p>========================================</p>
<p>&nbsp;</p>
<p>Hope this helps <img src='http://www.riaxe.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>&nbsp;</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.riaxe.com%2Fblog%2Fnet%2Fconsole-application-in-c-to-get-window-titles%2F&amp;title=Console%20Application%20in%20C%2B%2B%20to%20get%20Window%20Titles"><img src="http://www.riaxe.com/blog/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.riaxe.com/blog/net/console-application-in-c-to-get-window-titles/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

