Home

OFF-SOFT.net

OFF-SOFT.net

This site is support & information site of WEB,and Software. This site might help you that create software or Web Site…perhaps?[:]

VC + + 2008 Express to compile the sample using WTL and Preferences

Published on| April 24th, 2009 | No Comment.
Description:
WTL for a bit, including his own studies, we decided to conduct a series of articles.
Today, Qt is offered by the LGPL, available for free than ever GUI library has been enhanced. At this late hour, WTL may have been like no time. However, while at this late hour, and if we have to sense the speed EZARU the scene to worry about file size, even in business, yet. Me at least.
When that, WTL, and good speed, size (MFC DLL as little unnecessary attachments) is smaller, if the screen is easy to make, so you can send an email, in person we have found useful.

Download
Articles: ResEdit resource editor, and VC + + 2008 Exp. To be linked to
What is the first place you WTL?
WTL is or what kind of first place?
There was a description of the MicroSoft website. We excerpt a portion.
Referenced: http://msdn.microsoft.com/en-us/magazine/cc163305.aspx
Windows R Template Library (WTL) is a developer, Windows Vista R r has recently released a new version of this excellent library fully supports almost all of the new user interface and extended functionality that was introduced. This month, ATEMASU focus on several new features in this latest release. WTL WTL and the Visual C + + R For those readers not familiar with the use of development environment, start with a brief description.
Visual C + + team has said it will generate the code small and fast as possible COM can easily create client and server, and Active Template Library (ATL) has been developed. Focus on developing user interface applications, which were later added support for COM is different from MFC, ATL COM from the beginning has been designed for development and successful. ATL, user interface development is not only basic support, a class that is provided is very useful as a lightweight unit and the base class for more sophisticated users INTAFEISURAIBURARI.
WTL is simple or complex as can be imagined, by a set of very rich class of templates for building applications, ATL expands. WTL is a Visual C + + is not included in, SourceForge Web site (http://sourceforge.net/projects/wtl) or the Microsoft Download Center are available to both.
WTL 8.0, Windows Vista UI was originally developed to support. So, I would touch the topic of several articles dealing with the author or a previous column. However, the important point of this month, a new enhanced WTL how to promote the introduction of these new features, it will be cut or how the code that developers need to write your own. MSDN R Magazine Web to download for this column is available from the site, the sample includes most of the features described in this article.

Download, SourceForge Web site (http://sourceforge.net/projects/wtl)行IMASHOU.

In the place in which it downloaded it, the license seems to be different.

After all, ATL (Active Template Library)-only screen? Expansion in (extended) I feel like a library.
ATL / WTL and banged the fixture is that it is such a relationship. Express in WTL is a problem when using, ATL it is not likeable. From the time of the 2005 Express, a lot was discussed. Even now, Express is, MFC and ATL are not included.
Is able to resolve the problem "Microsoft Platform SDK". This, MFC and ATL is included. (Old)
How do I take the old one, please see the table below. Microsoft Platform SDK for Windows Server 2003 SP1 are included in the ATL and MFC, VC + + 6.0 back.

ATL (/ WTL) MFC VC + +
3.0 6.0 (mfc42.dll) Visual C + + 6.0
7.0 7.0 (mfc70.dll) Visual C + +. NET 2002
7.1 (/ 7.5) 7.1 (mfc71.dll) Visual C + +. NET 2003
8.0 (/ 8.0) 8.0 (mfc80.dll) Visual C + + 2005
※ WTL version is out, ATL to the version that support new versions of WTL.
Sourceforge is the only version that is still published.

ATL version, or check it?
ATL, as the name, is a template library, the header is Basic. So you need a special DLL that is not the version, and it should examine how sources are listed in the header.

atldef.h
1
#define _ATL_VER 0x0300
This, ATL version.

Microsoft Platform SDK for Windows Server 2003 SP1, as described above, ATL 3.0 are included.

Preamble, and so little, Visual C + + 2008 Express + Microsoft Platform SDK actually try to use WTL.

First, install
Details of the installation, there are so many sites listed, please see there. Just follow the screen to install.

  1. Visual C + + 2008 Express Edition installed
  2. WindowsR Server 2003 SP1 Platform SDK, or (R2) Installation
  3. After the installation WTL, WTL for 2008 put the installation wizard to create applications.
    1. WTL for installation, ZIP and extract the files to copy.
    2. Installation of WTL in AppWiz setup90x.js running.
    For more information, http://www.sfc.wide.ad.jp/ ~ irino/blog/2008/09/visual-c-2008-expressappwizwtl8.php.
    In fact, I, setup80x.js copy and use it to reorganize themselves to fit in, not being as above, did not know until recently.
    So, it is not used, because our ancestors have been published, please use there.
    The following is just the author, which are randomly reorganized.
    We saved up for this site. (If you have no link above, Please click here if you do not mind. )


  4. Visual C + + 2008 Express Edition to the directory, WTL and directories, Platform SDK include directory to add the ATL.
    [Tools] -> [Optional] -> [Solutions and Projects -> [VC + + directory] -> In the Show directories: [Include files] Add
    • % Platform SDK installation directory% \ Include (example: C: \ Program Files \ Microsoft Platform SDK \ Include)
    • % Platform SDK installation directory% \ Include \ atl (example: C: \ Program Files \ Microsoft Platform SDK \ Include \ atl)
    • % WTL installation directory% \ Include (example: C: \ WTL80 \ include)
Installation, is done, ATL for an older version of the latest compiler, you may become an error.
Therefore, the following must not modify the files.
  • % Platform SDK installation directory% \ Include \ atl \ atlwin.h
  • % Platform SDK installation directory% \ Include \ atl \ atlbase.h
  • atlwin.h in 1725 to change the following line per
    1
    2
    3
    4
    5
    6
    7
    8
    
    	BOOL SetChainEntry(DWORD dwChainID, CMessageMap* pObject, DWORD
    	dwMsgMapID = 0)
    	{
    	    int i;
    	    // first search for an existing entry
     
     
    	    for(i = 0; i < m_aChainEntry.GetSize(); i++)

  • 287 atlbase.h of change around the following line
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    
    /* Comment it
    	PVOID __stdcall __AllocStdCallThunk(VOID);
    	VOID __stdcall __FreeStdCallThunk(PVOID);
     
    	#define AllocStdCallThunk() __AllocStdCallThunk()
    	#define FreeStdCallThunk(p) __FreeStdCallThunk(p)
     
    	#pragma comment(lib, "atlthunk.lib")
    	*/
    	#define AllocStdCallThunk() HeapAlloc(GetProcessHeap(), 0, sizeof(_stdcallthunk))
    	#define FreeStdCallThunk(p) HeapFree(GetProcessHeap(), 0, p)
See also: http://www.codeproject.com/KB/wtl/WTLExpress.aspx
Let's compile a sample
WTL has a standard with a simple example. We have compiled a sample of what is expected to get the right environment.


% WTL installation directory% \ Samples \ MTPad directory "MTPad.dsw" Let's start.
Old automatically Visla C + + I will then update to the latest project.

The end of the conversion, after it finished reading file, try to implement a build.
End compilation! ! Link fails! !
I hope you receive a message like the following.
And links ...
CVTRES: fatal error CVT1100: duplicate resource. Type: MANIFEST, name: 1, language: 0x0409.
LINK: fatal error LNK1123: COFF failure during conversion to: What file is invalid, or broken. .
BIRUDOROGU is "file: / / c: \ WTL80 \ Samples \ MTPad \ Debug \ BuildLog.htm" was saved. .

This is the way to an old set of resource files in Visual C + + 2008 can not become an error.
If you remove the following line, you can link.
MTPad.rc 43 lines
"CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST" "res \ \ \ \ MTPad.exe.manifest" "\ r \ n"
MTPad.rc 399 lines
CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "res \ \ MTPad.exe.manifest"
When you link, let's run.
When you see the following screen, OK.


WTL is a free development environment, you can build, you can use in commercial and more on licensing, LGPL also not allowed to force a description such as reverse engineering, may be used with confidence may.
But is the problem in the future. WTL is so, so not popular with the library developers will upgrade properly, our worries are what will. The minutes are not popular, few articles on the Web, the amount of information, MFC, compared to a lot less.
Salvation is the best, it can exist in all the source code on hand.

Based on the above, do mind that the library would certainly convenient.

Articles: ResEdit resource editor, and VC + + 2008 Exp. To be linked to


  • はてなブックマークへ追加する
  • Facebookでシェアする
  • twitter でつぶやく
  • Google Plusでシェアする
  • Pocketでシェアする
ページトップへ