Recording the total of a rolling sequence
I am recording times taken for a production sequence to complete. The time is recorded in seconds by the plc, which counts upward from zero until the production sequence has completed, after a short pause the plc resets itself to zero and repeats the count for the next sequence. I would like to write the totals of each sequence to a tag so I can show total production times for each sequence in a table or on a historical chart.
I am unsure how to program labVIEW to take the total times for each repetition of the sequence and write the information to say, a tag. If anyone can offer an example of how I can retrieve these values I would be u-n-b-e-l-i-e-v-a-b-l-y grateful!!
Many thanks,
Stuart
Hi Stuart,
"I would like labVIEW to count the cycle/recognise the end of cycle"
From your descriptions so far, the only indication that your HMI/LabVIEW DSC program will have that a production cycle is complete is/are:
1) there will be a "short pause" during which the Total Cycle Time value will stick at its maximum value; and
2) the Total Cycle Time value gets reset to zero.
Idea: Monitor the Total Cycle Time timer/counter/data register as an Input tag (not logged). Use a shift register in your state machine's ** while loop to store the value from the previous time you monitored this Total Cycle Time tag. When the current value is < (less than) the previous value, a new cycle has started. Write the previous value to a 'Total Cycle Time' Memory tag that is configured to log.
" Also, I have not managed to configure a tag with a deadband of 0% without an error appearing in the configuration editor"
That's a headache. What kind of error message (if any) do you get? Have you tried it for different types of tags (Input, Memory, etc. etc.). What deadband(s) are you trying to set to zero?
There's a useful KnowledgeBase doc summarizing deadbands here.
If you want to have a logging deadband of 0%, you do have to have the Tag Engine Update deadband at 0% as well.
** Re: State machine
If you haven't done so already, you may want to look at examples of the use of a state machine as an overall structure for LabVIEW programs. Simple examples ship with LabVIEW. If you search this forum, you will find many discussions on its merits and different forms. There've also been a number of presentations/docs on the idea. A couple which come to mind are:
- Rob Humfeld's NI Week 2004 presentation here (the "State Machines" link at the bottom).
- LabVIEW Application Design Patterns from 2002.
Without the use of some kind of flavour of state machine, the block diagram for a LabVIEW DSC program can get messy and hard to debug very fast.
=====================================================
Fading out. " ... J. Arthur Rank on gong."
Similar Messages
-
How to get the total record count for the report
Hi,
How can I get count of the total records shown in the report. When we set the report attributes, we have an option "Set Pagination from X to Y of Z"
Does anyone know how can I get the Z value from APEX variables.
I know we can use that query and get the count but I just want to know how we can use APEX Variables effectively.
Thanks in advance.You write a loop, something like this:
Go_block('B1');
If not form_success then
Raise Form_Trigger_failure;
End if;
First_Record;
If not form_success then
Raise Form_Trigger_failure;
End if;
Loop
If :system.record_status in('CHANGED','INSERT') then
-- modify the record here--
End if;
Exit when :System.Last_Record = 'TRUE';
Next_Record;
End Loop;
First_Record;But be very careful-- If your block can fetch a large number of rows, (over 100), this loop can take a long time, and you should not use this method. The loop will continue fetching more rows from the database until all rows satisfying the query are retrieved. -
How to get the total record count in ODI
Hi
I have the interface the are file to DB.
The format is like this..
HEADER
DETAIL
TRAILER
Now will write the contains of file to DB,
But i have to insert the total count ie numberof record written from file to DB in my Trailer record.
can you tell me how can i get the total count of records in file and write it to trailer?
Also, I want the interface to rollback the data if something fails will loading the data from file., ie. if there are 100 records in file and 50 got transfer and something fails i want to rollabck the 50 records from DB.???
Thanks :)Hi
You can design a flow for Full load flow and incremental flow from flat file to Table.
Create a table at target database like.. (create table with last_execution and palce the V_FULL_LOAD value and LAST_EXECUTION_DT columns in last_execution table)
Add faltfile as table in model, create a variable as V_FULL_LOAD and make sure that the default values is 01-01-1900
Create one more variable like V_LAST_EXECUTION_DATE (in this variable write a case statement that if V_FULL_LOAD value is 'Y" then full load should happen and same time you should check that V_FULL_LOAD column is balnk then write insert statment else write update statement to update last_execution_dt column, similar for 'N')
please provide your *personal mail ID*, i will send a doc file realted to your query.
we have to tables present in work repository (SNP_STEP and STEP_LOG tables) using tables we can get how many records are inserted/updated and we can find how many records are not transfer and gor error.
Thanks
Phani -
Displaying the total no of records in ALV ouput.
Hi everybody,
I am displaying the output in ALV.
I want display the total number of records at the top of page.( before the columns).
Can any one throw light on this plz.
Karunakar reddyTo get the number of entries in your displayed table use:
<i>DESCRIBE TABLE tab LINES wg_lines.</i>
To display the value in a ALV Grid Control, use something like this:
<i>DATA: sl_layout TYPE lvc_s_layo.
sl_layout-grid_title = wl_lines.
CALL METHOD og_alv->set_table_for_first_display
EXPORTING
is_layout = sl_layout
....</i>
Regards,
Martin -
Count the total amount of records returned
Is there a way in DW to count and display the total amount of records in my DB table?
Eg: I might have 10,000 records in my database, but only 55 match the SELECT statement, so I want to show a visual counter saying '55 articles in this section' on my page.Choose one of these function appropriate to the api you are using:
http://php.net/manual/en/function.mysql-num-rows.php -
Calculating the total in alv and displaying the date
Hi,
I am trying to calculate the totals of netwr and fkimg in a report but the following coding cannot giv me the right answer so if there is anyone with the solution for this problem may you please help me out and how can i display the date on my report......here is my coding:
REPORT Z_DAILY_STOCK_NEW.
TYPE-POOLS: SLIS.
TABLES
TABLES: vbrk, kna1,vbrp,vbap,vbak, sflight.
ALV FIELDS
DATA: it_fieldcat TYPE SLIS_T_FIELDCAT_ALV WITH HEADER LINE,
wa_fieldcat TYPE slis_fieldcat_alv.
DATA: w_cnt LIKE sy-tabix.
total ref to data.
t_alv LIKE TABLE OF s_error WITH HEADER LINE.
DATA: gr_layout TYPE slis_layout_alv,
gr_tab_group TYPE slis_t_sp_group_alv,
gr_repid LIKE sy-repid,
gr_events TYPE slis_t_event,
gr_print TYPE slis_print_alv,
gr_user TYPE slis_formname VALUE 'USER_COMMAND'.
SELECTION SCREEN
SELECT-OPTIONS:
s_werks FOR vbrp-werks,
s_auart FOR vbak-auart.
DEFINITION OF AN INTERNAL TABLE
DATA: begin of i_stocktab occurs 0,
kunag LIKE vbrk-kunag,
name1 LIKE kna1-name1,
ort01 LIKE kna1-ort01,
inco1 LIKE vbrk-inco1,
vkgrp LIKE vbrp-vkgrp,
fkimg LIKE vbrp-fkimg,
netwr LIKE vbrk-netwr,
end of i_stocktab.
START OF SELECTION
SELECT vbrkkunag kna1name1 kna1ort01 vbrkinco1 vbrp~vkgrp
vbrpfkimg vbrknetwr
FROM kna1 inner join vbrk on kna1kunnr EQ vbrkkunrg
inner join vbak on kna1kunnr EQ vbakkunnr
inner join vbrp on vbrkvbeln EQ vbrpvbeln
INTO i_stocktab
WHERE vbrp~werks IN s_werks
AND vbak~auart IN s_auart.
APPEND i_stocktab.
ENDSELECT.
*DATA tb_alv TYPE i_stocktab WITH HEADER LINE.
PERFORM build_fieldcatalog.
PERFORM build_layout.
PERFORM build_event.
PERFORM build_print.
PERFORM calc_total.
PERFORM display_alv_report.
FORM build_fieldcatalog.
w_cnt = 1.
it_fieldcat-fieldname = 'KUNAG'.
it_fieldcat-seltext_m = 'Soldtp'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
it_fieldcat-key = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'NAME1'.
it_fieldcat-seltext_m = 'Name'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'ORT01'.
it_fieldcat-seltext_m = 'City'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'INC01'.
it_fieldcat-seltext_m = 'Incoterms'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'VKGRP'.
it_fieldcat-seltext_m = 'Sales Group'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'FKIMG'.
it_fieldcat-seltext_m = 'Invoiced Qty'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
*it_fieldcat-do_sum = 'x'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'NETWR'.
it_fieldcat-seltext_m = 'Invoiced Value'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
it_fieldcat-do_sum = 'x'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
ENDFORM.
FORM build_layout.
gr_layout-no_input = 'X'.
gr_layout-colwidth_optimize = 'X'.
gr_layout-totals_text = 'Totals: '(201).
gr_layout-detail_popup = 'X'.
ENDFORM.
FORM build_event.
DATA i_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = gr_events[].
READ TABLE gr_events WITH KEY name = slis_ev_user_command
INTO i_event.
if sy-subrc = 0.
MOVE gr_user TO i_event-form.
APPEND i_event TO gr_events.
endif.
ENDFORM.
*FORM calc_total.
LOOP AT it_fieldcat into wa_fieldcat
WHERE fieldname EQ 'FKIMG' OR
fieldname EQ 'NETWR'.
wa_fieldcat-do_sum = 'X'.
wa_fieldcat-datatype = 'QUAT'.
modify it_fieldcat from wa_fieldcat.
ENDLOOP.
*ENDFORM.
FORM build_print.
gr_print-reserve_lines = '2'.
gr_print-no_coverpage = 'X'.
ENDFORM.
FORM calc_total.
DATA: total type ref to data,
subtotal1 type ref to data.
field-symbols <fkimg> like sflight.
field-symbols <netwr> like sflight.
call method grid1-> get_subtotals
importing
ep_collect00 = subtotal
ep_collect01 = total.
assign total to <fkimg>.
assign total to <netwr>.
ENDFORM.
*& FUNCTION ALV DISPLAY
FORM display_alv_report.
gr_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = gr_repid
I_CALLBACK_USER_COMMAND = slis_ev_user_command
I_CALLBACK_TOP_OF_PAGE = 'TOP-OF-PAGE' " see FORM
IS_LAYOUT = gr_layout
IT_FIELDCAT = it_fieldcat[]
IT_SPECIAL_GROUPS = gr_tab_group
I_SAVE = 'X'
IT_EVENTS = gr_events
IS_PRINT = gr_print
TABLES
t_outtab = i_stocktab
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2.
IF sy-subrc <> 0.
ENDIF.
ENDFORM.
FORM top-of-page.
*ALV Header deaclarations
DATA: t_header TYPE slis_t_listheader,
wa_header TYPE slis_listheader,
t_line LIKE wa_header-info,
ld_lines TYPE i,
ld_linesc TYPE c.
*Title
wa_header-typ = 'H'.
wa_header-info = 'Report for daily Stock Returns'.
APPEND wa_header TO t_header.
CLEAR wa_header.
*Total No. Records Selected
DESCRIBE TABLE i_stocktab LINES ld_lines.
ld_linesc = ld_lines.
CONCATENATE 'Total No. of Records Selected:' ld_linesc
INTO t_line SEPARATED BY space.
wa_header-typ = 'A'.
wa_header-info = t_line.
APPEND wa_header TO t_header.
CLEAR: wa_header, t_line.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = t_header.
ENDFORM.Try This
REPORT z_daily_stock_new.
TYPE-POOLS: slis.
* TABLES
TABLES: vbrk, kna1,vbrp,vbap,vbak, sflight.
* ALV FIELDS
DATA: it_fieldcat TYPE slis_t_fieldcat_alv WITH HEADER LINE,
wa_fieldcat TYPE slis_fieldcat_alv.
DATA: w_cnt LIKE sy-tabix.
* total ref to data.
* t_alv LIKE TABLE OF s_error WITH HEADER LINE.
DATA: gr_layout TYPE slis_layout_alv,
gr_tab_group TYPE slis_t_sp_group_alv,
gr_repid LIKE sy-repid,
gr_events TYPE slis_t_event,
gr_print TYPE slis_print_alv,
gr_user TYPE slis_formname VALUE 'USER_COMMAND'.
* SELECTION SCREEN
SELECT-OPTIONS:
s_werks FOR vbrp-werks,
s_auart FOR vbak-auart.
* DEFINITION OF AN INTERNAL TABLE
DATA: BEGIN OF i_stocktab OCCURS 0,
kunag LIKE vbrk-kunag,
name1 LIKE kna1-name1,
ort01 LIKE kna1-ort01,
inco1 LIKE vbrk-inco1,
vkgrp LIKE vbrp-vkgrp,
fkimg LIKE vbrp-fkimg,
netwr LIKE vbrk-netwr,
END OF i_stocktab.
* START OF SELECTION
SELECT vbrk~kunag kna1~name1 kna1~ort01 vbrk~inco1 vbrp~vkgrp
vbrp~fkimg vbrk~netwr
FROM kna1 INNER JOIN vbrk ON kna1~kunnr EQ vbrk~kunrg
INNER JOIN vbak ON kna1~kunnr EQ vbak~kunnr
INNER JOIN vbrp ON vbrk~vbeln EQ vbrp~vbeln
INTO i_stocktab
WHERE vbrp~werks IN s_werks
AND vbak~auart IN s_auart.
APPEND i_stocktab.
ENDSELECT.
*DATA tb_alv TYPE i_stocktab WITH HEADER LINE.
PERFORM build_fieldcatalog.
PERFORM build_layout.
PERFORM build_event.
PERFORM build_print.
PERFORM calc_total.
PERFORM display_alv_report.
* FORM build_fieldcatalog *
FORM build_fieldcatalog.
w_cnt = 1.
it_fieldcat-fieldname = 'KUNAG'.
it_fieldcat-seltext_m = 'Soldtp'.
it_fieldcat-emphasize = 'X'.
it_fieldcat-key = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'NAME1'.
it_fieldcat-seltext_m = 'Name'.
it_fieldcat-emphasize = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'ORT01'.
it_fieldcat-seltext_m = 'City'.
it_fieldcat-col_pos = w_cnt.
it_fieldcat-emphasize = 'X'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
* w_cnt = w_cnt + 1.
* it_fieldcat-fieldname = 'INC01'.
* it_fieldcat-seltext_m = 'Incoterms'.
* it_fieldcat-emphasize = 'X'.
* APPEND it_fieldcat TO it_fieldcat.
* CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'VKGRP'.
it_fieldcat-seltext_m = 'Sales Group'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
it_fieldcat-fieldname = 'FKIMG'.
it_fieldcat-seltext_m = 'Invoiced Qty'.
it_fieldcat-emphasize = 'X'.
it_fieldcat-ref_tabname = 'VBRP' .
it_fieldcat-ref_fieldname = 'FKIMG' .
it_fieldcat-do_sum = 'X' .
* *it_fieldcat-do_sum = 'x'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
w_cnt = w_cnt + 1.
clear it_fieldcat .
it_fieldcat-fieldname = 'NETWR'.
it_fieldcat-seltext_m = 'Invoiced Value'.
it_fieldcat-emphasize = 'X'.
it_fieldcat-ref_tabname = 'VBRP' .
it_fieldcat-ref_fieldname = 'NETWR' .
it_fieldcat-do_sum = 'X' .
* it_fieldcat-do_sum = 'x'.
APPEND it_fieldcat TO it_fieldcat.
CLEAR it_fieldcat.
ENDFORM.
* FORM build_layout *
FORM build_layout.
gr_layout-no_input = 'X'.
gr_layout-colwidth_optimize = 'X'.
gr_layout-totals_text = 'Totals: '(201).
gr_layout-detail_popup = 'X'.
ENDFORM.
* FORM build_event *
FORM build_event.
DATA i_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = gr_events[].
READ TABLE gr_events WITH KEY name = slis_ev_user_command
INTO i_event.
IF sy-subrc = 0.
MOVE gr_user TO i_event-form.
APPEND i_event TO gr_events.
ENDIF.
ENDFORM.
*FORM calc_total.
* LOOP AT it_fieldcat into wa_fieldcat
* WHERE fieldname EQ 'FKIMG' OR
* fieldname EQ 'NETWR'.
* wa_fieldcat-do_sum = 'X'.
* wa_fieldcat-datatype = 'QUAT'.
* modify it_fieldcat from wa_fieldcat.
* ENDLOOP.
*ENDFORM.
FORM build_print.
gr_print-reserve_lines = '2'.
gr_print-no_coverpage = 'X'.
ENDFORM.
* FORM calc_total *
FORM calc_total.
DATA: total TYPE REF TO data,
subtotal1 TYPE REF TO data.
* FIELD-SYMBOLS <fkimg> LIKE sflight.
* FIELD-SYMBOLS <netwr> LIKE sflight.
* CALL METHOD grid1-> get_subtotals
* IMPORTING
* ep_collect00 = subtotal
* ep_collect01 = total.
* ASSIGN total TO <fkimg>.
* ASSIGN total TO <netwr>.
ENDFORM.
*& FUNCTION ALV DISPLAY
FORM display_alv_report.
gr_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = gr_repid
i_callback_user_command = slis_ev_user_command
i_callback_top_of_page = 'TOP-OF-PAGE' " see FORM
is_layout = gr_layout
it_fieldcat = it_fieldcat[]
it_special_groups = gr_tab_group
i_save = 'X'
it_events = gr_events
is_print = gr_print
TABLES
t_outtab = i_stocktab
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
ENDIF.
ENDFORM.
* FORM top-of-page *
FORM top-of-page.
*ALV Header deaclarations
DATA: t_header TYPE slis_t_listheader,
wa_header TYPE slis_listheader,
t_line LIKE wa_header-info,
ld_lines TYPE i,
ld_linesc TYPE c.
*Title
wa_header-typ = 'H'.
wa_header-info = 'Report for daily Stock Returns'.
APPEND wa_header TO t_header.
CLEAR wa_header.
*Total No. Records Selected
DESCRIBE TABLE i_stocktab LINES ld_lines.
ld_linesc = ld_lines.
CONCATENATE 'Total No. of Records Selected:' ld_linesc
INTO t_line SEPARATED BY space.
wa_header-typ = 'A'.
wa_header-info = t_line.
APPEND wa_header TO t_header.
CLEAR: wa_header, t_line.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = t_header.
ENDFORM. -
How can I get the total "values" in a hashtable ?
i know that i can get the total values in a hashtable by hash.elements() method. It returns an
enumeration with all the values present in this hashtable. this is fine upto here.
Now the preoblem is:
According to what rule this enumeration will be returned. I mean..
If i added in key A with value a,
then key B with value b;
then key C with value c;
then key D with value d;
(They all are objects of type String)
now i call ... hash.elements(); Suppose it returns Enumeration enum;.
Now in what order they all are present in this hashtable.
Meaning is that if i move arond this enum in what sequence they all will be returned.
option A ) In the same order as they were inserted in hashtable.
option B ) According to LIFO;
option C) There is no fix rules , simply it return all the elements and u cannot judge that the first element in enum was really the first element inserted in the hashtable and the second element of enum was really the second element inserted in the hashtable.
What do u think..which option is correct ?
Ny idea will highly appreciated.
Thanks in advance.
Sanjeev Dhimanhi, i am again..
boss ! this is not true..u just change the order and or change the keys and something like ...
"Sanjeev", "hello"
"Dhiman", "hi"
"Technosys" ,"Services"
u will find that its not LIFO..really i was thinking before coding my project that option A is correct and with knowledge i wrote 3 - 4 classes but when i run the programm its starts throwing errors.
so, i posted this question. I think "apppu" is right.
I think , firstly hash is calculated for each value and that value is returned which can be received in a fastest way and hence not necessarily in LIFO and FIFO..
Thanks to u also as u gave ur precious time for me.
Once again.
Thank you very much.
Sanjeev Dhiman -
With a contract number, how to know the total PO release value against it?
Usually one contract corresponds to multiple PO records, now we know the contract number, then how to know the total PO release value against this contract. In other word, we would like to know the total release value of all the POs with the same contract number. To just input the contract number in EKPO table? but then look for which field in this table to add these PO release values up?
We will give you reward points!
Thanks!hi Mohammad,
By following your instruction, input the contract number 4800000112 into Document number field, then hit Enter, get the following (only copy two records here for example), but kind of a mess. Could you let us know which one is the PO release value for this contract?
Contract Type Vendor Name PGp Agmt. date
Item Material Short text Mat. group
D I A Plnt SLoc Targ.qty. Un Net price Curr. per Un
4800000112 WK 2000012012 GULF INTERSTATE FIELD SERVICES QBH 06/20/2006
Agreement start06/20/2006 Agreement end 12/31/2007
Tgt. val. 1,000,000.00 USD Open 1,000,000.00 USD 100.00 %
00001 Inspection Svcs, Construction R3VNI
L U 0 UL 0.00 USD 1 EA
00002 Chief Inspector R3VNI
L U 0 DAY 390.00 USD 1 DAY -
Hi,
Again, I made a nice coloured picture from a screen capture which summarise the improvements that I would like to make in my form,
Situation:
For an educational purpose, I made this form to simplify the way of recording the data and also to develope the independence of the students.
( I am doing this on a voluntary basis, working extra hours on my free time but I don't really mind because I am learning a lot of things in the same time)
After being tested by the teacher, the student has to record the short date, the lines memorised, his grade, number of mistakes, and his attendance.
I created everything in Word, then converted the file in PDF, then I created all the different fields with Adobe acrobat.
There is in total 4 sheets, there are all similar except the first one in which there is a box with: date started, date finished, total time spent, absences.
Below this box there is a table with 16 lines from (A to P) and 7 columns (Days, Date, From.. to.. , Grade, No. lines memorised, No. Errors, Attendance) ( so this table is present on all the sheets)
Due to the fact that some students need more time than others, and also beacause some text need more time, I estimated a need of 4 sheets at the very most.
I would like to make the following amelioration and automate the inputting of some of the data because I know that some of the students will certainly forget, so to avoid this scenario I am trying to make this form the easiest possible.
screen capture of the form:
screen capture of the form editing, you can see the names of the different fields:
here is the form (only the first page) : http://cjoint.com/12fe/BBotMMgfYIy_memorisation_sheet_sample.pdf
In yellow 00000:
At present, the students has to input the total of absences manually, is there a way ( script) to automate this by initialising the field next to "Absences" at " 0 day" and then everytime that Absent is selected from the COMBO BOX, it add 1 and it is displayed like this: " 1 day" then " 2 days" then " 3 days" etc … (so from what I read I have to initialise a counter a the beginning and then for (i... ) count= count++; something like this...
Furthermore, I need a solution to overcome the possibility that a second sheet may be needed for the same student; therefore I would need the data from the "attendance column" from the second sheet ( and perhaps the 3rd and 4th aswell) to be added on the "absences field" in the first sheet
My idea: everytime that the short date is inputted in the first line (next to A) in the "Date" column of one of the 4 sheets then we check the 16 Combo box of the attendance column in this sheet instead to check 16*4=64 fields fot the 4 sheets in one go?
but I don't know at all how to write it in Javascript. Or perhaps there is a way more easier than that?
Shall I allocate a value for Absent on the “ export value”?
In purple
At present I wrote a simple script which matches the number of lines to the poem selected (Eg. if I select the poem V.Hugo, the number "36" will appear next to Number of lines).
Again I would like the make the life of the students very easy so I would like a script which detects this number “36” on the "From .. to …" column, as soon it is detected (on the first sheet or 2nd or 3rd or 4th) check from the same line if "A / Pass" or "B / Pass" have been selected in the "Grade" column ,if yes the short date inputted on this line will be written on the field next to "Date finished" .
this is a simple example with 36 lines only but somethimes, the students may have to memorise 80 lines and more, this is the reason for having 4 sheets in total.
So basically I would like to automate the field next to" Date finished:" with a script that collect the short date from the day in which the student has finished his memorisation with "A / Pass" or "B / Pass"
As for the "Total time spent" George Johnson helped me with a script that calculate the difference betwen date started and date finished (thank you)
I am sollicting your help, because after trying for hours I was really confused with the different if/else needed. And in top of that, it’s my first experience with Javascript.
I anticipate your assistance, thanking you in advance.I found this for counting the absences, its give you the total that's perfect, but is there a better methode which avoid me to write all the fields name, more simple????
( I found the idea here : Re: Total number added automatically )
// custom calculation script for field "Total #"
function CountFields(aFields) {
var nFields = 0;
for(i = 0; i < aFields.length; i++) {
try {
// count null values, export value of Absence is 0;
if(this.getField(aFields[i]).value == "0") nFields++;
} catch(e) {
if(e['message'] == "this.getField(aFields[i]) has no properties") app.alert("unknown field name: " + aFields[i]);
else app.alert(e.toString());
} // end catch
} // end for aFields
return nFields;
// create array of field names to count
var aNames = new Array("Sheet1AttendanceA","Sheet1AttendanceB","Sheet1AttendanceC","Sheet1AttendanceD","Sh eet1AttendanceE","Sheet1AttendanceF",
"Sheet1AttendanceG","Sheet1AttendanceH","Sheet1AttendanceI","Sheet1AttendanceJ","Sheet1Att endanceK","Sheet1AttendanceL",
"Sheet1AttendanceM","Sheet1AttendanceN","Sheet1AttendanceO","Sheet1AttendanceP" );
// count the non-null fields;
event.value = CountFields(aNames);
As for the 2nd question, I've tried to do something similar to the previous script, but of course it doesn't work, but I am quite sure that the idea is similar:
I don't know also how to add the other condition: the student should get A / Pass or B / Pass in order to consider he has finished??? and also how to check these condition from page 2, 3 and 4 and collect the date
function Datefinished(bFields) {
d2.value = nFields[i].value;
for(i = 0; i < aFields.length; i++) {
try {
if(this.getField(aFields[i]).value == this.getField("NumberLines").value) d2.value = nFields[i].value;
} catch(e) {
if(e['message'] == "this.getField(aFields[i]) has no properties") app.alert("unknown field name: " + aFields[i]);
else app.alert(e.toString());
} // end catch
} // end for aFields
return nFields;
// create array of field names to check
var aNames = new Array("Texte00","Texte54","Texte56","Texte58","Texte60","Texte62","Texte64","Texte66","Te xte68","Texte70","Texte72","Texte74","Texte76","Texte78","Texte80","Texte82");
var bNames = new Array("d1","d3","d4","d5","d6","d7","d8","d9","d10","d11","d12","d13","d14 ","d15","d16","d17"); // d1 is included because in some cases a student can finish in 1 day (short text); -
How to delete the total entries in ztable
Hi ,
How to delete the total entries in ztable...
code pls.
regards,Hi Venkat,
pls see below records,
Plant Material Alternate material
3770 00000000000126875 2020202
3770 000000000005999335 2020202
3770 117196 2020202
3780 00000000000126875 2020202
3784 00000000000126875 2020202
3784 000000000002809336 2020202
3784 000000000005999335 2 020202
3789 00000000000126875 2020202
if i write below syntax ,
delete from ztable where matkl = '2020202'.
all records contains matkl = '2020202' will be deleted ??
pls. reply. -
Is there a way to get the coherence reporter to record the interval?
There are three questions, really - but the first is the most important.
1. Can you get the reporter to record the duration since the last batch in seconds (or ms) in the same row as the current batch?
2. Can you get the reporter to record the timestamp in the report rows as ms since epoch (preferrably alongside the regular date in a different column, but by itself it'd probably be ok)
3. Is there any way to hook into the reporter output to customize how it records the actual data?
The jmx reporter records the batch number and the date of the batch run, but I don't see an easy way to get it to record the current date as a MS timestamp.
I've thought about creating a simple custom MBean that existed to do nothing but expose the current time in ms since epoch as an attribute that I could then have the reporter use and include a column both for the absolute date and for the relative date. Having certain metrics reported in terms of # of events / second would make it easier to analyze certain data (for instance, instead of showing the total ReadTimeMillis if it would show ReadTimeMillis / Reads / # ms * 60 to get the average time for a read, that would be a lot more useful for comparing intervals)
The intervals are never run on exactly the same schedule because the timer starts after the last report runs and the duration of running all the reports is not uniform.
(It'd also be very nice if the outputting of the reports were configurable and there was a way to plug into the reporting engine to hook in a different output method - e.g. to a database or to send the data over UDP to a graphite server or something)When I record the keyboard sounds as a midi track in Logic
I loose my sounds when I bounce to disc. Why do the sounds
not record on the hard drive when I bounce the midi track.
The plug in software instruments bounce fine to disc, but
not my keyboard sounds (external instrument-Roland XP 50
Keyboard)???
Think about it for a minute.... for one, MIDI is not audio, it's only data, you are not recording sound into the computer, the audio for the XP50 is coming out of the keyboard's audio outs. Software instruments take MIDI data and output directly to audio, so... they bounce fine as their output is audio. Your XP50 keyboard's audio outs are on the keyboard. So, you will have to record the audio from the keyboards output. I notice you're using Logic Express, unfortunately it doesn't have the I/O plugin.
pancenter- -
Printing only one line record with total of all items through alv
hi experts,
i am facing a problem while printing a list through alv.
requirement is, suppose i have 3 line items under one document no.
i have to print only one record with total amount of all items.more clearly...
1001 10 1000/-
1001 20 234/-
1001 30 540/- these records in internal table then i am passing it to reuse_alv_grid_display.
i need to display only 1001 1774/-(means sum of all the items)
please tell me how to do this.
thanks in advance,
manasihi ansari,
contains in itab
3000000004 02.11.2000 5550 27.95 27.95 0
3000000004 02.11.2000 5550 10.95 10.95 0
3000000005 02.11.2000 5550 27.95 27.95 0
3000000005 02.11.2000 5550 10.95 10.95 0
3000000006 02.11.2000 3020 52.99 52.99 0
3000000006 02.11.2000 3020 64.99 64.99 0
3000000006 02.11.2000 3020 49.5 49.5 0
3000000007 02.11.2000 3730 2,228.00 2,228.00 0
3000000007 02.11.2000 3730 1,698.00 1,698.00 0
3000000007 02.11.2000 3730 532 532 0
now please tell me how to print the data
output will be
3000000004 02.11.2000 5550 38.90 38.90 0
3000000005 02.11.2000 5550 38.90 38.90 0
3000000006 02.11.2000 3020 117.19 117.19 0
like that
please help me out
manasi -
How to find out the total, subtotal in alv report
hi dears,
how to find out the total, subtotal in alv report?
pls tell me logic ,
i will be waiting for eply
regards
eswarHi,
<b>ALV Grid List with sub-totals</b>
REPORT z_demo_alv_sort.
* This program lists orders (VBAK) with sort and sub-total for *
* 'sold-to-party' (KUNNR) and 'Sales organization' (VKORG) *
TABLES : vbak.
TYPE-POOLS: slis. " ALV Global types
SELECT-OPTIONS :
s_vkorg FOR vbak-vkorg, " Sales organization
s_kunnr FOR vbak-kunnr, " Sold-to party
s_vbeln FOR vbak-vbeln. " Sales document
SELECTION-SCREEN :
SKIP, BEGIN OF LINE,COMMENT 5(27) v_1 FOR FIELD p_max.
PARAMETERS p_max(2) TYPE n DEFAULT '20' OBLIGATORY.
SELECTION-SCREEN END OF LINE.
DATA:
BEGIN OF gt_vbak OCCURS 0,
vkorg LIKE vbak-vkorg, " Sales organization
kunnr LIKE vbak-kunnr, " Sold-to party
vbeln LIKE vbak-vbeln, " Sales document
netwr LIKE vbak-netwr, " Net Value of the Sales Order
waerk LIKE vbak-waerk, " Document currency
END OF gt_vbak.
INITIALIZATION.
v_1 = 'Maximum of records to read'.
START-OF-SELECTION.
PERFORM f_read_data.
PERFORM f_display_data.
* Form f_read_data
FORM f_read_data.
SELECT * INTO CORRESPONDING FIELDS OF TABLE gt_vbak
FROM vbak
UP TO p_max ROWS
WHERE kunnr IN s_kunnr
AND vbeln IN s_vbeln
AND vkorg IN s_vkorg.
ENDFORM. " F_READ_DATA
* Form f_display_data
FORM f_display_data.
DEFINE m_fieldcat.
add 1 to ls_fieldcat-col_pos.
ls_fieldcat-fieldname = &1.
ls_fieldcat-ref_tabname = 'VBAK'.
ls_fieldcat-do_sum = &2.
ls_fieldcat-cfieldname = &3.
append ls_fieldcat to lt_fieldcat.
END-OF-DEFINITION.
DEFINE m_sort.
add 1 to ls_sort-spos.
ls_sort-fieldname = &1.
ls_sort-up = 'X'.
ls_sort-subtot = &2.
append ls_sort to lt_sort.
END-OF-DEFINITION.
DATA:
ls_fieldcat TYPE slis_fieldcat_alv,
lt_fieldcat TYPE slis_t_fieldcat_alv,
lt_sort TYPE slis_t_sortinfo_alv,
ls_sort TYPE slis_sortinfo_alv,
ls_layout TYPE slis_layout_alv.
m_fieldcat 'VKORG' '' ''.
m_fieldcat 'KUNNR' '' ''.
m_fieldcat 'VBELN' '' ''.
m_fieldcat 'NETWR' 'X' 'WAERK'.
m_fieldcat 'WAERK' '' ''.
m_sort 'VKORG' 'X'. " Sort by vkorg and subtotal
m_sort 'KUNNR' 'X'. " Sort by kunnr and subtotal
m_sort 'VBELN' ''. " Sort by vbeln
ls_layout-cell_merge = 'X'.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
is_layout = ls_layout
it_fieldcat = lt_fieldcat
it_sort = lt_sort
TABLES
t_outtab = gt_vbak.
ENDFORM. " F_DISPLAY_DATA
***************** END OF PROGRAM Z_DEMO_ALV_SORT **********************
Regards
Sudheer -
Display the total number of rows for the report in OBIEE 11g
Hi, In obiee 11g, the pagination will be 1-25. Is there any possiblity in obiee to show the total rows count next to pagination. Ex: if the result contains 120 rows. it should display after the pagination
Records 1-25. Total of Records : 120
Is there any way we can display the total number of rows for the report.
Kindly help me.. Its very urgent requirement.
MAny Thank in advacneCheck this http://obiee100.blogspot.com/2011/07/display-total-number-of-records-in.html
and
http://docs.oracle.com/cd/E28280_01/bi.1111/e10544/appsql.htm#CHDCDIDA
You have to go something like as suggested in previous link.
Mark as correct/helpful -
I'm new to GB and I'm trying to record solo vocal with a backing track. I can get the track running OK but I can't seem to record. I think when I press record the backing track mutes and I need it running.. Thanks in advance!
guess what it says java file. So yes i'm sure. Sarcasm. Not the best way to encourage a total stranger to help you. Then there's
Sorry if i wasn't more clear but was that response needed?No it wasn't needed, but I'm not the one asking for help so I have the luxury of not worrying too much about it. It's extremely frustrating trying to drag relevant information out of someone, and makes one less inclined to bother.
Anyways, there's still nothing in this thread that actually explicitly says "there is a file called VolcanoApp.java in the directory where I'm running javac from" and I really can't be bothered banging my head against the wall any longer. You've made a silly mistake, or a false assumption. We all do it from time to time. My advice is, take a break, go for a walk and re-visit this in a while. You'll probably spot the mistake right away.
Maybe you are looking for
-
Hi All, One of my friends has completed training in PL/SQL programming. He wants some hands on projects so that he can work on that and gain confidence. So that he can get into full fledge career in PL/SQL programming. Can any one give me some insigh
-
Error while Creating ar invoice
hi when i was creating a ar invoice by copying from delivery i got an error msg from sap software as sapbussinessone_20070821154722.dmp file has created. can any one can help in this regard firstly what is that error means and what that .dmp file mea
-
How to convert COLUMN_WID to date format mm/dd/yyy
Hi Experts, How do I convert the COLUMN_WID (ex. 20121120) to date format mm/dd/yyy (ex. 11/20/2012) using the RPD in BMM Layer? Hope that I convey my questions clearly. Thanks,
-
Hello list, I am searching for the jar file for edu.sinica.iis.cscl.util.IniFile for this clas sbut after lot of google i din't found any so if anyone here can help for this will be appreciable. thanks in advance Regards bharat
-
Weird acting in Device Manager
So my previous post didn't bear much fruit, but hopefully this new info i discovered can help solving my problem. Here's my situation. I'm using this Iphone 3g for the first time, meaning i need to connect to Itunes in order to activate it. Unfortuna