全國最多中醫師線上諮詢網站-台灣中醫網
發文 回覆 瀏覽次數:1291
推到 Plurk!
推到 Facebook!

如何大量變更Project version

尚未結案
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#1 引用回覆 回覆 發表時間:2004-06-14 11:15:01 IP:61.220.xxx.xxx 未訂閱
我有個Project Group 在這個Project Group裡面有很多的Project. 但是要更改版本資訊的時候每次都覺得很麻煩, 要一個一個的輸入特定的版本資訊. 嘗試著直接去修改過 dof 檔, 但是修改後Build的執行檔也不是該版本, 不知道各位是怎麼樣去解決這個問題的.
william
版主


發表:66
回覆:2535
積分:3048
註冊:2002-07-11

發送簡訊給我
#2 引用回覆 回覆 發表時間:2004-06-14 11:35:50 IP:147.8.xxx.xxx 未訂閱
Delete the .res file, edit the .dof file. Re-open the project and let Delphi recreate the .res file 
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#3 引用回覆 回覆 發表時間:2004-06-14 13:24:17 IP:61.220.xxx.xxx 未訂閱
我試過了, 版本資訊改不了, 不知道是什麼原因
william
版主


發表:66
回覆:2535
積分:3048
註冊:2002-07-11

發送簡訊給我
#4 引用回覆 回覆 發表時間:2004-06-14 14:31:24 IP:147.8.xxx.xxx 未訂閱
Did you do a bulid instead of compile project?
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#5 引用回覆 回覆 發表時間:2004-06-14 14:47:21 IP:61.220.xxx.xxx 未訂閱
引言: Did you do a bulid instead of compile project?
我試過了, 我重寫一次我的步驟, 請您看看對不對 1. Delete *.res 2. Edit *.dof 's FileVersion 3. Open Delphi 4. Open Project (Rebuild .res file) 5. Build Project 6. Check file version Rebuild的結果是 AP 的 ICON 不見了, 可是版本資訊也沒更新.
william
版主


發表:66
回覆:2535
積分:3048
註冊:2002-07-11

發送簡訊給我
#6 引用回覆 回覆 發表時間:2004-06-14 15:01:22 IP:147.8.xxx.xxx 未訂閱
Your procedure looks alright... Any additional resource files in the project? e.g. search for $R
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#7 引用回覆 回覆 發表時間:2004-06-14 15:25:54 IP:61.220.xxx.xxx 未訂閱
引言: Your procedure looks alright... Any additional resource files in the project? e.g. search for $R
需要額外再增加什麼進來呢? 發表人 - alex0628 於 2004/06/14 15:29:33
william
版主


發表:66
回覆:2535
積分:3048
註冊:2002-07-11

發送簡訊給我
#8 引用回覆 回覆 發表時間:2004-06-14 15:57:10 IP:147.8.xxx.xxx 未訂閱
Check for other linked resource files (via $R in source) if there is any definition for the version info. FYI for Delphi 2, this is the only way to include version info.
speedup
資深會員


發表:19
回覆:259
積分:280
註冊:2003-07-04

發送簡訊給我
#9 引用回覆 回覆 發表時間:2004-06-14 16:38:20 IP:61.224.xxx.xxx 未訂閱
引言:
引言: Did you do a bulid instead of compile project?
我試過了, 我重寫一次我的步驟, 請您看看對不對 1. Delete *.res 2. Edit *.dof 's FileVersion 3. Open Delphi 4. Open Project (Rebuild .res file) 5. Build Project 6. Check file version Rebuild的結果是 AP 的 ICON 不見了, 可是版本資訊也沒更新.
try to delete *.dcu 混心雜欲 棄修身~唉
------
唉~
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#10 引用回覆 回覆 發表時間:2004-06-14 16:58:08 IP:61.220.xxx.xxx 未訂閱
引言: try to delete *.dcu
我試過可以了, 但是整個程式的ICON變成Default了, 這個有辦法解決嗎?
Chance36
版主


發表:31
回覆:1033
積分:792
註冊:2002-12-31

發送簡訊給我
#11 引用回覆 回覆 發表時間:2004-06-14 22:34:23 IP:211.20.xxx.xxx 未訂閱
alex0628 你好    1.針對每個dpr開啟[Projects]->[Options]->切到[Version Info] 將[Include Version Information]及[auot-IncrementBuild Number]打勾 2.開啟project Group 然後用Build All Projects 不是用Compile All projects 3.或個別的dpr則用Build Project 發表人 - chance36 於 2004/06/14 22:37:24
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#12 引用回覆 回覆 發表時間:2004-06-14 23:05:19 IP:220.138.xxx.xxx 未訂閱
引言: 1.針對每個dpr開啟[Projects]->[Options]->切到[Version Info] 將[Include Version Information]及[auot-IncrementBuild Number]打勾 2.開啟project Group 然後用Build All Projects 不是用Compile All projects 3.或個別的dpr則用Build Project 發表人 - chance36 於 2004/06/14 22:37:24
我現在的Version Information是用日期來做Build Number, 因為常常需要Build Project, 所以每一次一個一個開dpr來改Version都需要花很多的時間, 所以想說用UltraEdit直接Replace dof 檔裡面的Version, 現在已經都可以Work了, 但是存在的一個問題是專案的ICON會變回Delphi的預設ICON, 所以現在還不知道怎麼解決.
william
版主


發表:66
回覆:2535
積分:3048
註冊:2002-07-11

發送簡訊給我
#13 引用回覆 回覆 發表時間:2004-06-15 10:31:15 IP:147.8.xxx.xxx 未訂閱
Then I would suggest you set version info the hard way...    1) do NOT include version info in your project 2) create a TEXT resource script (e.g. ver.rc) 3) compile ver.rc using brcc32 into ver.res 4) link ver.res to your project using {$R ver.res}    Here is a sample .rc created using Borland Resource Workshop (you can find it on Delphi 7 CD):    
/****************************************************************************    ver.rc    produced by Borland Resource Workshop    *****************************************************************************/    #define VERSIONINFO_1        1
1 VERSIONINFO 
FILEVERSION 1, 0, 0, 0
PRODUCTVERSION 1, 0, 0, 0
FILEOS VOS_DOS_WINDOWS16
FILETYPE VFT_APP
{
 BLOCK "StringFileInfo"
 {
  BLOCK "040904E4"
  {
   VALUE "CompanyName", "My Company\000\000"
   VALUE "FileDescription", "Description from .def file here\000"
   VALUE "FileVersion", "1.00\000\000"
   VALUE "InternalName", "Application name\000"
   VALUE "LegalCopyright", "Copyright © My Company 1993\000\000"
   VALUE "OriginalFilename", ".exe file name here\000"
  }     }     BLOCK "VarFileInfo"
 {
  VALUE "Translation", 0x409, 1252
 }    }
alex0628
一般會員


發表:13
回覆:24
積分:7
註冊:2002-04-15

發送簡訊給我
#14 引用回覆 回覆 發表時間:2004-06-15 11:12:54 IP:61.220.xxx.xxx 未訂閱
謝謝您, 可以了 這樣爾後只需要Replace FILEVERSION 然後下個batch command 將所有的 rc 檔變成 res 檔, 然後再 Build All Project 就搞定了
系統時間:2024-05-15 19:52:07
聯絡我們 | Delphi K.Top討論版
本站聲明
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。
2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。
3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇!