亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? ch28.htm

?? Learning language of Visual C++6
?? HTM
?? 第 1 頁 / 共 3 頁
字號:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>

<HEAD>
<SCRIPT LANGUAGE="JavaScript">

<!--

function popUp(pPage) {
 var fullURL = document.location;
 var textURL = fullURL.toString();
 var URLlen = textURL.length;
 var lenMinusPage = textURL.lastIndexOf("/");
 lenMinusPage += 1;
 var fullPath = textURL.substring(0,lenMinusPage);
 popUpWin = window.open('','popWin','resizable=yes,scrollbars=no,width=525,height=394');
 figDoc= popUpWin.document;
 zhtm= '<HTML><HEAD><TITLE>' + pPage + '</TITLE>';
 zhtm += '<link rel="stylesheet" href="/includes/stylesheets/ebooks.css"></head>';
 zhtm += '<BODY bgcolor="#FFFFFF">';
 zhtm += '<IMG SRC="' + fullPath + pPage + '">';
 zhtm += '<P><B>' + pPage + '</B>';
 zhtm += '</BODY></HTML>';
 window.popUpWin.document.write(zhtm);
 window.popUpWin.document.close();
 // Johnny Jackson 4/28/98
 }

//-->
                                                                
</SCRIPT>
<link rel="stylesheet" href="/includes/stylesheets/ebooks.css">

	
	<TITLE>Special Edition Using Visual C++ 6 -- Ch 28 -- Future Explorations</TITLE>
</HEAD>

<BODY TEXT="#000000" BGCOLOR="#FFFFFF">

<CENTER>
<H1><IMG SRC="../button/que.gif" WIDTH="171" HEIGHT="66" ALIGN="BOTTOM" BORDER="0"><BR>
Special Edition Using Visual C++ 6</H1>
</CENTER>
<CENTER>
<P><A HREF="../ch27/ch27.htm"><IMG SRC="../button/previous.gif" WIDTH="128" HEIGHT="28"
ALIGN="BOTTOM" ALT="Previous chapter" BORDER="0"></A><A HREF="../apa/apa.htm"><IMG
SRC="../button/next.gif" WIDTH="128" HEIGHT="28" ALIGN="BOTTOM" ALT="Next chapter"
BORDER="0"></A><A HREF="../index.htm"><IMG SRC="../button/contents.gif" WIDTH="128"
HEIGHT="28" ALIGN="BOTTOM" ALT="Contents" BORDER="0"></A> 
<HR>

</CENTER>
<CENTER>
<H1>- 28 -</H1>
</CENTER>
<CENTER>
<H1>Future Explorations</H1>
</CENTER>

<UL>
	<LI><A HREF="#Heading1">Creating Console Applications</A>
	<UL>
		<LI><A HREF="#Heading2">Creating a Console Executable</A>
		<LI><A HREF="#Heading3">Writing an Object-Oriented Console Application</A>
		<LI><A HREF="#Heading4">Scaffolding Discrete Algorithms</A>
	</UL>
	<LI><A HREF="#Heading5">Creating and Using a 32-Bit Dynamic Link Library</A>
	<UL>
		<LI><A HREF="#Heading6">Making a 32-Bit DLL</A>
		<LI><A HREF="#Heading7">Using 32-Bit DLLs</A>
	</UL>
	<LI><A HREF="#Heading8">Sending Messages and Commands</A>
	<LI><A HREF="#Heading9">Considering International Software Development Issues</A>
</UL>

<P>
<HR SIZE="4">

<CENTER>
<H1></H1>
</CENTER>
<P>There are a number of topics that have not been covered elsewhere in this book,
but that are well known to experienced Visual C++ programmers. They are best explored
after you have experience with Developer Studio, MFC, and C++ programming. This chapter
has just enough to show you how interesting these topics are, and to encourage you
to explore them yourself in the months and years to come.</P>
<P>
<H2><A NAME="Heading1"></A>Creating Console Applications</H2>
<P>A console application looks very much like a DOS application, though it runs in
a resizable window. It has a strictly character-based interface with cursor keys
rather than mouse movement. You use the Console API and character-based I/O functions
such as printf() and scanf() to interact with the user.</P>
<P>
<H3><A NAME="Heading2"></A>Creating a Console Executable</H3>
<P>A console application is executed from the DOS command line or by choosing Start,
Run and typing the full name (including the path) of the application. Console applications
are probably still among the easiest programs to create, and this version of the
compiler supports them directly.</P>
<P>Let's walk together through the few steps necessary to create a basic console
application, and then we'll explore some beneficial uses of creating these applications.
The first console application we'll create is a spin on the classic &quot;Hello,
World!&quot; that Kernighan and Ritchie (the creators of C++'s ancestor C) created
in the 1970s.</P>
<P>Open the Microsoft Developer Studio and follow these steps to create a console
application:</P>

<DL>
	<DT></DT>
	<DD><B>1. </B>In the Microsoft Developer Studio, select File, New.
	<P>
	<DT></DT>
	<DD><B>2. </B>In the New dialog box, click the Projects tab to bring up the now familiar
	New project dialog box. (If it isn't familiar, go back to Chapter 1, &quot;Building
	Your First Windows Application.&quot;)
	<P>
	<DT></DT>
	<DD><B>3.</B> Name the project HelloWorld, set an appropriate folder for the project,
	and choose Win32 Console Application from the list on the left.
	<P>
	<DT></DT>
	<DD><B>4. </B>Click OK.
	<P>
	<DT></DT>
	<DD><B>5. </B>AppWizard asks whether you want to create An Empty Project, A Simple
	Application, A &quot;Hello World&quot; Application, or An Application that uses MFC.
	Select An Empty Project so that you can create our slightly simpler HelloWorld by
	yourself.
	<P>
	<DT></DT>
	<DD><B>6. </B>Click Finish.
	<P>
</DL>

<P>The project is created immediately but has no file added to it. You create source
and header files and add them to the project. This sample will all fit in one file.
Follow these steps:</P>

<DL>
	<DT></DT>
	<DD><B>1. </B>Select File, New from the File menu and click the File tab.
	<P>
	<DT></DT>
	<DD><B>2. </B>Leave the Add to Project box selected; the new file will be added to
	the project.
	<P>
	<DT></DT>
	<DD><B>3. </B>Choose C++ Source File from the box on the left.
	<P>
	<DT></DT>
	<DD><B>4. </B>Enter <B>HelloWorld</B> as the filename--the extension .cpp will be
	added automatically.
	<P>
	<DT></DT>
	<DD><B>5. </B>The New dialog box should resemble Figure 28.1. Click OK.
	<P>
</DL>

<P><A HREF="javascript:popUp('28fig01.gif')"><B>FIG. 28.1</B></A><B> </B><I>Create
a C++ source file for your console application.</I></P>
<P>A blank text file is created and named for you and added to the project, all in
one step. Add the code in Listing 28.1 to the new file.</P>
<P>
<H4>Listing 28.1&#160;&#160;HelloWorld.cpp</H4>
<PRE>#include &lt;iostream.h&gt;
int main()
{
     cout &lt;&lt; &quot;Hello from the console!&quot;&lt;&lt; endl;
     return 0;
</PRE>
<PRE>}
</PRE>
<P>Choose Build, Execute to compile, link, and execute the program. (A dialog will
ask you to confirm that you want to build the project before executing.) You should
see a DOS box appear that resembles Figure 28.2. The line Press any key to continue
is generated by the system and gives you a chance to read your output before the
DOS box disappears.</P>
<P>
<H3><A NAME="Heading3"></A>Writing an Object-Oriented Console Application</H3>
<P>The HelloWorld application is clearly C++ and would not compile in a C compiler,
which doesn't support stream-based I/O with cout, but it's not object oriented--there's
not an object in it. Replace the code in HelloWorld.cpp with the lines in Listing
28.2.</P>
<P><A HREF="javascript:popUp('28fig02.gif')"><B>FIG. 28.2</B></A><B> </B><I>Your
application appears to be a DOS program.</I></P>
<P>
<H4>Listing 28.2&#160;&#160;HelloWorld.cpp--With Objects</H4>
<PRE>// HelloWorld.cpp
//
#include &lt;iostream.h&gt;
#include &lt;afx.h&gt;
class Hello
{
private:
     CString message;
public:
     Hello();
     void display();
};
Hello::Hello()
{
     message = &quot;Hello from the console!&quot;;
}
void Hello::display()
{
     cout &lt;&lt; message &lt;&lt; endl;
}
int main()
{
     Hello hello;
     hello.display();
     return 0;
</PRE>
<PRE>}
</PRE>
<P>Now this is an object-oriented program, and what's more, it uses CString, an MFC
class. To do so, it must include &lt;afx.h&gt;. If you build the project now, you
will get linker error messages that refer to _beginthreadex and _endthreadex. By
default, console applications are single-threaded, but MFC is multithreaded. By including
afx.h and bringing in MFC, this application is making itself incompatible with the
single-threaded default. To fix this, choose Project Settings and click the C/C++
tab. From the drop-down box at the top of the dialog box, choose Code Generation.
In the drop-down list box labeled Use Run-Time Library, choose Debug Multithreaded.
(The completed dialog box is shown in Figure 28.3.) Click OK and rebuild the project.</P>
<P><A HREF="javascript:popUp('28fig03.gif')"><B>FIG. 28.3</B></A><B> </B><I>Make
your console application multithreaded so that it can use MFC.</I></P>
<P>The output of this object-oriented program is just like that of the preceding
program--this is just a sample. But you see that console applications can use MFC,
be built around objects, and be quite small. They must have a main() function, and
it is this function that is called by the operating system when you run the application.</P>


<BLOCKQUOTE>
	<P>
<HR>
<STRONG>NOTE:</STRONG> Although this application is small, Visual C++ creates a lot
	of overhead files. The Debug directory occupies about 7.8MB, of which about 1.3MB
	is HelloWorld.exe. The rest is the MFC libraries--they aren't small.&#160; 
<HR>


</BLOCKQUOTE>

<H3><A NAME="Heading4"></A>Scaffolding Discrete Algorithms</H3>
<P>One important reason to build a console application these days is to <I>scaffold</I>
small code fragments or single objects. This refers to building a temporary framework
around the code you want to test. (Some developers call this a <I>test harness</I>.)
The simplest possible framework is a console application like the one you just built:
In fact, you'll build a scaffold later in this chapter.</P>
<P>To scaffold an object or function, you should do the following:</P>

<DL>
	<DT></DT>
	<DD><B>1. </B>Create a new console application just for the scaffolding process.
	<P>
	<DT></DT>
	<DD><B>2. </B>Add a main() function to the .CPP file you plan to scaffold.
	<P>
	<DT></DT>
	<DD><B>3. </B>Include the header file for the object or function to be tested.
	<P>
	<DT></DT>
	<DD><B>4. </B>Add code to main() that exercises the function or object in a variety
	of test cases.
	<P>
</DL>

<P>Having followed those steps, you can now test the code thoroughly, focusing only
on the performance characteristics and correctness of this small piece of your large
project. Scaffolding holds true to the canon of software development that states,
&quot;Design in the large and program in the small.&quot;</P>
<P>By applying a scaffold to any algorithm, you are helping to ensure the accuracy
in the small. Remember there are additional benefits involved, too: By placing the
scaffold code directly into the module, you are clearly documenting that the code
has been tested and how to use it. You make it available for further testing, debugging,
or extending at a later date.</P>
<P>
<H2><A NAME="Heading5"></A>Creating and Using a 32-Bit Dynamic Link Library</H2>
<P>Dynamic link libraries (DLLs) are the backbone of the Windows 95 and Windows NT
operating systems. Windows 95 uses Kernel32.dll, User32.dll, and Gdi32.dll to perform
the vast majority of its work, and you can use them as well. The Visual C++ online

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美日韩国产影片| 91亚洲国产成人精品一区二区三| 91精品国产91久久久久久一区二区 | 中文字幕一区二区三区精华液 | 国产一区不卡视频| 精品国产伦理网| 国产一区在线精品| 国产欧美日韩亚州综合| 丁香婷婷综合网| 最新久久zyz资源站| 99国内精品久久| 亚洲国产日韩av| 欧美xfplay| av电影在线观看完整版一区二区| 日韩制服丝袜先锋影音| 777xxx欧美| 国产不卡视频在线观看| 成人欧美一区二区三区黑人麻豆| 91天堂素人约啪| 亚洲国产精品一区二区尤物区| 91精品国产综合久久婷婷香蕉 | 国内精品久久久久影院一蜜桃| 久久午夜免费电影| 91丨porny丨国产入口| 亚洲国产精品久久久久婷婷884| 日韩欧美一级精品久久| 成人99免费视频| 视频在线观看一区二区三区| 国产欧美日韩视频一区二区| 欧美亚洲国产bt| 国产一区二区三区免费看 | 亚洲在线一区二区三区| 日韩午夜激情av| 91天堂素人约啪| 精品一区二区三区在线播放视频| 国产精品高潮呻吟| 日韩久久精品一区| 91原创在线视频| 国产一区二区伦理| 亚洲成人在线免费| 国产精品久久久99| 久久蜜桃av一区二区天堂| 欧美亚洲国产bt| 99精品热视频| 国产一区欧美日韩| 日本伊人午夜精品| 一区二区国产视频| 久久精品视频在线看| 91麻豆精品国产自产在线| 99久久国产综合精品麻豆| 美女看a上一区| 亚洲色图制服诱惑| 国产精品午夜久久| 2021久久国产精品不只是精品| 欧美专区日韩专区| 91丨九色丨国产丨porny| 国模一区二区三区白浆| 天涯成人国产亚洲精品一区av| 亚洲欧美影音先锋| 国产喷白浆一区二区三区| 日韩色视频在线观看| 欧美日韩久久久| 在线观看中文字幕不卡| 91首页免费视频| 92精品国产成人观看免费| 国产福利精品导航| 极品美女销魂一区二区三区| 日本不卡一区二区三区高清视频| 亚洲黄色尤物视频| 亚洲精品写真福利| 亚洲美女区一区| 亚洲图片另类小说| 亚洲免费毛片网站| 亚洲美女免费在线| 亚洲一区在线观看视频| 亚洲美女精品一区| 亚洲永久精品大片| 亚洲一二三区在线观看| 亚洲成人av一区二区三区| 成人h动漫精品| 成人精品一区二区三区四区 | 福利91精品一区二区三区| 国产福利一区在线| 成人免费福利片| 97se亚洲国产综合自在线观| 91麻豆精品视频| 在线观看日韩av先锋影音电影院| 色欧美乱欧美15图片| 欧美影视一区二区三区| 欧美人与禽zozo性伦| 日韩欧美www| 久久精品日产第一区二区三区高清版 | 久久www免费人成看片高清| 久久精品99国产精品日本| 捆绑变态av一区二区三区| 久久99在线观看| 国产精品自在欧美一区| 顶级嫩模精品视频在线看| caoporn国产一区二区| 色婷婷国产精品综合在线观看| 欧美综合视频在线观看| 欧美一区二区三区喷汁尤物| www国产亚洲精品久久麻豆| 国产精品色一区二区三区| 亚洲欧洲日本在线| 亚洲成人黄色影院| 国产在线精品免费av| 不卡一区二区三区四区| 欧美在线一区二区三区| 欧美一级理论片| 国产精品久久久爽爽爽麻豆色哟哟 | 久久久五月婷婷| 亚洲美女免费视频| 久久99国产精品免费| 成人av网址在线| 欧美一级高清大全免费观看| 国产精品美女久久福利网站| 亚洲国产精品精华液网站| 国产精品影音先锋| 欧美日韩在线播放三区四区| 久久久午夜电影| 亚洲无线码一区二区三区| 国产一区三区三区| 欧美日韩精品一区二区三区| 国产日韩欧美不卡在线| 亚洲一区二区三区影院| 国产成人精品亚洲777人妖| 欧美网站大全在线观看| 国产婷婷色一区二区三区| 亚洲影院免费观看| 成人免费视频一区| 日韩写真欧美这视频| 悠悠色在线精品| 风间由美一区二区三区在线观看 | 亚洲综合一区二区三区| 国产一区91精品张津瑜| 欧美日韩mp4| 亚洲人成在线播放网站岛国| 国产精品亚洲午夜一区二区三区 | 91精品国产美女浴室洗澡无遮挡| 中文字幕亚洲一区二区va在线| 狠狠色伊人亚洲综合成人| 欧美性大战久久久久久久| 国产欧美va欧美不卡在线| 麻豆一区二区99久久久久| 欧美日韩午夜在线视频| 亚洲女同女同女同女同女同69| 国产乱码字幕精品高清av| 欧美一区二区大片| 亚洲午夜免费视频| 色琪琪一区二区三区亚洲区| 国产精品视频观看| 国产乱子伦一区二区三区国色天香| 欧美日韩另类国产亚洲欧美一级| 亚洲欧美经典视频| 99视频精品在线| 国产精品久久久久桃色tv| 国产曰批免费观看久久久| 日韩亚洲欧美在线观看| 日本午夜精品一区二区三区电影| 色综合天天天天做夜夜夜夜做| 国产精品麻豆视频| 成人激情免费视频| 国产视频一区在线观看| 久久国产欧美日韩精品| 日韩精品一区二区三区老鸭窝| 午夜精品福利视频网站| 精品视频一区三区九区| 亚洲国产中文字幕| 欧美日韩你懂得| 午夜亚洲福利老司机| 8x8x8国产精品| 蜜臀精品久久久久久蜜臀| 欧美一区二区女人| 蜜臀a∨国产成人精品| 欧美变态凌虐bdsm| 国产在线精品一区二区三区不卡| 亚洲精品一区二区三区四区高清| 激情国产一区二区 | 日韩欧美一区电影| 激情综合网最新| 久久久国际精品| 国产成人在线影院| 国产精品三级在线观看| 91视视频在线直接观看在线看网页在线看| 国产精品丝袜久久久久久app| 99久久99久久免费精品蜜臀| 国产精品高清亚洲| 欧洲精品视频在线观看| 日韩av电影一区| 久久久久免费观看| 99在线热播精品免费| 亚洲成av人片在线观看| 精品日韩99亚洲| 成人深夜福利app| 五月激情综合网| 久久久久久久久一| 91免费精品国自产拍在线不卡| 亚洲综合激情小说| 日韩视频中午一区|