Validating forms using check boxs
hi i am trying to validate a form using check boxs where all of the elements have the same name. Using the code below it enables validation when only one check box is available, however with muliple check-boxs it goes into and eternal loop and never executes the code! Any help on this matter would be most appreciated.
<SCRIPT language="javaScript">
function validate()
if (!document.myform.pkey.checked)
alert("Please Select a Questionnaire to delete!!");
return false;
</SCRIPT>
Hi,
When you have multiple checkboxes with same name, it will form an array of check boxes. So you have to validate them as below.
flag=0;
if(chkcntr>1)
for(i=0;i<frm.ch.length;i++)
if(frm.ch.checked)
flag=1;
break;
else
if(frm.ch.checked)
flag=1;
if(flag==1)
//checkbox selected,can give any action
else
// checkbox not selected,give alert
Similar Messages
-
How to use check box & dropdownlist in smart forms
can anybdy explain(any examples) how i can use check box or drop down list in smart forms.is ther any provision like that
Hi Ranjith,
To use Check box in smartform do the following:
Change the editor to 'PC Editor' and take the menu.
in text editor of TEXT ELEMENTS..
Insert -> Characters -> SAP Symbols
in print preview u can't see these changes..
for more details check this link..
How to create checkbox in smartforms??
Ashven -
Use check box for report and form
Hi Expert,
I try to use check box to select multiple rows in a report and then click on a button to go to a form on another page to choose some values from the form and then do a mass update for records selected in reports.
I read the "How to Work with Check Boxes" in 2 Day Developer guide, it works fine to select mutiple rows in report and do update with process in that report page.
However, if I click on a button to go to another page which contains a form, seems the values stored in the package array are cleared and not passed to that page.
Do you know how I could make this work?
Thanks a lot,
JessieHello Sakti,
I am also in ECC6.0 & if i see the definition of the BAdI BADI_TAX1_XTXIT_SET, "Multiple Use" checkbox is checked! What are you trying to do - trying to create an implementation?
@Prabhu: Although the BAdI is "multiple-use", but there is not filter applied to it. Next time do your checks properly before replying
BR,
Suhas -
Using check boxes appear as a "tick" and I want a "X"
Hi guys - new user to Adobe Forms (MAC Adobe Acrobat XI) - I have used check boxes in my first form however when I check them they appear as a "tick" and I want a "X" - I went to the properties section and tried all the options (circle, etc) but it always came back as a tick - any suggestions?
Thanks George - whilst I've used Dropbox for a couple of years now this is the first time I have shared a file (which you should have received directly to your email - I'm sorry to say I wasn't sure how to post the link in this forum! (once again a bit clueless on my part)
Interesting however since I tested the process by sending to my work PC (WIN7) and the boxs have crosses in them! so the problem appears to be with my set up on my home mac (OSX 10.9.4). Really I should have thought to do this first before asking!
Any thoughts?
Cheers -
Help getting a form with check box capabilities?
Hi all,
I built a new site using Muse, which I am very happy with so far, but I am finding the forms a bit limiting. The previous website, which I am replacing with the new muse site, was built using Dreamweaver. The old site had a form with check boxes and it pointed to a PHP directory. Is there a way to acheive the same results in Muse? Either a form widget update (without having to use BC), or a simple way to configure Muse to interact with my PHP directory? I'm not a coder, but I can manage some light work.
Any help would be greatly appreciated.
Thanks!Thanks Morgan! Jotform is in the realm of possiblities; however, the company the site is for has a very strict privacy policy, which might be a concern when looking at free form builders. I should have mentioned that before.
I beleive the best way to acheive what I'm trying to do is by linking the existing PHP directory to the new Muse site. The existing form built in Dreamweaver works fine, I just need to get the same form to work in Muse. Is there a way to do that? -
How to use check box in flash 8?
How to use check box in flash 8?
If you want it to happen when someone clicks the checkbox, then you need to add a listener for that event.
var cbListener:Object = new Object();
cbListener.click = function (evt:Object) {
if (cb.selected) {
gotoAndStop(2);
cb.addEventListener("click", cbListener);
(Note: "cb" and "cbListener" are names that were made up for this example. They could be anything you want to name them) -
H ow we use check boxes in report
how we use check boxes in report(alv,intrective)
Hi,
In the basic list we will display the Check box, once the check box is clicked then the recrod information should be displayed in the secondary list. so we will give the Check box for every reocrd then what ever we select the checkboxes. then we shoild provide the info of those records
Reports with checkbox
Regards
Sudheer -
How to display another window by using Check box
Hi Friends,
I have one doubt in Webdynpro with java. How to display another window by using Check box?
For Exam My requirement is I am getting BAPI from ECC System. So I have to go given input details in first view and output details in Second View. So in Second View I will taken Table that data will displayed in rows. each and every row first check box is available.
Here Select Check Box of particular row then click Edit button. That row data will be displayed in one popup window.
empid, name, sal ,firstname, last Name
empid, name, sal ,firstname, last Name
empid, name, sal ,firstname, last Name
Suppose I have to select check box in First Row Click on EDIT button That row data will be displayed in another popup window here customer will change details depending up requirement click on SAVE Button that update data will saved in ECC System.
How to display another window by using Check box?
Regards
VijayHi Vijay
Your question is not clear enough to give an answer. Do you have some difficulties with the code for opening a popup-window? There are many-many examples in the forum how to open/close a popup.
Or you do not know how to bind the popup opening with clicking a check box? Just put the code in the onSelect event handler of the check box.
BR, Siarhei
Edited by: Siarhei Pisarenka on Mar 11, 2010 10:55 AM -
Unable to check multiple use check box for BADI
Hi,
In ECC 6.0, when I am trying to activate the multiple use check box ( For multiple implementation of BADI ) , it is not allowed me the same.
Throwing the error as - interface IF_EX_TAX1_XTXIT_SET can not be used.
BADI name - BADI_TAX1_XTXIT_SET
Can anyone pls help me how to do this.
Thanks,
ShaktiHello Sakti,
I am also in ECC6.0 & if i see the definition of the BAdI BADI_TAX1_XTXIT_SET, "Multiple Use" checkbox is checked! What are you trying to do - trying to create an implementation?
@Prabhu: Although the BAdI is "multiple-use", but there is not filter applied to it. Next time do your checks properly before replying
BR,
Suhas -
How to save the session states for a tabular form WITHOUT using check boxs?
Greeting guys,
As you know that we can use collections to save the session states of a tabular forms, described in the how-to doc of manual tabular forms. However, what I am trying to do ( or have to do) is to provide a manual tabular form, and save the session states for validation, without using the check boxes. Because a user can put contents into some columns in a row without checking the corresponding checkbox, according to the requirements. So basically what I tried is to loop over all the rows and save Every entry into a collection. However, sometimes I got "no data found" error with unknown reasons.
My current solution is to use the "dirty" Retry button that gets back the history, which IMO is not a good workabout. So, I'd appreciate if somebody can shed some light on a better solution, especially if it is close to the one in that how-to doc.
Thanks in advance.
LucThe following is the first collection solutin I've tried:
htmldb_collection.create_or_truncate_collection('TEMP_TABLE');
for i in 1..p_row_num loop -- Loop on the whole form rows
if (htmldb_application.g_f01(i) is not null) or (htmldb_application.g_f05(i) <> 0)
--If either of them has some input values, the row should be saved into the colleciton.
then
htmldb_collection.add_member(
p_collection_name => 'TEMP_TABLE',
p_c001 => htmldb_application.g_f01(i),
p_c002 => htmldb_application.g_f03(i),
p_c003 => htmldb_application.g_f04(i),
p_c004 => htmldb_application.g_f05(i),
p_c005 => htmldb_application.g_f06(i),
p_c006 => htmldb_application.g_f08(i)
end if;
end loop;
Some of columns have null values, but I don't think that's the reason. Because once I clicked all the check boxes, there would be no error no matter what values were in other columns.
Another issue would be extract the values FROM the collection, which has been tried because I had problem to store the data into the collection. I used "decode" functions inside the SQL to build the tabular form. I am not sure whether it will be the same as a regular SQL for a tabular form, like the example in the How-to doc.
Also I didn't use the checksum, for it is not an issue at the current stage. I am not sure whether that's the reason which caused the NO DATA FOUND error. -
Selection using check box in std ALV grid!
Hi all,
I have written a custom report to show the O/p in ALV grid.
This is my code:
TABLES :zpo_loi.
TYPE-POOLS : slis.
TYPE-POOLS: icon.
TABLES : sscrfields.
DATA : ls_composer TYPE ssfcompop,
ls_control TYPE ssfctrlop.
DATA : wa_return TYPE TABLE OF bapiret2 ,
wa_address TYPE bapiaddr3.
DATA : wa_crmd_orderadm_h TYPE zpo_loi,
it_po TYPE TABLE OF crmd_orderadm_h,
wa_po TYPE bbp_pds_header.
DATA : it_tab TYPE TABLE OF zpo_loi.
DATA : it_data TYPE TABLE OF crmd_orderadm_h,
wa_data TYPE bbp_pds_header,
et_data TYPE bbps_sf_po_output.
DATA : w_formname TYPE tdsfname ,
w_sfname TYPE rs38l_fnam.
DATA :it_po_no TYPE TABLE OF select_be_obj_id,
wa_it_po_no LIKE LINE OF it_po_no.
DATA :r_itab TYPE ddshretval OCCURS 0.
DATA : it_output LIKE TABLE OF zloi,
wa_output TYPE zloi.
DATA : w_answer TYPE c.
DATA : g_repid LIKE sy-repid,
g_title TYPE lvc_title,
g_set_pf_stat TYPE slis_formname VALUE 'SET_PF_STATUS',
g_user_command TYPE slis_formname VALUE 'USER_COMMAND',
g_layout TYPE slis_layout_alv,
g_print_alv TYPE slis_print_alv,
g_variant LIKE disvariant,
c_char_a(1) VALUE 'A',
c_char_x(1) VALUE 'X',
itab_alv_sort TYPE slis_t_sortinfo_alv,
itab_alv_fcat TYPE slis_t_fieldcat_alv.
* Internal tables Begin with IT_ *
DATA : it_fcat TYPE slis_t_fieldcat_alv, "---ALV
it_disp TYPE TABLE OF zloi.
* Work Area for Internal tables Begin with WA_ *
DATA : wa_fcat TYPE slis_fieldcat_alv , "---ALV
wa_layout TYPE lvc_s_layo, "---ALV
wa_it_disp LIKE LINE OF it_disp.
DATA : it_sf_po TYPE TABLE OF crmd_orderadm_h,
wa_sf_po TYPE bbp_pds_header.
*SELECTION-SCREEN:
* BEGIN OF SCREEN 500 AS WINDOW TITLE title,
* END OF SCREEN 500.
*DATA : functxt TYPE smp_dyntxt.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
SELECT-OPTIONS sel_po FOR zpo_loi-zobject_id.
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.
PARAMETERS : pr_loi RADIOBUTTON GROUP grp1 USER-COMMAND ucom,
pr_fondo RADIOBUTTON GROUP grp1.
SELECTION-SCREEN END OF BLOCK b2.
* At selection-screen output *
AT SELECTION-SCREEN OUTPUT.
IF pr_fondo = 'X'.
REFRESH sel_po.
LOOP AT SCREEN.
IF screen-name = text-003 OR screen-name = text-004.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSEIF pr_loi = 'X'.
LOOP AT SCREEN.
IF screen-name = text-003 OR screen-name = text-004.
screen-input = '1'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
* At selection-screen on radiobutton *
AT SELECTION-SCREEN ON RADIOBUTTON GROUP grp1.
IF pr_fondo = 'X'.
REFRESH sel_po.
LOOP AT SCREEN.
IF screen-name = text-003 OR screen-name = text-004.
screen-input = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSEIF pr_loi = 'X'.
LOOP AT SCREEN.
IF screen-name = text-003 OR screen-name = text-004.
screen-input = '1'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR sel_po-low.
PERFORM populate_table.
PERFORM f4_help.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR sel_po-high.
PERFORM populate_table.
PERFORM f4_help.
* At selection-screen *
AT SELECTION-SCREEN.
*---CHECKING THE INPUT >>>
IF sy-ucomm = 'ONLI'.
PERFORM f002-check_input.
PERFORM f001-check.
ENDIF.
*& Form POPULATE_TABLE
* text
* --> p1 text
* <-- p2 text
FORM populate_table .
SELECT zobject_id
description
FROM zpo_loi
INTO CORRESPONDING FIELDS OF TABLE it_tab.
SORT it_tab BY zobject_id ASCENDING.
ENDFORM. " POPULATE_TABLE
*& Form F4_HELP
* text
* --> p1 text
* <-- p2 text
FORM f4_help .
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
ddic_structure = ' '
retfield = 'ZOBJECT_ID'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'A'
value_org = 'S'
TABLES
value_tab = it_tab
return_tab = r_itab.
ENDFORM. " F4_HELP
*& Form F001-CHECK
* text
* --> p1 text
* <-- p2 text
FORM f001-check .
IF pr_fondo = 'X'.
PERFORM display_expiring_fondos.
ELSEIF pr_loi = 'X'.
PERFORM fetch_po_det.
PERFORM build_fcat.
PERFORM alv_display.
ENDIF.
ENDFORM. " F001-CHECK
*& Form F002-CHECK_INPUT
* text
* --> p1 text
* <-- p2 text
FORM f002-check_input .
IF pr_loi = 'X'.
REFRESH it_po.
IF sel_po-low IS NOT INITIAL.
SELECT object_id
FROM crmd_orderadm_h
INTO CORRESPONDING FIELDS OF TABLE it_po
WHERE object_type = 'BUS2201'
AND object_id = sel_po-low.
IF sy-subrc NE 0.
IF sel_po-high IS NOT INITIAL.
SELECT object_id
FROM crmd_orderadm_h
INTO CORRESPONDING FIELDS OF TABLE it_po
WHERE object_type = 'BUS2201'
AND object_id = sel_po-high.
IF sy-subrc NE 0.
MESSAGE e009(zsrm).
ENDIF.
ENDIF.
MESSAGE e007(zsrm).
ENDIF.
ELSE.
MESSAGE e010(zsrm).
ENDIF.
IF sel_po-high IS NOT INITIAL.
SELECT object_id
FROM crmd_orderadm_h
INTO CORRESPONDING FIELDS OF TABLE it_po
WHERE object_type = 'BUS2201'
AND object_id = sel_po-high.
IF sy-subrc NE 0.
MESSAGE e008(zsrm).
ENDIF.
ENDIF.
ENDIF.
ENDFORM. " F002-CHECK_INPUT
*& Form FETCH_PO_DET
* text
* --> p1 text
* <-- p2 text
FORM fetch_po_det .
REFRESH it_po.
it_po_no[] = sel_po[].
DATA : w_count TYPE i,
w_lines TYPE c,
wa_header TYPE bbp_pds_po_header_d.
REFRESH : it_po,it_output.
IF sel_po-high IS NOT INITIAL.
SELECT object_id
description
posting_date
created_by
FROM crmd_orderadm_h
INTO CORRESPONDING FIELDS OF TABLE it_po
WHERE object_type = 'BUS2201'
AND object_id BETWEEN sel_po-low AND sel_po-high.
ELSE.
SELECT object_id
description
posting_date
created_by
FROM crmd_orderadm_h
INTO CORRESPONDING FIELDS OF TABLE it_po
WHERE object_type = 'BUS2201'
AND object_id = sel_po-low.
ENDIF.
w_lines = sy-dbcnt.
w_count = 1.
DO.
IF w_count LE w_lines.
READ TABLE it_po INTO wa_po INDEX w_count.
MOVE wa_po-object_id TO wa_output-zzpono.
MOVE wa_po-description TO wa_output-zzpodesc.
MOVE wa_po-posting_date TO wa_output-zzpodate.
MOVE wa_po-created_by TO wa_output-zzpocreator.
CALL FUNCTION 'BBP_PD_PO_GETDETAIL'
EXPORTING
i_object_id = wa_output-zzpono
IMPORTING
e_header = wa_header.
CALL FUNCTION 'BAPI_USER_GET_DETAIL'
EXPORTING
username = wa_output-zzpocreator
IMPORTING
address = wa_address
TABLES
return = wa_return.
CLEAR wa_output-zzpocreator.
CONCATENATE wa_address-firstname ' ' wa_address-lastname INTO wa_output-zzpocreator .
MOVE wa_header-total_value TO wa_output-zzpoval.
MOVE wa_header-currency TO wa_output-zzpocur.
APPEND wa_output TO it_output.
w_count = w_count + 1.
ELSE.
EXIT.
ENDIF.
ENDDO.
ENDFORM. " FETCH_PO_DET
*& Form BUILD_FCAT
* text
* --> p1 text
* <-- p2 text
FORM build_fcat .
g_repid = sy-repid.
g_title = 'Print LOI details'.
g_print_alv-no_print_listinfos = 'X'.
g_variant-report = sy-repid.
g_variant-variant = sy-title.
CLEAR g_layout.
g_layout-f2code = ' '.
wa_layout-zebra = 'X'.
g_layout-flexible_key = 'X'.
g_layout-colwidth_optimize = 'X'.
g_layout-detail_initial_lines = 'X'.
g_layout-box_fieldname = 'ZZCHECK'.
REFRESH it_fcat.
*Po no
CLEAR wa_fcat.
wa_fcat-fieldname = 'ZZPONO' .
wa_fcat-tabname = 'IT_DISP'.
wa_fcat-seltext_m = 'Purchase Order'.
*wa_fcat-seltext_s = 'Purchase Order.
wa_fcat-icon = 'X'.
wa_fcat-col_pos = '2'.
wa_fcat-outputlen = 10.
APPEND wa_fcat TO it_fcat.
*Description
CLEAR wa_fcat.
wa_fcat-fieldname = 'ZZPODESC' .
wa_fcat-tabname = 'IT_DISP'.
*wa_fcat-seltext_l = 'Description'.
wa_fcat-seltext_m = 'Description'.
*wa_fcat-seltext_s = 'Description'.
wa_fcat-col_pos = '3'.
wa_fcat-outputlen = 10.
APPEND wa_fcat TO it_fcat.
*Posting date
CLEAR wa_fcat.
wa_fcat-fieldname = 'ZZPODATE' .
wa_fcat-tabname = 'IT_DISP'.
wa_fcat-seltext_l = 'Posting Date'.
wa_fcat-seltext_m = 'Posting Date'.
*wa_fcat-seltext_s = 'Posting Date'.
wa_fcat-col_pos = '4'.
wa_fcat-outputlen = 8.
APPEND wa_fcat TO it_fcat.
*value
CLEAR wa_fcat.
wa_fcat-fieldname = 'ZZPOVAL' .
wa_fcat-tabname = 'IT_DISP'.
*wa_fcat-seltext_l = 'PO value'.
wa_fcat-seltext_m = 'PO value'.
*wa_fcat-seltext_s = 'PO value'.
wa_fcat-col_pos = '5'.
wa_fcat-outputlen = 15.
wa_fcat-no_zero = 'X'.
APPEND wa_fcat TO it_fcat.
*Currency
CLEAR wa_fcat.
wa_fcat-fieldname = 'ZZPOCUR' .
wa_fcat-tabname = 'IT_DISP'.
*wa_fcat-seltext_l = 'PO Currency'.
wa_fcat-seltext_m = 'PO Currency'.
*wa_fcat-seltext_s = 'PO Currency'.
wa_fcat-col_pos = '6'.
wa_fcat-outputlen = 5.
APPEND wa_fcat TO it_fcat.
*Creator
CLEAR wa_fcat.
wa_fcat-fieldname = 'ZZPOCREATOR' .
wa_fcat-tabname = 'IT_DISP'.
*wa_fcat-seltext_l = 'Buyer'.
wa_fcat-seltext_m = 'Buyer'.
*wa_fcat-seltext_s = 'Buyer'.
wa_fcat-col_pos = '7'.
wa_fcat-outputlen = 12.
APPEND wa_fcat TO it_fcat.
ENDFORM. " BUILD_FCAT
*& Form ALV_DISPLAY
* text
* --> p1 text
* <-- p2 text
FORM alv_display .
SORT it_output BY zzpono.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = g_repid
i_callback_pf_status_set = g_set_pf_stat
i_callback_user_command = g_user_command
i_grid_title = g_title
is_layout = g_layout
it_fieldcat = it_fcat[]
is_variant = g_variant
is_print = g_print_alv
TABLES
t_outtab = it_output[]
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
ENDIF.
ENDFORM. " ALV_DISPLAY
*& Form user_command
* text
* -->R_UCOMM text
* -->RS_SELFIELD text
FORM user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield. "#EC CALLED
DATA: gd_repid LIKE sy-repid, "Exists
ref_grid TYPE REF TO cl_gui_alv_grid.
IF ref_grid IS INITIAL.
CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
IMPORTING
e_grid = ref_grid.
ENDIF.
IF NOT ref_grid IS INITIAL.
CALL METHOD ref_grid->check_changed_data .
ENDIF.
rs_selfield-refresh = 'X'.
CASE r_ucomm.
WHEN 'PRINTLOI'.
PERFORM call_sf.
WHEN 'BACK'.
CALL SELECTION-SCREEN 1000.
WHEN 'CANCEL'.
CALL SELECTION-SCREEN 1000.
WHEN 'EXIT'.
CALL SELECTION-SCREEN 1000.
ENDCASE.
ENDFORM. "user_command
*& Form set_pf_status
* text
* -->RT_EXTAB text
FORM set_pf_status USING rt_extab TYPE slis_t_extab.
SET PF-STATUS 'ZALV' EXCLUDING rt_extab.
SET TITLEBAR 'ZALV'.
ENDFORM. "set_pf_status
*& Form CALL_SF
* text
* --> p1 text
* <-- p2 text
FORM call_sf .
REFRESH it_sf_po.
LOOP AT it_output INTO wa_output WHERE zzcheck = 'X'.
wa_sf_po-object_id = wa_output-zzpono.
APPEND wa_sf_po TO it_sf_po.
ENDLOOP.
w_formname = 'ZSR_EBP_DOCU_LETTEROFINTENT1'.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = w_formname
IMPORTING
fm_name = w_sfname
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc <> 0.
ENDIF.
ls_composer-tdnewid = 'X'.
ls_control-no_dialog = 'X'.
LOOP AT it_sf_po INTO wa_sf_po.
CALL FUNCTION w_sfname
EXPORTING
control_parameters = ls_control
output_options = ls_composer
wa_object = wa_sf_po
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc <> 0.
ENDIF.
ENDLOOP.
ENDFORM. " CALL_SF
*& Form DISPLAY_EXPIRING_FONDOS
* text
* --> p1 text
* <-- p2 text
FORM display_expiring_fondos .
SET PF-STATUS 'ZLOI'.
SET TITLEBAR 'ZLOI'.
TYPES : BEGIN OF ty_output1,
guid TYPE bbp_guid,
object_id TYPE crmt_object_id_db,
description TYPE crmt_process_description,
posting_date TYPE crmt_posting_date,
zzfondo_dat TYPE zfondo_dat,
created_by TYPE crmt_created_by,
END OF ty_output1.
DATA : it_output1 TYPE TABLE OF ty_output1,
wa_output1 TYPE ty_output1,
w_lines,
w_count,
it_fondo TYPE TABLE OF zsr_fondo,
it_temp_fondo TYPE TABLE OF zsr_fondo,
wa_temp_fondo TYPE zsr_fondo,
wa_fondo TYPE zsr_fondo,
w_diff TYPE p,
wa_header1 TYPE bbp_pds_po_header_d.
CONSTANTS : c_otype(8) VALUE 'BUS2201'.
REFRESH : it_output1,it_temp_fondo,it_fondo.
SELECT b~zzfondo_dat
a~guid
a~object_id
a~description
a~posting_date
a~created_by
INTO CORRESPONDING FIELDS OF TABLE it_output1
FROM bbp_pdhsc AS b
LEFT OUTER JOIN crmd_orderadm_h AS a ON b~guid = a~guid
AND a~object_type = c_otype.
LOOP AT it_output1 INTO wa_output1.
CALL FUNCTION '/SDF/CMO_DATETIME_DIFFERENCE'
EXPORTING
date1 = sy-datum
date2 = wa_output1-zzfondo_dat
IMPORTING
datediff = w_diff
EXCEPTIONS
invalid_datetime = 1
OTHERS = 2.
IF sy-subrc <> 0.
ENDIF.
IF w_diff <= '7'.
wa_temp_fondo-zzpono = wa_output1-object_id.
APPEND wa_temp_fondo TO it_temp_fondo.
ENDIF.
ENDLOOP.
*select the final entries for PO whose FONDO is expiring
DESCRIBE TABLE it_temp_fondo LINES w_lines.
w_count = 1.
DO.
IF w_count LE w_lines.
READ TABLE it_temp_fondo INTO wa_temp_fondo INDEX w_count.
IF sy-subrc = 0.
CALL FUNCTION 'BBP_PD_PO_GETDETAIL'
EXPORTING
i_object_id = wa_temp_fondo-zzpono
IMPORTING
e_header = wa_header1.
wa_fondo-zzpono = wa_temp_fondo-zzpono.
wa_fondo-zzpodesc = wa_header1-description.
wa_fondo-zzpodate = wa_header1-posting_date.
wa_fondo-zzexpdate = wa_header1-zzfondo_dat.
wa_fondo-zzpoval = wa_header1-total_value.
wa_fondo-zzpocur = wa_header1-currency.
wa_fondo-zzpocreator = wa_header1-created_by.
CLEAR : wa_address.
REFRESH wa_return.
CALL FUNCTION 'BAPI_USER_GET_DETAIL'
EXPORTING
username = wa_header1-created_by
IMPORTING
address = wa_address
TABLES
return = wa_return.
CLEAR wa_fondo-zzpocreator.
CONCATENATE wa_address-firstname ' ' wa_address-lastname INTO wa_fondo-zzpocreator .
w_count = w_count + 1.
APPEND wa_fondo TO it_fondo.
ENDIF.
ELSE.
EXIT.
ENDIF.
ENDDO.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_structure_name = 'ZSR_FONDO'
i_grid_title = 'EXPIRING FONDOS'
TABLES
t_outtab = it_fondo[]
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
ENDIF.
ENDFORM. " DISPLAY_EXPIRING_FONDOS
Now in my ALV grid o/p i can see the check box but if i select one row and then try to select another the first one gets deselected.
Can anybody tell me what is missing?Hi,
Try like changing this
insted of
g_layout-f2code = ' '.
use this
g_layout-f2code = 'DISP'. " Sets fcode for when double
and
g_layout-f2code = '&ETA'. " it will display POPUP screen
Best Regards
Ranga
Edited by: Ranga Swamy on Nov 1, 2008 11:07 PM
Edited by: Ranga Swamy on Nov 1, 2008 11:17 PM -
Update database using check boxes
I have a query region that produces a checkbox and an associated line with the checkbox. The data in the database that is a "Y", produces a checked box.
select check_box_seq,
htmldb_item.checkbox(1,is_it_checked,decode(is_it_checked,'Y','CHECKED')) D,
check_box_text R
from check_box_tbl
What I need to happen is to change one or more check boxes. I have a MultiRow Update process, with a process point of On Submit - After Computations and Validations with a PL/SQL conditional processing of:
FOR I in 1.. HTMLDB_APPLICATION.F_F01.COUNT LOOP
update table check_box_tbl set is_it_checked = Y
where check_box_seq = htmldb_item.application.g_f01(i);
END LOOP;
But the data in the database does not change. I have read numerous discussion on this thread but I have not found exactly what I need or can not recognize it.
How can I get the data in the database to change when I either change a checked box or after I have changed all boxes and then press the SUBMIT.I am having a similar problem that I cannot find the answer to. (See my process below). I don't think that the process is "grabbing" the checked values in the SDN column. It is using NULL, so therefore no rows are being inserted in the table. Shg_id and SDN are both primary keys in this table, so I need to insert both. Shg_id has an assigned value already.
My process is this:
DECLARE
l_selected HTMLDB_APPLICATION_GLOBAL.VC_ARR2;
BEGIN
l_selected := HTMLDB_UTIL.STRING_TO_TABLE(:P312_SDN);
FOR i IN 1..l_selected.count
LOOP
INSERT INTO shgm (Shg_id, SDN)
VALUES (:P312_Shg_id, l_selected (i));
END LOOP;
END; -
How do I list product details using check boxes to save having to write the same info over and o
Hi there
First of all
Happy New Year and I hope everyone is well all the best for the future
Now...... back to the point
What I want to do is........
I am making a jewelry ... necklace... shopping site for my girlfriend.... well.... my wife in two weeks.... This site has been a loooong time coming.... I am still not happy with it so it still not public.... but is working ok She very upset it taking more than a year.... but I am still learning and I always want it better
Anyway
I have hundreds of Necklace details to enter..... i thought it would be easy but it is very tmie consuming...... So ...
The necklaces are made from different kinds of stones.... turquoise .. agate ... and about a hundred more different kinds of stones
In my add product form I have a field for entering product details..... to enter the different kinds of stones the necklaces are made from..... sometimes more than twenty for one necklace..... So what I want to do is have check boxes... or radio boxes to choose what stones to add to the description..... So I can have a list of about fifty different kinds of stones all with a check box next to them so that when you choose a box that stone name would appear in the product description
Sounds easy but I can't figure out how to do it.....
I think I need a different table in my database a 'stone_neck' field to store all the stone names.... about 50 fields..... .... with an id field and a name field and maybe a display field ....... I think
Does that sound correct.......?
If so then how do I display the details in a field in a table in my product detail page? I think I need a recordset on my detail page that gets all the stone names.... but how do I display the names of the stones that I have checked in the addprod form ? Do I need to put all every one of the stone info from the bindings panel? and then show region if .......
i am confused
If anyone has any ideas it would be great
Have a great dayMaybe you can take tips by visiting sites of prominent jewelry brands like Tiffany to get some ideas of how to structure your product list details.
Just a thought.
Mahadevan
www.wheretobuyringsnow.com -
How to use check box in SQL Query
Hi
I have a reagion with check boxes. Now I am creating another region which is
PL/SQL function/block returning query.
here' the block. When I save it give me error
Query cannot be parsed within the Builder. If you believe your query is syntactically correct, check the ''generic columns'' checkbox below the region source to proceed without parsing. ORA-00900: invalid SQL statement
Here is the code
DECLARE
p_str VARCHAR2(2000);
p_col_name varchar2(100);
p_flg char(1);
BEGIN
p_flg := 'N';
for i in 1 .. htmldb_application.g_f01.count
LOOP
p_flg := 'Y';
p_col_name := htmldb_application.g_f01(i);
IF i = 1
THEN
p_str := 'SELECT ' || p_col_name;
ELSE
p_str := p_str || ', ' || p_col_name;
END IF;
END LOOP;
p_str := p_str || ' FROM UALDBA_V';
RETURN p_str;
END;
Please advice
SunilSunil - The htmldb_application.g_fxx arrays are empty during page rendering. A query cannot be generated using them.
Scott -
How to get selected row values in a table using check box
Hi ADF Experts,
JDEV Version 11.1.1.7.0
My requirement is getting the selected row valuesof a af:table using a checkbox(multi select).
Thanks,
AnimeshHi,
add a transient attribute to the POJO entity and update this through a check box. The ensure you have autosubmit=true set on the check box. In a value change listener set or remove the row's checbox attribute value
Frank
Maybe you are looking for
-
Error in starting Adobe Bridge in Photoshop CS2
I've just installed Photoshop CS2, however upon opening Adobe Bridge this error message appears " The application has failed to start because libagluc28.dll was not found. Reinstalling to application may fix the problem" I have reinstalled and click
-
Problem with minimize and maximize of the AIR WIndow
If I execute the below code I will get an window with 100 buttons. With vertical scrolling on. If I bring the vertical scroll down say positioned at some button. Minimize it using minimize button and maxmize it . The vertical scroll position is reset
-
Changes made in Camer Raw are not visible in Bridge
I'm editing the RAW images in Camera raw started from Bridge (Ctr- R). By returning to Bridge with "done" the changes are not visible. This worked until recently. s there any setting which prevents Bridge taking in consideration the info from the XMP
-
I hate itunes! I am beginning to hate my Ipad!
It freezes my PC, wont recognize my Ipad, wont sync with my Ipad... I have reinstalled/uninstalled it but still wont fix the **** problem! Itunes then just installed an update and now it wont even run with the update! What is going on!!!!!! What i
-
I run Arch on my Thinkpad T41p (ATI video card, 1400x1050 screen), its not a fast new laptop but its not bad. Since i started using Arch the time to boot was something that impressed me. It was very quick to the SLiM login manager and I recon perhap