{"id":563,"date":"2010-04-28T03:44:07","date_gmt":"2010-04-27T18:44:07","guid":{"rendered":"http:\/\/qos.mine.nu\/2010\/04\/getwindowtextaafafafafaaaeaaeiyaeasaeaafaafaeiy.html"},"modified":"2010-04-28T09:28:16","modified_gmt":"2010-04-28T00:28:16","slug":"getwindowtextaafafafafaaaeaaeiyaeasaeaafaafaeiy","status":"publish","type":"post","link":"https:\/\/qos.dev7.net\/wordpress\/2010\/04\/getwindowtextaafafafafaaaeaaeiyaeasaeaafaafaeiy.html","title":{"rendered":"GetWindowText\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u306f\u6587\u5b57\u6570\uff1f\u623b\u308a\u5024\u306f\u30d0\u30a4\u30c8\u6570\uff1f"},"content":{"rendered":"<div id=\"wppda_alert\">\u3053\u306e\u8a18\u4e8b\u306f\uff12\u5e74\u4ee5\u4e0a\u524d\u306b\u66f8\u3044\u305f\u3082\u306e\u3067\u3059\u3002<br\/>\r\n\u305d\u306e\u305f\u3081\u60c5\u5831\u304c\u53e4\u3044\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002\u3054\u4e86\u627f\u304f\u3060\u3055\u3044\u3002m(_ _)m<\/div><p><a href=\"http:\/\/msdn.microsoft.com\/ja-jp\/library\/cc364815.aspx\">GetWindowText \u95a2\u6570<\/a>\u3092\u898b\u308b\u3068\u3001<\/p>\n<blockquote>\n<p>int GetWindowText(      <br \/>&#160; HWND hWnd,&#160;&#160;&#160;&#160;&#160;&#160;&#160; \/\/ \u30a6\u30a3\u30f3\u30c9\u30a6\u307e\u305f\u306f\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb\u306e\u30cf\u30f3\u30c9\u30eb       <br \/>&#160; LPTSTR lpString,&#160; \/\/ \u30c6\u30ad\u30b9\u30c8\u30d0\u30c3\u30d5\u30a1       <br \/>&#160; int nMaxCount&#160;&#160;&#160;&#160; \/\/ \u30b3\u30d4\u30fc\u3059\u308b\u6700\u5927\u6587\u5b57\u6570       <br \/>);       <\/p>\n<h6>\u30d1\u30e9\u30e1\u30fc\u30bf<\/h6>\n<dl>\n<dt><em>hWnd<\/em> <\/dt>\n<dd>\u30a6\u30a3\u30f3\u30c9\u30a6\uff08 \u307e\u305f\u306f\u30c6\u30ad\u30b9\u30c8\u3092\u6301\u3064\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb\uff09\u306e\u30cf\u30f3\u30c9\u30eb\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002 <\/dd>\n<dt><em>lpString<\/em> <\/dt>\n<dd>\u30d0\u30c3\u30d5\u30a1\u3078\u306e\u30dd\u30a4\u30f3\u30bf\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002\u3053\u306e\u30d0\u30c3\u30d5\u30a1\u306b\u30c6\u30ad\u30b9\u30c8\u304c\u683c\u7d0d\u3055\u308c\u307e\u3059\u3002 <\/dd>\n<dt><em>nMaxCount<\/em> <\/dt>\n<dd>\u30d0\u30c3\u30d5\u30a1\u306b\u30b3\u30d4\u30fc\u3059\u308b\u6587\u5b57\u306e\u6700\u5927\u6570\u3092\u6307\u5b9a\u3057\u307e\u3059\u3002\u30c6\u30ad\u30b9\u30c8\u306e\u3053\u306e\u30b5\u30a4\u30ba\u3092\u8d85\u3048\u308b\u90e8\u5206\u306f\u3001\u5207\u308a\u6368\u3066\u3089\u308c\u307e\u3059\u3002NULL \u6587\u5b57\u3082\u6570\u306b\u542b\u3081\u3089\u308c\u307e\u3059\u3002<\/dd>\n<\/dl>\n<h6>\u623b\u308a\u5024<\/h6>\n<p>\u95a2\u6570\u304c\u6210\u529f\u3059\u308b\u3068\u3001\u30b3\u30d4\u30fc\u3055\u308c\u305f\u6587\u5b57\u5217\u306e\u6587\u5b57\u6570\u304c\u8fd4\u308a\u307e\u3059\uff08 \u7d42\u7aef\u306e NULL \u6587\u5b57\u306f\u542b\u3081\u3089\u308c\u307e\u305b\u3093\uff09\u3002\u30bf\u30a4\u30c8\u30eb\u30d0\u30fc\u3084\u30c6\u30ad\u30b9\u30c8\u304c\u306a\u3044\u5834\u5408\u3001\u30bf\u30a4\u30c8\u30eb\u30d0\u30fc\u304c\u7a7a\u306e\u5834\u5408\u3001\u304a\u3088\u3073 <em>hWnd <\/em>\u30d1\u30e9\u30e1\u30fc\u30bf\u306b\u6307\u5b9a\u3057\u305f\u30a6\u30a3\u30f3\u30c9\u30a6\u30cf\u30f3\u30c9\u30eb\u307e\u305f\u306f\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb\u30cf\u30f3\u30c9\u30eb\u304c\u7121\u52b9\u306a\u5834\u5408\u306f 0 \u304c\u8fd4\u308a\u307e\u3059\u3002\u62e1\u5f35\u30a8\u30e9\u30fc\u60c5\u5831\u3092\u53d6\u5f97\u3059\u308b\u306b\u306f\u3001 \u95a2\u6570\u3092\u4f7f\u3044\u307e\u3059\u3002<\/p>\n<p>\u4ed6\u306e\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u30a8\u30c7\u30a3\u30c3\u30c8\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb\u306e\u30c6\u30ad\u30b9\u30c8\u3092\u3053\u306e\u95a2\u6570\u3067\u53d6\u5f97\u3059\u308b\u3053\u3068\u306f\u3067\u304d\u307e\u305b\u3093\u3002<\/p>\n<\/blockquote>\n<p>\u3068\u3042\u3063\u305f\u3002nMaxCount\u3068\u623b\u308a\u5024\u306e\u3069\u3061\u3089\u3082\u3001\u6587\u5b57\u6570\u3068\u3042\u308b\u306e\u3067\u3001    <br \/>\u2193\u3053\u3093\u306a\u30bd\u30fc\u30b9\u66f8\u3044\u3066\u52d5\u304b\u3057\u3066\u307f\u305f\u3002(hWnd\u306e\u30bf\u30a4\u30c8\u30eb\u306b\u306f\u3001\u7d50\u69cb\u773a\u3081\u306e\u65e5\u672c\u8a9e\uff14\uff19\u6587\u5b57)<\/p>\n<pre class=\"csharpcode\"><span class=\"kwrd\">char<\/span> tmpBuffer[128];\n<span class=\"kwrd\">int<\/span> ret = GetWindowText(hWnd, tmpBuffer, 64);<\/pre>\n<style type=\"text\/css\">\n<p>.csharpcode, .csharpcode pre\n{\n\tfont-size: small;\n\tcolor: black;\n\tfont-family: consolas, \"Courier New\", courier, monospace;\n\tbackground-color: #ffffff;\n\t\/*white-space: pre;*\/\n}\n.csharpcode pre { margin: 0em; }\n.csharpcode .rem { color: #008000; }\n.csharpcode .kwrd { color: #0000ff; }\n.csharpcode .str { color: #006080; }\n.csharpcode .op { color: #0000c0; }\n.csharpcode .preproc { color: #cc6633; }\n.csharpcode .asp { background-color: #ffff00; }\n.csharpcode .html { color: #800000; }\n.csharpcode .attr { color: #ff0000; }\n.csharpcode .alt \n{\n\tbackground-color: #f4f4f4;\n\twidth: 100%;\n\tmargin: 0em;\n}\n.csharpcode .lnum { color: #606060; }<\/style>\n<p>\u3059\u308b\u3068\u3001\u3001\u3001ret\u306b\u300198\u304c\uff01\uff1f<br \/>\n  <br \/>\u623b\u308a\u5024\u306f\u30d0\u30a4\u30c8\u6570\u30fb\u30fb\u30fb\u306a\u306e\uff1f\uff1f\uff08\u7d50\u679c\u3092\u898b\u308b\u3068\u305d\u3046\u306a\u3093\u3060\u3051\u3069\u3002\uff09<\/p>\n<p><a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/ms633520(VS.85).aspx\">GetWindowText Function (Windows)<\/a>\u306b\u306f\u3001<\/p>\n<blockquote>\n<dl>\n<dt><em>nMaxCount<\/em> [in] <\/dt>\n<dd><strong>int<\/strong><\/dd>\n<dd>\n<p>Specifies the maximum number of characters to copy to the buffer, including the <strong>NULL<\/strong> character. If the text exceeds this limit, it is truncated.<\/p>\n<\/dd>\n<\/dl>\n<h5>Return Value<\/h5>\n<p><strong>int<\/strong><\/p>\n<p>If the function succeeds, the return value is the length, in characters, of the copied string, not including the terminating <strong>NULL<\/strong> character. If the window has no title bar or text, if the title bar is empty, or if the window or control handle is invalid, the return value is zero. To get extended error information, call<a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/ms679360(v=VS.85).aspx\">GetLastError<\/a>.<\/p>\n<p>This function cannot retrieve the text of an edit control in another application.<\/p>\n<\/blockquote>\n<p>\u30fbmaximum number of characters<\/p>\n<p>\u30fbthe return value is the length, in characters, of the copied string, \u2026<\/p>\n<p>\u307e\u3001\u5206\u304b\u3089\u306a\u3044\u3051\u3069\u3002\u3002<\/p>\n<p>Microsoft Visual C++ 2008\u306b\u3066\u3002<\/p>\n<p>(\u8ffd\u8a18)<\/p>\n<p>\u4f55\u304c\u60aa\u3044\u3063\u3066\u8a33\u3067\u306f\u306a\u3044\u3067\u3059\u304c\u3001\u3078\u3047\uff5e\u3002\u3063\u3066\u601d\u3063\u305f\u3060\u3051\u3002\u30d0\u30a4\u30c8\u6570\u8fd4\u3063\u3066\u3053\u306a\u3044\u3068\u3044\u308d\u3044\u308d\u3068\u9762\u5012\u305d\u3046\u3060\u3051\u3069\u306d\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3053\u306e\u8a18\u4e8b\u306f\uff12\u5e74\u4ee5\u4e0a\u524d\u306b\u66f8\u3044\u305f\u3082\u306e\u3067\u3059\u3002 \u305d\u306e\u305f\u3081\u60c5\u5831\u304c\u53e4\u3044\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002\u3054\u4e86\u627f\u304f\u3060\u3055\u3044\u3002m(_ _)mGetWindowText \u95a2\u6570\u3092\u898b\u308b\u3068\u3001 int GetWindowText( &#160; HWND hWnd &hellip; <a href=\"https:\/\/qos.dev7.net\/wordpress\/2010\/04\/getwindowtextaafafafafaaaeaaeiyaeasaeaafaafaeiy.html\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[126],"tags":[],"class_list":["post-563","post","type-post","status-publish","format-standard","hentry","category-afafaafaf"],"_links":{"self":[{"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/posts\/563","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/comments?post=563"}],"version-history":[{"count":2,"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/posts\/563\/revisions"}],"predecessor-version":[{"id":575,"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/posts\/563\/revisions\/575"}],"wp:attachment":[{"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/media?parent=563"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/categories?post=563"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/qos.dev7.net\/wordpress\/wp-json\/wp\/v2\/tags?post=563"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}