• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            穩(wěn)定盈利的期貨交易方法-量化趨勢交易

            alantop -專業(yè)量化投資者

            愛好:量化投資,逆向工程,滲透
            隨筆 - 595, 文章 - 0, 評論 - 921, 引用 - 0
            數(shù)據(jù)加載中……

            Demonstrates Downloading Data Asynchronously(用ATL異步下載數(shù)據(jù)的演示)

            程序代碼: http://www.shnenglu.com/Files/alantop/async.rar

            This sample creates a control that downloads data asynchronously from a URL. The control implements the IBindStatusCallback interface. Typically, you asynchronously download large binary objects or properties. This allows the control's user interface to remain unblocked during potentially lengthy network operations. The use of asynchronous downloading also gives the user a chance to abort the download. ATL uses WinInet functions internally to implement asynchronous downloading.

            這個例子建立了一個控件從一個URL里異步下載數(shù)據(jù)。這個控件實現(xiàn)了IBindStatusCallback接口。有代表性的,你異步下載大的數(shù)據(jù)和道具。這將保持在整個網(wǎng)絡(luò)長時間的網(wǎng)絡(luò)操作中,用戶的接口保持不被封鎖。異步下載可以給用戶提供中斷的機會。ATL用內(nèi)建的WinInet函數(shù)實現(xiàn)異步下載。

            ASYNC creates a subclassed edit control with one property called URL. The URL property is a BSTR that represents a URL that points to data. The ASYNC sample uses the ATL CBindStatusCallback class to implement asynchronous downloading. When the control user sets the URL property, ASYNC creates a CBindStatusCallback object. The CBindStatusCallback::StartAsyncDownload method is then called and passed both the URL and a pointer to a callback function. This function, CAtlAsync::OnData, is called by the CBindStatusCallback object and is passed the binary data from the URL as it is received. CAtlAsync::OnData simply sends the received data to the subclassed edit control, where it is displayed.

            ASYNC建立一個子類化的edit控件,其有一個屬性關(guān)聯(lián)URL.URL屬性用BSTR代表。演示程序用CBindStatusCallback類實現(xiàn)異步下載。當控件用戶設(shè)置URL屬性,ASYNC建立一個CBindStatusCallback屬性。然后,CBindStatusCallback::StartAsyncDownload被調(diào)用,URL和一個指向回調(diào)函數(shù)的指針被傳遞給函數(shù)。CAtlAsync::OnDataCBindStatusCallback對象調(diào)用,并傳遞url接收到的二進制數(shù)據(jù)。CAtlAsync::OnData發(fā)送接收到的數(shù)據(jù)到被顯示的子類化控件中。

            Running the Sample

            Load the AtlAsync.htm file into your web browser. Type a URL into the edit control and press the Go button. This sets the ASYNC control's URL property to the URL you typed and starts the download. As data is downloaded, you will see it displayed in the ASYNC control.

            在瀏覽器中打開atlasync.htm文件。在edit控件鍵入網(wǎng)址,并選擇go.這將設(shè)置ASYNC控件的URL屬性并開始下載。當數(shù)據(jù)下載的時候,你可以看到它在async控件中顯示。

            For an example of how to subclass Windows controls using ATL, see the ATL SubEdit sample.

            怎樣用 ATL 子類化窗口控件,看 ATL subedit 例子。

            ?

            posted on 2006-05-30 23:42 AlanTop 閱讀(621) 評論(0)  編輯 收藏 引用 所屬分類: C++

            国产69精品久久久久777| 国内精品久久国产大陆| 久久精品国产99久久久| 亚洲欧美成人久久综合中文网| 国产精品久久午夜夜伦鲁鲁| 亚洲欧美日韩久久精品| 久久久99精品一区二区| 国产亚洲成人久久| 欧美成a人片免费看久久| 国产精品青草久久久久福利99| 99久久免费国产精品| 一级做a爰片久久毛片人呢| 一本久久a久久精品综合夜夜 | 久久国产精品99国产精| 国产精品久久久亚洲| 亚洲乱亚洲乱淫久久| 久久亚洲国产成人影院网站| 久久精品这里只有精99品| 久久综合亚洲色HEZYO社区| 亚洲国产精品无码久久久秋霞2| 久久久久av无码免费网| 久久国产精品77777| 久久久久久亚洲精品无码| 久久亚洲中文字幕精品一区| 国内精品久久国产| 久久99国产乱子伦精品免费| 精品久久人人做人人爽综合| 国产精品久久新婚兰兰| 久久国产一片免费观看| 久久99精品久久久久久久久久| 久久国产乱子伦精品免费午夜| 婷婷伊人久久大香线蕉AV| AAA级久久久精品无码区| 99久久99久久| 少妇久久久久久被弄高潮| 久久笫一福利免费导航| 久久久91人妻无码精品蜜桃HD| 国产精品久久精品| 久久综合精品国产二区无码| 狠狠色噜噜色狠狠狠综合久久| 久久成人精品视频|