﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>C++博客-力为的技术博客-随笔分类-6. COM&amp;ATL&amp;WTL</title><link>http://www.cppblog.com/mythma/category/1927.html</link><description>C++QQ群：320523969，320523982</description><language>zh-cn</language><lastBuildDate>Tue, 31 Dec 2013 05:12:40 GMT</lastBuildDate><pubDate>Tue, 31 Dec 2013 05:12:40 GMT</pubDate><ttl>60</ttl><item><title>COM Interop遇到的几个问题</title><link>http://www.cppblog.com/mythma/archive/2013/12/31/COM_Interop_issues.html</link><dc:creator>力为</dc:creator><author>力为</author><pubDate>Tue, 31 Dec 2013 05:01:00 GMT</pubDate><guid>http://www.cppblog.com/mythma/archive/2013/12/31/COM_Interop_issues.html</guid><wfw:comment>http://www.cppblog.com/mythma/comments/205079.html</wfw:comment><comments>http://www.cppblog.com/mythma/archive/2013/12/31/COM_Interop_issues.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.cppblog.com/mythma/comments/commentRss/205079.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/mythma/services/trackbacks/205079.html</trackback:ping><description><![CDATA[<strong>错误症状</strong><br /><pre><ul><li><span style="font-family: verdana, 'courier new';">Error: Cannot register a logger before the MuxLogger has been initialized. <br /><br /></span></li><li><span style="font-family: verdana, 'courier new';">error C4772: #import referenced a type from a missing type library; '__missing_type__' used as a placeholder </span></li></ul><pre><ul><li><span style="font-family: verdana, 'courier new';">.Net编译失败，但没有任何错误提示消息。</span></li></ul><ul><li><span style="font-family: verdana, 'courier new';">C#中添加COM引用，有两种错误症状：（1）无法添加也没有错误消息 （2）VS直接Crash</span></li></ul><br /><strong>解决办法</strong><br />检查COM IDL，接口定义有问题。</pre></pre><img src ="http://www.cppblog.com/mythma/aggbug/205079.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/mythma/" target="_blank">力为</a> 2013-12-31 13:01 <a href="http://www.cppblog.com/mythma/archive/2013/12/31/COM_Interop_issues.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>用CImage加载内存里的Image (II)</title><link>http://www.cppblog.com/mythma/archive/2012/10/19/load_image_from_memory.html</link><dc:creator>力为</dc:creator><author>力为</author><pubDate>Fri, 19 Oct 2012 04:50:00 GMT</pubDate><guid>http://www.cppblog.com/mythma/archive/2012/10/19/load_image_from_memory.html</guid><wfw:comment>http://www.cppblog.com/mythma/comments/193519.html</wfw:comment><comments>http://www.cppblog.com/mythma/archive/2012/10/19/load_image_from_memory.html#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://www.cppblog.com/mythma/comments/commentRss/193519.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/mythma/services/trackbacks/193519.html</trackback:ping><description><![CDATA[06年的时候有过用CImage加载内存里的图片的需求，<a href="http://www.cppblog.com/mythma/archive/2006/06/10/8384.html">当时是这样做的</a>。<br /><br />多年后，再次看这个问题，发现更简单的办法：<br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #0000FF; ">void</span>&nbsp;LoadImage(<span style="color: #0000FF; ">void</span>*&nbsp;pBuffer,&nbsp;<span style="color: #0000FF; ">int</span>&nbsp;nSize,&nbsp;CImage&amp;&nbsp;img)<br />{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;COleStreamFile&nbsp;osf;<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;osf.CreateMemoryStream(NULL);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;osf.Write(pBuffer,&nbsp;nSize);<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;osf.SeekToBegin();<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;img.Load(osf.GetStream());<br />}</div><img src ="http://www.cppblog.com/mythma/aggbug/193519.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/mythma/" target="_blank">力为</a> 2012-10-19 12:50 <a href="http://www.cppblog.com/mythma/archive/2012/10/19/load_image_from_memory.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>我的原创技术随笔大全（2000~2009）</title><link>http://www.cppblog.com/mythma/archive/2010/01/09/105218.html</link><dc:creator>力为</dc:creator><author>力为</author><pubDate>Fri, 08 Jan 2010 17:13:00 GMT</pubDate><guid>http://www.cppblog.com/mythma/archive/2010/01/09/105218.html</guid><wfw:comment>http://www.cppblog.com/mythma/comments/105218.html</wfw:comment><comments>http://www.cppblog.com/mythma/archive/2010/01/09/105218.html#Feedback</comments><slash:comments>4</slash:comments><wfw:commentRss>http://www.cppblog.com/mythma/comments/commentRss/105218.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/mythma/services/trackbacks/105218.html</trackback:ping><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要:   二十一世纪的第一个十年过去了，回顾了一下这些年写的博客，发现自己也没闲着。但不免也有些遗憾，内容大都是关于知识、经验和技术，而关于思考和idea的却比较少。期待下一个十年吧！<br>    第一篇日志是在2004年发布在CSDN的博客上（记得开始不叫博客），截至到现在累积了不少东西了。为了怀念这过去的十年（2000~2003是个空白期，那段时间国内好像也没博客，网络也不发达，信息也闭塞），特整理了一下，称作我的原创技术随笔大全（2000~2009）&nbsp;&nbsp;<a href='http://www.cppblog.com/mythma/archive/2010/01/09/105218.html'>阅读全文</a><img src ="http://www.cppblog.com/mythma/aggbug/105218.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/mythma/" target="_blank">力为</a> 2010-01-09 01:13 <a href="http://www.cppblog.com/mythma/archive/2010/01/09/105218.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>让Toolbar显示大小不同的ICONs</title><link>http://www.cppblog.com/mythma/archive/2006/06/11/8422.html</link><dc:creator>力为</dc:creator><author>力为</author><pubDate>Sun, 11 Jun 2006 07:39:00 GMT</pubDate><guid>http://www.cppblog.com/mythma/archive/2006/06/11/8422.html</guid><wfw:comment>http://www.cppblog.com/mythma/comments/8422.html</wfw:comment><comments>http://www.cppblog.com/mythma/archive/2006/06/11/8422.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.cppblog.com/mythma/comments/commentRss/8422.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/mythma/services/trackbacks/8422.html</trackback:ping><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: It's said in MSDN that:“Microsoft Windows assumes that all of a toolbar's bitmapped images are the same size. ” So the question is : How can we implement a toolbar with different sized images, which is just like as Google Toolbar?&nbsp;&nbsp;<a href='http://www.cppblog.com/mythma/archive/2006/06/11/8422.html'>阅读全文</a><img src ="http://www.cppblog.com/mythma/aggbug/8422.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/mythma/" target="_blank">力为</a> 2006-06-11 15:39 <a href="http://www.cppblog.com/mythma/archive/2006/06/11/8422.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>用CImage加载内存里的Image</title><link>http://www.cppblog.com/mythma/archive/2006/06/10/8384.html</link><dc:creator>力为</dc:creator><author>力为</author><pubDate>Sat, 10 Jun 2006 08:49:00 GMT</pubDate><guid>http://www.cppblog.com/mythma/archive/2006/06/10/8384.html</guid><wfw:comment>http://www.cppblog.com/mythma/comments/8384.html</wfw:comment><comments>http://www.cppblog.com/mythma/archive/2006/06/10/8384.html#Feedback</comments><slash:comments>14</slash:comments><wfw:commentRss>http://www.cppblog.com/mythma/comments/commentRss/8384.html</wfw:commentRss><trackback:ping>http://www.cppblog.com/mythma/services/trackbacks/8384.html</trackback:ping><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: 问题：已知一块内存，知道里面是一张图片的数据，如何显示出来？&nbsp;&nbsp;<a href='http://www.cppblog.com/mythma/archive/2006/06/10/8384.html'>阅读全文</a><img src ="http://www.cppblog.com/mythma/aggbug/8384.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.cppblog.com/mythma/" target="_blank">力为</a> 2006-06-10 16:49 <a href="http://www.cppblog.com/mythma/archive/2006/06/10/8384.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>