作者ljuber (即戰力之豆花妹護衛隊)
看板Office
標題Re: [算表] 傳回資料的頁次??
時間Wed Sep 30 11:12:34 2009
※ 引述《ljuber (即戰力之豆花妹護衛隊)》之銘言:
: 軟體: excel
: 版本: 任何版本
: 我有一個excel檔案
: 分頁分了幾百頁
: 現在想在旁邊加一個欄位
: 顯示他這筆資料目前是位於第幾頁
: 例如:
: A B
: 姓名 頁次
: 1 王小明 1
: .
: .
: .
: 30 方大同 15
: .
: .
: .
: .
: .
: 100 張智成 20
: 不知道有什麼函數可以做到
: 因為每頁的欄位不盡相同
感謝W大的提醒
我去找到了這個網頁的作法:
http://www.excelhelp.net/cgi-bin/forum/topic.cgi?forum=4&topic=1001&show=0
============================
相關附件: (共 2065 位元組)
利用 GET.DOCUMENT(50) 及 GET.DOCUMENT(64)
抱歉我沒有中文板的 Excel 4 macro
Type 50
The total number of pages that would be printed based on current settings,
excluding notes, or 1 if the document is a chart.
定義名稱
TotalPage = GET.DOCUMENT(50)
Type 64
An array of row numbers corresponding to rows that are immediately below a
manual or automatic page break.
定義名稱
Pagenumber =
IF(ISERROR(MATCH(ROW(),GET.DOCUMENT(64),1)),1,MATCH(ROW(),GET.DOCUMENT(64),1)+1)
後來可以!!感謝
--
http://img195.imageshack.us/img195/2903/img5738m.jpg
豆起相思,其生南國,
花開堪折,莫待落蒂,
妹上心頭,如獲至寶。
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 210.65.186.253
→ windknife18:^^ 09/30 15:57