网站大量收购独家精品文档,联系QQ:2885784924

简易VC使用手册.PPT

  1. 1、本文档共15页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
简易VC使用手册

簡易 Visual Studio 2008 C++ 使用手冊 Han-Chern Ling 下載 Visual Studio 2008 中文版 成大的電腦資源 .tw/download 建立、編譯、執行 C 程式 兩種方式: 進入Visual Studio 2008後,先建立專案 在 DOS 視窗中執行 cl xxx.c 在Studio 2008 中建置新的 Project (專案) - 1 第一次執行 Studio 2008 時,程式會先要求選擇預設環境設定,點選『Visual C++ 開發設定』,再點選啟動Visual Studio。過一陣子,就會出現下圖之畫面。 在Studio 2008 中建置新的 Project (專案) - 2 在 Studio 2008 中必須先建立程式之 Project 後,才可進行後續的編譯程式與執行,故在此先進行建立 Project : 進入Visual C++ 2008 後 ? 檔案 ? 新增 ? 專案; 出現『新增專案視窗』後,選取『一般』『空專案』; 選取本project 存取位置後,在名稱處填入專案名稱; 按確定後,這就建好ㄧ個新的專案了。 在Studio 2008 中建置新的 Project (專案) - 3 接下來,就要建立新的 C 或 C++ 的程式碼(source code),或將已建好的 source code 加入專案中 : 建立新的 C 或 C++ 的程式碼 方案總管(滑鼠右鍵) ? 原始程式檔 ?加入 ? 新增項目; 出現『加入新項目』 ? 程式碼 ? C++檔 ? 加入名稱(如果是C的程式檔,請強制使用副檔名 .c,否則預設副檔名是 .cpp) ? 加入; 這時就可在新視窗鍵入你的程式碼。 在Studio 2008 中建置新的 Project (專案) - 4 在Studio 2008 中編譯及執行 Project (專案) - 5 程式碼完成後,就可建立執行檔了: 建置 ? 建置方案 (or Press F7) ? 希望編譯時沒有出現錯誤 偵錯 ? 啟動但不偵錯 (or Press ctrl+F5) ? 點選此處來執行程式 方法二:直接在 DOS 視窗下、下指令碼 \ cl source.c 簡易DOS操作指令 Oops! 錯誤產生時,該怎麼辦? Syntax Errors (語法錯誤) – When compiler can not recognize a statement If an error message appears in the Output pane’s Build tab, double-clicking anywhere on the error message displays the source file and places a blue arrow marker in the margin indicator bar (i.e., the gray strip to the left of the source code), indicating the offending line. If you do not understand the error message, highlight the error message number by dragging the mouse over the number, then press the F1 key. This displays a help file that provides information about the error and some helpful hints as to the cause of the error. Debugging Run-Time Logic Errors (語意錯誤) The Visual Studio provides a debugger tool to help the programmer find run-time logic errors in programs that compile and link successfully but do not produce expected results. The debugger lets the programmer view the executing program and its data as the program runs either one step at a time or at full speed. The program stops on a selected line of code or upon a fa

文档评论(0)

xiaozu + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档