[CS6][JS][Win]Append page number of citation
Hi guys,
I hope you can help me with this one, I have a Bibliography page structured like this:
DARWIN Charles Erasmus 7529 (1759–1799) Lorem ipsum dolor sit amet,
consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore
et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud
exercitation ullamco laboris nisi ut aliquip ex ea commodo.
Then I need to search for the body of the book for pages where Darwin were cited then append it to the end of the paragraph which will look like this:
DARWIN Charles Erasmus 7529 (1759–1799) Lorem ipsum dolor sit amet,
consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore
et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud
exercitation ullamco laboris nisi ut aliquip ex ea commodo. [23 35 102 204]
Please take note that the citation on the body of the book may come in different format like, CE Darwin, C.E. Darwin, or Darwin, CE.
I would really appreciate your help.
-CharlesD
Charles, I had some time during lunch. Find attached a new version. The GREP searches now for pairs. The GREP string can be written certainly shorter, but in this case it is more readable.
So the GREP will find in the first loop C.E. Darwin, C. E. Darwin, CE Darwin or Darwin, C.E. , Darwin, C. E. and Darwin CE and save the corresponding page. Then it will search for 'DARWIN Charles Erasmus' with a applied paragraph style 'myPStyle' and will insert the page names at the end of the paragraph. If the pargraph had alreday something in brackets, this content will be deleted. So you can run the script multiple times.
In the second loop it will find RL Darwin > DARWIN Roqueza Lopena and so on. You can add addtional names or change the GREP expression which determines what is to be found.
Because I am only an advanced beginner in Javascript this could maybe be done easier, but this is my way for today .
main ();
function main() {
var curDoc = app.activeDocument;
var allPages = curDoc.pages;
// [ GREP-Querie, special paragraph ]
var searchList = [
[ "(?i)((C\\. ?E\\.|CE) Darwin)|(Darwin, (C\\. ?E\\.|CE))", "DARWIN Charles Erasmus" ],
[ "(?i)((R\\. ?L\\.|RL) Darwin)|(Darwin, (R\\. ?L\\.|RL))", "DARWIN Roqueza Lopena" ],
[ "(?i)((C\\. ?R\\.|CR) Darwin)|(Darwin, (C\\. ?R\\.|CR))", "DARWIN Charles Robert" ],
// loop through the searchList
for ( var s = 0; s < searchList.length; s++ ) {
app.findGrepPreferences = null;
app.findGrepPreferences.findWhat = searchList[s][0];
var pNumbers = new Array();
// loop through all pages
for ( var p = 0; p < allPages.length; p++ ) {
var curPage = allPages[p];
var tfs = curPage.textFrames;
// loop through all textframes on the current page
for ( var t = 0; t < tfs.length; t++ ) {
var tf = tfs[t];
if ( tf.contents != "" ) {
var res = tf.findGrep();
if ( res.length > 0 ) {
pNumbers.push( curPage.name );
break;
} // if
} // if
} // tfs
} // allPages
var pageString = pNumbers.join( " " );
alert ( searchList[s][1] + ": " + pageString );
app.findGrepPreferences = null;
app.findGrepPreferences.findWhat= searchList[s][1];
app.findGrepPreferences.appliedParagraphStyle = curDoc.paragraphStyles.itemByName( "myPStyle" );
var result = curDoc.findGrep();
var para = result[0].paragraphs[0];
// if the paragraph has already content in '[…]' this content will be deleted
if ( para.characters[-2].contents == "]" ) {
app.findGrepPreferences = null;
app.findGrepPreferences.findWhat = " +\\[[^\\]]+\\]";
app.changeGrepPreferences.changeTo = "";
para.changeGrep();
para.insertionPoints[-2].contents = " [" + pageString + "]";
} // searchList
} // main
Similar Messages
-
CS6 - how to get page number?
i have selected frame. I want to know page number, where it is.
aSel = app.selection[0];
alert (aSel.parent.name); - i get empty string
cause it' Object spread. And what to do then? (without losing of right/left reffering)
thanks
p.s. in CS3 i did it, and in CS6 i get stuck.@Dmitry – for further reference see also:
http://www.indiscripts.com/post/2012/06/so-what-s-new-in-indesign-cs6-scripting-dom
http://www.indiscripts.com/post/2011/04/so-what-s-new-in-indesign-cs5-5-scripting-dom
http://www.indiscripts.com/post/2010/10/so-what-s-new-in-indesign-cs5-scripting-dom
For the whole documentation of the DOM:
http://www.jongware.com/idjshelp.html
Hm. While we are at it:
Is there a "What's new in InDesign CS4 scripting DOM" somewhere?
Just to complete the picture…
Uwe -
Is there any way to link page number with the reference page number within text in InDesign CC and CS6?
You should ask in InDesign
The Cloud forum is not about using individual programs
The Cloud forum is about the Cloud as a delivery & install process
If you will start at the Forums Index https://forums.adobe.com/welcome
You will be able to select a forum for the specific Adobe product(s) you use
Click the "down arrow" symbol on the right (where it says All communities) to open the drop down list and scroll -
I have Adobe Design Standard CS6 purchased 2013 with serial number but cannot find to download it onto a new mac laptop. When I try and add the 24-digit serial number to my account it doesn't seem to work?
CS6 - http://helpx.adobe.com/x-productkb/policy-pricing/cs6-product-downloads.html
You can also download the trial version of the software thru the page linked below and then use your current serial number to activate it.
Be sure to follow the steps outlined in the Note: Very Important Instructions section on the download pages at this site and have cookies enabled in your browser or else the download will not work properly.
CS6: http://prodesigntools.com/adobe-cs6-direct-download-links.html -
Why wont my .vst plugins work in cs6 on win 7 pro 64 bit
why wont my .vst plugins work on my new os ,win 7 pro 64 bit, i have cs6 and cc installed, they worked fine when it was on xp pro.. even if it finds them and you can bring them up it crashes cs6, any advice is helpful, thanks!!
awb5151 wrote:
But i really want them to work in cs6, i heard you have to use j bridge to use .vst's in cc, is this true..
Yes.
I just dont understand why they wont work in win 7 pro 64 bit , is it an os problem or is it a cs6 problem, when i had cs6 in win xp pro, was it installed as a 32 bit program, if thats the case can i load a 32 bit version of cs6>>>??? thanks!!
It's not the OS - W764Pro can run 32-bit software fine in emulation. Your problem is that there is no 32-bit version of CC. It was widely circulated before release that this was going to be 64-bit only, and that you would need bridging software to run old 32-bit VST plugins.
Apparently, jbridge works fine once you've got it installed and everything in the correct place. I wouldn't know though, because I don't use it - I only use a small number of 64-bit plugins directly. On those few occasions that I want to use a 32-bit plugin, I run it in CS6 Audition (which isn't the CC version, but is 32-bit). So yes, if you have the 32-bit program you can run them in that. Both versions of the software will co-exist quite happily on the same machine, and won't interact at all - except that you have to be careful with your sound device settings. -
How to get the page number when click the(Next page) Icon on Tableview
Hi all,
I had implemented a tableview in one of the Views that I had implemented for a BSP application. I am using MVC framework.
Let us assume when we execute the BSP and a table view got 11 pages.
How I can keep track of the page number when we click the (Next page, Previous page, Bottom , Top) Icons on my tableview . Is there any attribute willstore that corresponding page number of the tableview when we click the corresponding Icon's??
I had checked both CL_HTMLB_TABLEVIEW and CL_HTMLB_EVENT_TABLEVIEW Classes and i don't find any attribute.
Any help will be appreciated.
Thanks in advance.
Thanks,
GreetsonHi Greetson,
I was thinking to write a weblog about that.
But now I would like to have your opinion:
I coded a generic method in my main controller (but you could also insert it in the application class) that save the firstvisible row in the class me->firstvisiblerowlist (that is a table)
DATA: l_firstvisiblerowlist TYPE zmmsp_tableview_1st_visi_row.
DATA: ff TYPE ihttpnvp,
ffs TYPE tihttpnvp.
me->request->get_form_fields( CHANGING fields = ffs ).
LOOP AT ffs INTO ff.
IF ff-name CP 'f*visiblefirstrow'.
READ TABLE me->firstvisiblerowlist INTO l_firstvisiblerowlist WITH KEY name = ff-name.
CASE sy-subrc.
WHEN 0.
l_firstvisiblerowlist-name = ff-name.
l_firstvisiblerowlist-value = ff-value.
MODIFY me->firstvisiblerowlist FROM l_firstvisiblerowlist INDEX sy-tabix.
WHEN 4.
IF sy-tabix = 0.
l_firstvisiblerowlist-name = ff-name.
l_firstvisiblerowlist-value = ff-value.
APPEND l_firstvisiblerowlist TO me->firstvisiblerowlist.
ELSE.
l_firstvisiblerowlist-name = ff-name.
l_firstvisiblerowlist-value = ff-value.
INSERT l_firstvisiblerowlist INTO me->firstvisiblerowlist INDEX sy-tabix.
ENDIF.
WHEN 8.
l_firstvisiblerowlist-name = ff-name.
l_firstvisiblerowlist-value = ff-value.
APPEND l_firstvisiblerowlist TO me->firstvisiblerowlist.
ENDCASE.
ENDIF.
ENDLOOP.
Than you have to provide a generic method to read the firstvisiblerow for each tableview
GET_FIRSTVISIBLEROW
*IM_TABLENAME
*RE_VALUE
DATA: l_firstvisiblerow TYPE zmmsp_tableview_1st_visi_row.
READ TABLE me->firstvisiblerowlist INTO l_firstvisiblerow WITH KEY name = im_tablename.
IF sy-subrc = 0.
re_value = l_firstvisiblerow-value.
ELSE.
re_value = 1.
ENDIF.
And in the DO_REQUSET of each controller you could write something like:
* Paginator
DATA: l_tab1_visiblefirstrow TYPE sytabix.
l_tab1_visiblefirstrow = o_bsp_main->get_firstvisiblerow( 'f019id_tab1_visiblefirstrow' ).
As usual pass the value to the view via:
o_page->set_attribute( name = 'tab1visiblefirstrow' value = l_tab1_visiblefirstrow ).
Did you get it? -
Accessing page number property [CS3] [JS]
I am trying to find a way to access page numbers from a JavaScript program. Pages can always be accessed by their number (e.g., currentDocument.pages.item(0) references the first page). I have several documents (not gathered as a book) that have their page numbers set to start at different numbers. For instance, one document begins its page numbering at 100. That page 100 is still accessed by currentDocument.pages.item(0), since it is still the first page of the document.
My question is this: is there a way for the script to determine what the actual page number is for any given page? I need this number to insert as an attribute for an XML element that will mark the beginning of new pages in the print version so that citations can be created from the digital version. It seems like it should be something simple like myPage.pageNumber, but I haven't been able to find a property like this in any of the scripting references or any discussion of this issue in the forums.
There has to be an obvious answer, but somehow it is eluding me.
KevinThank you. I knew it had to be obvious. I saw the name property, but since it returned a string I didn't think that was it. The script is now doing exactly what I wanted.
Kevin -
Preview.app and multipage tiff files (page number)
I scan completed job folders at my company and store the resulting files on a server for users to access. They are a multipage .tif format which is basically a fax file format that is very common among document scanners.
Preview is pretty good at viewing these except I am stuck with two problems.
- 10.4 Preview will only show the first 250 pages of a file.
- 10.5 Preview will show many more pages which is good, but it gives NO WAY to know what image number you are looking at!! (preview 10.4 shows image numbers under the thumbnails, but the 10.5 version for some mysterious reason does not).
So if you are looking at an image near the middle of a 500 page document, you have no idea what image number it is, and you basically have to click the little arrow on the print box until you get to that page (which can be hard to tell because you are looking at a small thumbnail of the page). It's completely unusable.
Now before you tell me "yes it does show the page numbers in the thumbnail view!!!" let me remind you that I am not viewing PDFs. Yes, for PDF files the page number is right there all nice and handy. But for these multipage tif files, no page number for you!!!
Hah, update! I have just discovered that with very short file names, you can see the image number, because Preview 10.5 appends the image number to the end of the file name on each thumbnail.
So you can see: myFile.tif-389 on page 389's thumbnail.
But if your filename is much longer, you see: myLongerFile... with no way to see the image number.
I don't even know where to complain about this. Any ideas welcome.Paul Bruneau wrote:
I scan completed job folders at my company and store the resulting files on a server for users to access. They are a multipage .tif format which is basically a fax file format that is very common among document scanners... Any ideas welcome.
Multipage TIF is not common at all. Why not just save these files as PDF? Any modern scanner software should be about to generate PDF files. They won't be any larger than the TIF files and will be readable in anything with all available features.
I don't have any multipage tif files and don't even know how I could generate one. You can send your request to Apple via their Feedback page. But there is really no downside and numerous benefits to saving as PDF instead. -
Dynamically use page number in form field on spawned pages?
I have a form with spawned pages. JS for spawning page(s) works fine. However, one text field on template is driving me nuts. I would like this field ("CaseNum") to dynamically display page number, since page number also corresponds to case number. On templage ("getcase"), I can calculate value for CaseNum using custom calc script (event.value = this.PageNum). But that doesn't work because every spawned page gets the same value (ie, whatever is last spawned page number). I also tried JS below, using P0.getcase.CaseNum as the field on the template in which I want the page number/case number to be displayed:
var oPage = this.pageNum;
this.getField("P" + oPage + ".getcase" + ".CaseNum").value = oPage;
But, this doesn't work either, because the field on the spawned page automatically gets the prefix of P + page number + .getcase appended to the field name. Is there any way to dynamically used page number in a form field on spawned pages? If so, how? Note that while I am trying to use a dynamic case number on spawned pages, it presents the same issue as dynamically displaying page numbers on spawned pages. I'm a JS newbie, so any help appreciated. I've searched high and low on web and in forums and couldn't find the answer. Thx.http://forums.adobe.com/thread/1160899
7.George Johnson,
28-Feb-2013 09:42 in reply to natelfo
Is this what you mean?
Also see:
http://www.planetpdf.com/developer/article.asp?ContentID=6466
http://www.wordwizardsinc.com/blog/finding-the-fieldname-prefix-on-acrobat-acroform-spawne d-template-pages-using-javascript-functions/ -
Hi frnds,
I want to display page numbers as x/y,
x->current page number of list report
y->total pagenumber of list report
in header part of list report, this value has to be printed in each page of the list report.i can calculate current page by sy-pagno,
but my question is, how can we calculate the total page number of the list report.
Thanks in advance
Anandhi check this,
*& Report ZVG_ALV_SLIST2 *
report zvg_alv_slist2 .
ALV
type-pools: slis.
G L O B A L I N T E R N A L T A B L E S
data: gt_fieldcat type slis_t_fieldcat_alv,
gs_layout type slis_layout_alv,
gt_events type slis_t_event.
data: it_sort type slis_t_sortinfo_alv ,
wa_sort type slis_sortinfo_alv .
data: gs_print type slis_print_alv.
data: begin of it_sflight occurs 0,
carrid like sflight-carrid,
connid like sflight-connid,
fldate like sflight-fldate,
price like sflight-price,
planetype like sflight-planetype,
seatsmax like sflight-seatsmax,
seatsocc like sflight-seatsocc,
paymentsum like sflight-paymentsum,
end of it_sflight.
*DATA: GI_SFLIGHT LIKE STANDARD TABLE OF ST_SFLIGHT.
data: g_repid like sy-repid.
data: gt_list_top_of_page type slis_t_listheader.
data: v_total(5).
start-of-selection.
g_repid = sy-repid.
perform init_fieldcat using gt_fieldcat[].
perform build_eventtab using gt_events[].
perform build_comment using gt_list_top_of_page[].
perform get_data.
perform set_layout using gs_layout.
SORTING
clear wa_sort.
wa_sort-fieldname = 'CARRID'.
wa_sort-up = 'X'.
wa_sort-group = '*'.
wa_sort-subtot = 'X'.
append wa_sort to it_sort.
clear wa_sort.
wa_sort-fieldname = 'CONNID'.
wa_sort-up = 'X'.
wa_sort-group = 'UL'.
wa_sort-subtot = 'X'.
append wa_sort to it_sort.
DISPLAY LIST
call function 'REUSE_ALV_LIST_DISPLAY'
exporting
i_interface_check = ' '
i_callback_program = g_repid
i_callback_user_command = 'USER_COMMAND'
is_layout = gs_layout
it_fieldcat = gt_fieldcat[]
it_sort = it_sort[]
it_events = gt_events
is_print = gs_print
tables
t_outtab = it_sflight
exceptions
program_error = 1
others = 2.
if sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
*& Form INIT_FIELDCAT
form init_fieldcat using p_gt_fieldcat type slis_t_fieldcat_alv.
data: ls_fieldcat type slis_fieldcat_alv,
l_index type sy-tabix.
data :rep like sy-repid.
rep = sy-repid.
call function 'REUSE_ALV_FIELDCATALOG_MERGE'
exporting
i_program_name = rep
i_internal_tabname = 'IT_SFLIGHT'
i_inclname = rep
changing
ct_fieldcat = gt_fieldcat
exceptions
inconsistent_interface = 1
program_error = 2
others = 3.
if sy-subrc <> 0.
message id sy-msgid type 'S' number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-subrc.
endif.
sort gt_fieldcat by col_pos.
loop at gt_fieldcat into ls_fieldcat.
l_index = sy-tabix.
if ls_fieldcat-fieldname = 'PRICE'.
ls_fieldcat-do_sum = 'X'.
ls_fieldcat-sp_group = 'X'.
modify gt_fieldcat from ls_fieldcat index l_index .
endif.
endloop.
endform. " INIT_FIELDCAT
*& Form BUILD_EVENTTAB
form build_eventtab using p_gt_events type slis_t_event.
data: ls_event type slis_alv_event.
clear ls_event.
ls_event-name = slis_ev_top_of_page.
ls_event-form = 'XTOP_OF_PAGE'.
append ls_event to p_gt_events.
clear ls_event.
ls_event-name = slis_ev_top_of_list.
ls_event-form = 'XTOP_OF_LIST'.
append ls_event to p_gt_events.
clear ls_event.
clear ls_event.
ls_event-name = slis_ev_end_of_page.
ls_event-form = 'XEND_OF_PAGE'.
append ls_event to p_gt_events.
ls_event-name = slis_ev_end_of_list.
ls_event-form = 'XEND_OF_LIST'.
append ls_event to p_gt_events.
clear ls_event.
endform. " BUILD_EVENTTAB
*& Form BUILD_COMMENT
form build_comment using p_gt_list_top_of_page type slis_t_listheader.
data: ls_line type slis_listheader.
ls_line-typ = 'H'." = Header, S = Selection, A = Action
ls_line-key = 'KEY'.
ls_line-info = 'INFO'.
append ls_line to p_gt_list_top_of_page.
endform. " BUILD_COMMENT
*& Form SELECTION
form get_data..
data: l_rows type i value 3.
Read data from table SFLIGHT
select carrid
connid
fldate
price
planetype
seatsmax
seatsocc
paymentsum
from sflight
into table it_sflight.
up to l_rows rows.
sort it_sflight.
endform. " SELECTION
*& Form SET_LAYOUT
form set_layout using p_gs_layout type slis_layout_alv.
* P_GS_LAYOUT-F2CODE = P_F2CODE.
p_gs_layout-zebra = 'X'.
p_gs_layout-colwidth_optimize = 'X'.
p_gs_layout-no_input = 'X'.
p_gs_layout-no_colhead = space.
p_gs_layout-totals_text = 'Total Price'.
p_gs_layout-subtotals_text = 'Sub Total'.
p_gs_layout-totals_only = 'X'.
p_gs_layout-key_hotspot = 'X'.
p_gs_layout-detail_popup = 'X'.
p_gs_layout-no_subtotals = space.
p_gs_layout-expand_all = 'X'.
p_gs_layout-group_buttons = 'X'."space.
endform. " SET_LAYOUT
FORM XTOP_OF_PAGE *
form xtop_of_page.
data : lv_page(5),
lv_text(20).
MOVE SY-PAGNO TO LV_PAGE.
write:/ 'X_TOP_OF_PAGE'.
endform. "xtop_of_page
FORM XTOP_OF_LIST *
form xtop_of_list.
write:/ 'X_TOP_OF_LIST'.
endform. "xtop_of_list
FORM XEND_OF_PAGE *
form xend_of_page.
write:/ 'X_END_OF_PAGE'.
endform. "xend_of_page
FORM XEND_OF_LIST *
form xend_of_list.
write:/ 'X_END_OF_LIST'.
data : lv_page(5),
lv_text(20).
data : l_lines type i,
l_line type i.
clear v_total.
write sy-pagno to v_total left-justified.
export v_total to memory id 'V_TOTAL'.
do sy-pagno times.
lv_page = sy-index.
concatenate 'Page' lv_page 'of' v_total
into lv_text separated by space.
if sy-index = 1.
read line 2 of page sy-index.
else.
read line 1 of page sy-index.
endif.
sy-lisel+60(20) = lv_text.
modify current line .
enddo.
endform. "xend_of_list
USER_COMMAND *
form user_command using r_ucomm like sy-ucomm
rs_selfield type slis_selfield.
case r_ucomm.
when 'EXIT'.
leave to screen 0.
when '&IC1'.
data: text(256),text1(6),text2(5).
move rs_selfield-tabindex to text1.
move rs_selfield-sumindex to text2.
concatenate 'Double clicked on (field:'
rs_selfield-fieldname
'Value:'
rs_selfield-value
text1
text2
into text
separated by space.
call function 'POPUP_TO_DISPLAY_TEXT'
exporting
textline1 = text.
endcase.
endform. "user_command
regards,
venkat. -
Page Number Error when export to PDF
I am getting an error on page numbers for a book file when I export to PDF. The page numbers are set in the master pages and when I export each chapter individually the page number show fine. When I export the entire book, then some of the page numbers repeat. The pages are the right pages, but the numbers change incorrectly. For instance, the sequence goes, 58, 59, 58, 61 and 72, 73, 72, 73, 76.
I've updated to the latest InDesign (7.5.2) and have tried multiple PDF export options (High Print, Press, PDF/X, etc) and nothing fixes it.
Any suggestions?
thanksThis is a known (and fairly catastrophic) problem in CS5.5.
Some people have found exporting the individual INDD files to IDML, resaving them as INDD files (don't overwrite your originals!! Make a backup first!), and recreating the book works...for a while.
You could revert to CS5.0 if you have a license for it.
CS6 is on the horizon and should fix this bug.
Hopefully there'll be a CS5.5 maintenance update to do so as well.
Sorry I don't have a better suggestion. -
Masking Page number in Application web link
Hi,
Is there any way to mask page numbe(s) in Apex Application web link.
For example, http://<server name>/pls/apex/f?p=111 is the web address to access my Apex application and it defaults to home page, if I run this application. After that, if I navigate to any other page(example page number 200) within the application, Page number will appends to the above web-link as below
http://<server name>/pls/apex/f?p=111:*200*:3080776628071182::NO
Is there any way, can we mask page number/application number in application web-link.
Appreciate your help.
Thanks,ManikHi Manik,
The only way that I know to mask a page is to use a page alias. For example page 200 is page aliased as HOME.
So where ever you would call pagee 200 from a application liunk you would use HOME instead of 200. I am not sure how to mask the application number. I would have to test that out.
Cheers Mike -
Page Number in Normal Report List?
Is this possible? How? I need to put like Page 1 of 1 on the lower right hand corner of the report page.
Thanks rewards will be givenHI
see this report
page number is there, just adjust the place of possition
REPORT ZNNR_REPORT NO STANDARD PAGE HEADING MESSAGE-ID ZNNR LINE-SIZE 100 LINE-COUNT 65(4).
******DATA DECLARATIONS**********
DATA : BEGIN OF IT_PLANT OCCURS 0,
MATNR LIKE MARA-MATNR,
WERKS LIKE MARC-WERKS,
PSTAT LIKE MARC-PSTAT,
EKGRP LIKE MARC-EKGRP,
END OF IT_PLANT.
DATA : BEGIN OF IT_PONO OCCURS 0,
EBELN LIKE EKKO-EBELN,
EBELP LIKE EKPO-EBELP,
MATNR LIKE EKPO-MATNR,
WERKS LIKE EKPO-WERKS,
LGORT LIKE EKPO-LGORT,
END OF IT_PONO.
TABLES EKKO.
********END OF DATA DECLARATIONS*********
********SELECTION SCREEN DESIGN ***********
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETER : P_WERKS LIKE MARC-WERKS MODIF ID S1.
SELECT-OPTIONS : S_EBELN FOR EKKO-EBELN NO INTERVALS MODIF ID S2.
SELECTION-SCREEN END OF BLOCK B1.
SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-004.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS : R1 RADIOBUTTON GROUP G1 DEFAULT 'X'.
SELECTION-SCREEN COMMENT 5(20) TEXT-002 FOR FIELD R1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
PARAMETERS : R2 RADIOBUTTON GROUP G1.
SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD R2.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END OF BLOCK B2.
******END OF SELECTION SCREEN DESIGN****************
*********INITIALIZATION OF SELECTION SCREEN ELEMENTS.*****
INITIALIZATION.
P_WERKS = '1000'.
S_EBELN-LOW = '4500016926'.
S_EBELN-OPTION = 'EQ'.
S_EBELN-SIGN = 'I'.
APPEND S_EBELN.
CLEAR S_EBELN.
************END OF INITIALIZATION***********************
***********SCREEN MODIFICATIONS*******************
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF R1 EQ 'X' AND SCREEN-GROUP1 EQ 'S2'.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
IF R2 EQ 'X' AND SCREEN-GROUP1 EQ 'S1'.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
********END OF SCREEN MODIFICATIONS*****************
***************SCREEN VALIDATIONS *****************
at selection-screen.
SELECT SINGLE *
FROM EKKO
INTO EKKO
WHERE EBELN IN S_EBELN.
IF SY-SUBRC <> 0.
SET CURSOR FIELD 'S_EBELN-LOW'.
MESSAGE E999 WITH TEXT-005.
ENDIF.
********end of screen validation*****************
START-OF-SELECTION.
*set pf-status '100'.
IF R1 EQ 'X'.
SELECT MATNR
WERKS
PSTAT
EKGRP
FROM MARC
INTO TABLE IT_PLANT
WHERE WERKS = P_WERKS.
LOOP AT IT_PLANT.
WRITE : SY-VLINE , 2 IT_PLANT-MATNR COLOR COL_KEY,
21 SY-VLINE , 22 IT_PLANT-WERKS COLOR COL_KEY,
27 SY-VLINE ,28 IT_PLANT-PSTAT COLOR COL_NORMAL,
43 SY-VLINE ,44 IT_PLANT-EKGRP COLOR COL_NORMAL.
ENDLOOP.
ENDIF.
IF R2 EQ 'X'.
SELECT EBELN EBELP MATNR WERKS LGORT
FROM EKPO
INTO TABLE IT_PONO
WHERE EBELN IN S_EBELN.
LOOP AT IT_PONO.
WRITE : SY-VLINE , 2 IT_PONO-EBELN COLOR COL_KEY,
12 SY-VLINE , 13 IT_PONO-EBELP COLOR COL_KEY,
18 SY-VLINE , 19 IT_PONO-MATNR COLOR COL_NORMAL,
37 SY-VLINE , 38 IT_PONO-WERKS COLOR COL_NORMAL,
44 SY-VLINE , 45 IT_PONO-LGORT COLOR COL_NORMAL, 49 SY-VLINE..
ENDLOOP.
ENDIF.
TOP-OF-PAGE.
IF R1 EQ 'X'.
*ULINE AT /1(48).
WRITE : SY-VLINE ,2 'MATERIAL NUMBER',
21 SY-VLINE , 22 'PLANT',
27 SY-VLINE , 28 'STATUS',
43 SY-VLINE , 44 'GRUP', 48 SY-VLINE.
ULINE AT /1(48).
ENDIF.
IF R2 EQ 'X'.
WRITE : SY-VLINE , 2 'PO NUMBER',
12 SY-VLINE, 13 'ITEM',
18 SY-VLINE,19 'MATERIAL NUMBER',
37 SY-VLINE, 38 'PLANT',
44 SY-VLINE, 45 'GRUP',
49 SY-VLINE.
ULINE AT /1(50).
ENDIF.
<b>END-OF-PAGE.
ULINE AT /1(50).
WRITE :/10 'PAGE NUMBER', SY-PAGNO.</b>
<b>Reward if usefull</b> -
Reseting page number in Word RTF template for BI Publisher PDF generation
Hi!
Apex 4.0.2, Oracle 10.2.0.4, BIP 10.2
Bills are created based on Word RTF file with BI Publisher. Reszulting file is one big PDF file, which has many pages.
Word RTF template is grouped on BILLS.ID field with page break option. So one BILLS.ID may have one or many pages (according data).
How to create RTF template (for PDF BI Publisher generation) with reseting page numbers when grouping value change.
Page numbers are in footer in format
curr_group_page/total_group_pages
where:
curr_group_page is current page number in group (defined with BILLS.ID field),
total_group_pages is total page number of pages in group (defined with BILLS.ID field).
I need to reset numbering whenever BILLS.ID (group) change.
Example:
ID=1 (4 pages)
1/4, 2/4, 3/4, 4/4
ID=2 (1 pages)
1/1
ID=3 (2 pages)
1/2, 2/2
ID=4 (3 pages)
1/3, 2/3, 3/3
etc.
How to achieve that kind of numbering?
Any help appreciated.
Regards,
Damir Vadas
Edited by: Damir Vadas on May 16, 2011 12:49 PMSimple question.. Does your posting deal with an APEX issue or a BI Publisher issue? The posting you have deals with the RTF add-on for Word that builds report layouts for BI Publisher. I suggested in my response that you move it to a more relevant forum..
If you feel that me alerting you to the fact your are VIOLATING forum policy is an issue, please feel free to ask others their view.. (posting to a 3 year old closed thread, creating MULTIPLE threads for a single issue..) You do NOT seem to get the idea that posting this in the Bi Publisher support forum would probably get you a BETTER response than here.. Asking pl/sql questions here will also get people to refer your questions to the PL/Sql Support forum..
Also, here is a POSSIBLE answer from the BI Publisher Forum: http://forums.oracle.com/forums/thread.jspa?threadID=594805
This Is The APEX SUPPORT forum, we deal with SUPPORT questions on APEX (Application Express)..
Thank you,
Tony Miller
Webster, TX
You know, I used to think that it was awful that life was so unfair. Then I thought, wouldn't it be much worse if life were fair, and all the terrible things that happen to us come because we actually deserve them? So, now I take great comfort in the general hostility and unfairness of the universe.
If this question is answered, please mark the thread as closed and assign points where earned.. -
Page number reset in .rtf template
Hello,
In the AR statements report, If I run the report for mutiple customers, page number has to be reset for each bill_to customer...
I have the header part from the second page, so when I run the report for multiple customers...even for the new customer's first page...header is coming....
So I assume by resetting the page number for every bill to automatically solve the issue of header from second page...
Please advise...how to reset the page# based on a condition ( for each bill to)...I know it work with @section....
but my template is like <?for-each-group:G_STATEMENT;./STATEMENT_DATE?><?for-each-group:current-group();././././././././././././././SEND_TO_ADDRESS_ID?>
-Sridhar
Edited by: user7751421 on Oct 12, 2011 4:32 AMIf you could send me your xml and template i can give a try.
[email protected] is my email id.
Maybe you are looking for
-
FF doesn't work anymore, and seeing this forum through IE6 makes me hate things
== Issue == Firefox is crashing or closing unexpectedly == Description == This is a direct reply to http://support.mozilla.com/en-US/forum/1/594409 because I cannot answer to it. I selected "I have the same problem" among the checkboxes and it tells
-
Hi all, If you generate export datasource for Infocube. how you recognise in the MANAGE section of the infocube that infocube data has been transfered to other data target.where as in ODS you can view the D- Datamart Status of the ODS, by whi
-
Problem with WRT160NV2, both wired and wireless...
I bought a WRT160NV2 Refurbed from CompUSA about 2 weeks ago, and since then I've been having some problems. It's not every site, but there are a few sites (three or four I've noticed) that load very, very, very slowly. It happens using wired or wir
-
Hi All, I am using Oracle 10.2. I had a query as: SELECT schma1.ASN_IR_ID_SQ.NEXTVAL * INTO seq_11 FROM DUAL;* when i run this query i am getting error as : ora- 02289: sequence does not exist Thanks
-
Pc will no reconize my iphone 4s
pc will not see my iphone 4s when i connect it what can i do to get it working