ALV REPORT: read selected checkbox in alv grid and process the pushbutton
my requirement is to check some rows from alv grid and the press the pushbutton. Thereby following things should process:
select all checked rows into an itab and call the transaction code CJ01 for all
entries......
I am finding the problem that when I select the checkbox....the internal table doesnt recognize the boxes as checked ones......
thanks in advance...
Kartikey Singh,
Data: ref1 type ref to cl_gui_alv_grid.
CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
IMPORTING
E_GRID = ref1.
call method ref1->check_changed_data.
loop at t_output where Flag = 'X'.
if t_output-VKUEGRU is initial.
message e000 with text-110.
endif.
endloop.
Similar Messages
-
Run alv report without selection screen in background
Hello Every body,
i programmed a ALV Report without selection screen, and i want to create a job for this alv report.
Any help?
Thank u.
Ouail.Hi Steve,
Can you tell me where i have to put your code?
this is my abap code:
START-OF-SELECTION.
p_filref = '\\SAPSERVER\f\SAFT\ivat\FI_Extract_1000_20140709_102346_910.XML'.
PERFORM copy_from_xml_to_itab TABLES it_ref_file
ref_xml_data
USING p_filref.
**Begin Extraction File
SUBMIT ZZ_FI_IVAT_EXTRACTOR
WITH p_bukrs EQ '1000'
WITH p_gjahr EQ '1998'
WITH filepath EQ '\\SAPSERVER\f\SAFT\iVAT_Extractie\'
WITH cldata eq space
AND RETURN.
DATA: FILE_TABLE TYPE TABLE OF SDOKPATH,
DIR_TABLE TYPE TABLE OF SDOKPATH.
CALL FUNCTION 'TMP_GUI_DIRECTORY_LIST_FILES'
EXPORTING
DIRECTORY = '\\SAPSERVER\f\SAFT\iVAT_Extractie\'
FILTER = '*.*'
TABLES
FILE_TABLE = FILE_TABLE
DIR_TABLE = DIR_TABLE
EXCEPTIONS
CNTL_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.
"get file name
LOOP AT FILE_TABLE INTO p_filref.
ENDLOOP.
CONCATENATE '\\SAPSERVER\f\SAFT\iVAT_Extractie\' p_filref INTO path.
PERFORM copy_from_xml_to_itab TABLES t_ext_file
ext_xml_data
USING path.
PERFORM fill_xml_tab_in .
perform build_fieldcatalog.
PERFORM compare_data_ref_ext.
PERFORM send_email.
perform display_alv_report.
PERFORM delete_extraction_file.
in the perform copy_from_xml_to_itab TABLES it_ref_file......, i use this code:
CREATE OBJECT gcl_xml.
*Upload XML File
CALL METHOD gcl_xml->import_from_file
EXPORTING
filename = p_filref
RECEIVING
retcode = gv_subrc.
IF gv_subrc = 0.
CALL METHOD gcl_xml->render_2_xstring
IMPORTING
retcode = gv_subrc
stream = gv_xml_string
size = gv_size.
IF gv_subrc = 0.
REFRESH gt_xml_data[].
* Convert XML to internal table
CALL FUNCTION 'SMUM_XML_PARSE'
EXPORTING
xml_input = gv_xml_string
TABLES
xml_table = gt_xml_data
return = gt_return.
ENDIF.
ENDIF. -
We are trying to implement a process so that any document that needs to be printed through our Java application will be printed as PDF using Adobe Reader. For which, We created and execute the below command line to call Adobe Reader and print the PDF on a printer."C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /T "\\<Application Server>\Report\<TEST.PDF>" "<Printer Name>". Current Situation: The above command line parameter when executed is working as expected in a User's Workspace. When executed in a command line on the Application Server is working as expected. But, the same is not working while executing it from Deployed environment.Software being used: 1. Adobe 11.0 enterprise version. 2. Webshpere Application Server 8.5.5.2. Please let us know if there is a way to enable trace logs in Adobe Reader to further diagnose this issue.
This is the Acrobat.com forum. Your question will have a much better chance being addressed in the Acrobat SDK forum.
-
I have moved my Photoshop CS5 to my traveling computer,a Surface Pro 3. I have photoshop loaded but in trying to look at raw images it says my camera raw does not support the sony alpha 65 which is what I have. I went out and tried to download the newest raw version and even went out and did a zipfile download and it will not update my current version. What should I do
I have 6.0. Tried to download newest verion and it will not download. Went out and then downloaded a zipfile and it still will not download, thus cannot look at my raw pictures.
Thanks, John
m: gener7
Sent: Thursday, December 11, 2014 6:01 PM
To: JOHN STAHLY
Subject: I have Adobe photoshop cs5. need to update camera raw, cause my camera raw is 2010and does not read my camera, I went out and downloaded the new one and it does not link to adobe photoshop cs5
I have Adobe photoshop cs5. need to update camera raw, cause my camera raw is 2010and does not read my camera, I went out and downloaded the new one and it does not link to adobe photoshop cs5
created by gener7 <https://forums.adobe.com/people/gener7> in Photoshop General Discussion - View the full discussion <https://forums.adobe.com/message/7007148#7007148> -
i cannot install adobe reader. I get so far and get the message "Error 1324. All folders or the volume is invalid. Please enter it again" can you help?
We need to know if any registry settings are causing this error. Please follow these instructions:
from Windows Start | Search: type regedit and hit Enter; you will see a window like this
now click on the little arrow ▹ left from HKEY_CURRENT_USER
Next click the arrow ▹ beside Software, then Microsoft, then Windows, then CurrentVersion, then Explorer, then click on User Shell Folders
all entries on the right side should start with %USERPROFILE%
If you have anything different, this may be the cause for the install failure.
Now you need to repeat the same thing for another key:
▹ HKEY_LOCAL_MACHINE ▹ Software ▹ Microsoft ▹ Windows ▹ CurrentVersion ▹ Explorer ▹ User Shell Folders
Here all entries should start with %PUBLIC% or %ProgramData%. If you have anything different, this may also be the cause for the install failure. -
How to read a checkbox in ALV (FM used)
Hi Experts,
I have generated an ALV grid using funtion module. There are 9 coloumns with checkbox col at first position. Each row has a checkbox. Now I want to read that particular row for which the checkbox is checked. Kindly tell me the procedure.
Points will be awarded...
Thanks,
Vishal S.Hi
1. You will have to make the field editable. In the field catalog set the EDIT = 'X' for the check box field.
2. Once the check box is checked, call the method CHECK_CHANGED_DATA of the grid in the PAI of the screen which will update the internal table. Now, you can just loop at the internal table with a where clause on the check box field.
loop at itab where checkbox = 'x'.
endloop.
same thread...
Re: Output Format for Amount in SAP Script PO
Re: Checkbox in ALV
Steps..
In the layout you need to have the BOX_FIELDNAME with a value..Let's say BOX
Declare the same value BOX in the internal table that you display in the output..
Then if the check box is selected...automatically the internal table will be filled X in the BOX column..
Check this example..
TYPE-POOLS: slis.
DATA: t_fieldcatalog TYPE slis_t_fieldcat_alv.
DATA: s_fieldcatalog TYPE slis_fieldcat_alv.
DATA: s_layout TYPE slis_layout_alv.
DATA: BEGIN OF itab OCCURS 0,
icon TYPE icon-id,
vbeln TYPE vbeln,
kunnr TYPE kunnr,
erdat TYPE erdat,
box TYPE c,
END OF itab.
DATA: v_repid TYPE syrepid.
START-OF-SELECTION.
Get the data.
SELECT vbeln kunnr erdat UP TO 100 ROWS
FROM vbak
INTO CORRESPONDING FIELDS OF TABLE itab.
IF sy-subrc <> 0.
MESSAGE s208(00) WITH 'No data found'.
LEAVE LIST-PROCESSING.
ENDIF.
Modify the record with red light.
itab-icon = '@0A@'.
MODIFY itab TRANSPORTING icon WHERE NOT vbeln IS initial.
v_repid = sy-repid.
Get the field catalog.
CLEAR: s_fieldcatalog.
s_fieldcatalog-col_pos = '1'.
s_fieldcatalog-fieldname = 'ICON'.
s_fieldcatalog-tabname = 'ITAB'.
s_fieldcatalog-seltext_l = 'Status'.
s_fieldcatalog-icon = 'X'.
APPEND s_fieldcatalog TO t_fieldcatalog.
CLEAR: s_fieldcatalog.
s_fieldcatalog-col_pos = '2'.
s_fieldcatalog-fieldname = 'VBELN'.
s_fieldcatalog-tabname = 'ITAB'.
s_fieldcatalog-rollname = 'VBELN'.
APPEND s_fieldcatalog TO t_fieldcatalog.
CLEAR: s_fieldcatalog.
s_fieldcatalog-col_pos = '3'.
s_fieldcatalog-fieldname = 'KUNNR'.
s_fieldcatalog-tabname = 'ITAB'.
s_fieldcatalog-rollname = 'KUNNR'.
APPEND s_fieldcatalog TO t_fieldcatalog.
CLEAR: s_fieldcatalog.
s_fieldcatalog-col_pos = '4'.
s_fieldcatalog-fieldname = 'ERDAT'.
s_fieldcatalog-tabname = 'ITAB'.
s_fieldcatalog-rollname = 'ERDAT'.
APPEND s_fieldcatalog TO t_fieldcatalog.
Set the layout.
s_layout-box_fieldname = 'BOX'.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_callback_program = v_repid
is_layout = s_layout
i_callback_pf_status_set = 'SET_PF_STATUS'
i_callback_user_command = 'USER_COMMAND'
it_fieldcat = t_fieldcatalog[]
TABLES
t_outtab = itab.
FORM SET_PF_STATUS *
--> EXTAB *
FORM set_pf_status USING extab TYPE slis_t_extab.
SET PF-STATUS 'TEST2'.
ENDFORM.
FORM user_command *
--> UCOMM *
--> SELFIELD *
FORM user_command USING ucomm LIKE sy-ucomm
selfield TYPE slis_selfield.
Check the ucomm.
IF ucomm = 'DETAIL'.
LOOP AT itab WHERE box = 'X'.
itab-icon = '@08@'.
MODIFY itab TRANSPORTING icon.
ENDLOOP.
ENDIF.
selfield-refresh = 'X'.
ENDFORM.
<b>Reward if usefull</b> -
CAN ANYONE PLZ TEMME HOW TO SELECT MULTIPLE RECORDS IN ALV AND EDIT THEM...........................
EG....SELECT MULTIPLE VALUES AND CHANGE D ACTIVE INDICATOR.........
THANX IN ADVANCE...........Hi,
Reprots
http://www.sapgenie.com/abap/reports.htm
http://www.allsaplinks.com/material.html
http://www.sapdevelopment.co.uk/reporting/reportinghome.htm
ALV
1. Please give me general info on ALV.
http://www.sapfans.com/forums/viewtopic.php?t=58286
http://www.sapfans.com/forums/viewtopic.php?t=76490
http://www.sapfans.com/forums/viewtopic.php?t=20591
http://www.sapfans.com/forums/viewtopic.php?t=66305 - this one discusses which way should you use - ABAP Objects calls or simple function modules.
2. How do I program double click in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=11601
http://www.sapfans.com/forums/viewtopic.php?t=23010
3. How do I add subtotals (I have problem to add them)...
http://www.sapfans.com/forums/viewtopic.php?t=20386
http://www.sapfans.com/forums/viewtopic.php?t=85191
http://www.sapfans.com/forums/viewtopic.php?t=88401
http://www.sapfans.com/forums/viewtopic.php?t=17335
4. How to add list heading like top-of-page in ABAP lists?
http://www.sapfans.com/forums/viewtopic.php?t=58775
http://www.sapfans.com/forums/viewtopic.php?t=60550
http://www.sapfans.com/forums/viewtopic.php?t=16629
5. How to print page number / total number of pages X/XX in ALV? http://www.sapfans.com/forums/viewtopic.php?t=29597 (no direct solution)
6. ALV printing problems. The favourite is: The first page shows the number of records selected but I don't need this.
http://www.sapfans.com/forums/viewtopic.php?t=64320
http://www.sapfans.com/forums/viewtopic.php?t=44477
7. How can I set the cell color in ALV? http://www.sapfans.com/forums/viewtopic.php?t=52107
8. How do I print a logo/graphics in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=81149
http://www.sapfans.com/forums/viewtopic.php?t=35498
http://www.sapfans.com/forums/viewtopic.php?t=5013
9. How do I create and use input-enabled fields in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=84933
http://www.sapfans.com/forums/viewtopic.php?t=69878
10. How can I use ALV for reports that are going to be run in background?
http://www.sapfans.com/forums/viewtopic.php?t=83243
http://www.sapfans.com/forums/viewtopic.php?t=19224
11. How can I display an icon in ALV? (Common requirement is traffic light icon).
http://www.sapfans.com/forums/viewtopic.php?t=79424
http://www.sapfans.com/forums/viewtopic.php?t=24512
12. How can I display a checkbox in ALV? http://www.sapfans.com/forums/viewtopic.php?t=88376
http://www.sapfans.com/forums/viewtopic.php?t=40968
http://www.sapfans.com/forums/viewtopic.php?t=6919
Check this for basic concepts of OOPS
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/abap%20objects/abap%20code%20sample%20to%20learn%20basic%20concept%20of%20object-oriented%20programming.doc
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/alv%20grid/abap%20code%20sample%20to%20display%20data%20in%20alv%20grid%20using%20object%20oriented%20programming.doc
Tabstrip
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/alv%20grid/abap%20code%20sample%20for%20tab%20strip%20in%20alv.pdf
Editable ALV
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/alv%20grid/abap%20code%20sample%20to%20edit%20alv%20grid.doc
Tree
http://www.sapdevelopment.co.uk/reporting/alv/alvtree/alvtree_usrint.htm
General Tutorial for OOPS
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/an%20easy%20reference%20for%20alv%20grid%20control.pdf
http://www.sapdevelopment.co.uk/reporting/alvhome.htm
http://www.sap-img.com/abap/what-is-alv-programming.htm
http://www.sap-img.com/abap-function.htm
http://www.geocities.com/mpioud/Abap_programs.html
http://www.sapdevelopment.co.uk/reporting/alv/alvtree%5Calvtree_basic.htm
http://esnips.com/doc/ad20dca9-6182-4903-8d8f-96a66dc8590c/ALV.pdf
http://www.sap-img.com/abap-function.htm -
In ALV Report Filter selection should be case sensitive
Dear All,
since one field is case sensitive in database table , i have to fetch that in alv report , but when i am applying filter on that field its is simply fetching data with case description. if its in caps it should fetch caps data but in smaal case report showing no data
Regards,
Pankaj VashistaHi,
All text datas are case sensitive.
To make it work perfectly You have to Use the Keyword translate to Upper Case than display
Now filter can work.
Without Transalation to Upper Case filter will not work.
Regards
Arbind -
In an alv report how to get data in next and previous pages.
in my alv report i require the output such that
when i will press the next button in the application tool bar the alv report will be displayed for the next inventory document number in the next page. like wise previous
would anybody please help me out.
thanks and regards
pappsIn your servlet you could set the arraylist into the HttpRequest object so that it is visible in the JSP you are forwarding to.
RegistrationDAO rdao=new RegistrationDAO();
ArrayList arr1=rdao.getsearchresults(af);
request.setAttribute("someArrayList",arr1);Then in the JSP you could use JSTL 1.1 and jsp:useBean tag to access the ArrayList like this
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<jsp:useBean id="someArrayList" class="java.util.ArrayList" scope="request"/>
<c:forEach var="currentRecord" items="${someArrayList}">
Some property of the AddressForm object: ${currentRecord.propertyName} <br/>
Another property of the AddessForm object : ${currentRecord.someOtherPropertyName} <br/>
<hr/>
</c:forEach>I guess you are using struts, so instead of JSTL there might be some struts tags that do the same as above JSTL tags. You can research further on that.
If you can't use struts tags or JSTL tags then you could write it with JSP scriptlets (highly discouraged option). -
Reading multiples files from a folder and processing
Hello everyone,
Im working on a project to analyst and process Acoustic Emission Signals. My problem is that I have a folder that containts several files .txt. Every file contains 16 waveforms (16 channels) that I need to process with an equation to detect the arrival times of the waves.
I have been working in this way : Running the labview code that open the file that I select .. then the processing happens on every wave and I click stop to select the file where I want to save the solutions. The solutions is only a vector of the 16 arrival times detected. Then I have to stop the code (by clicking Abort Execution) and repeat the process ... Run the code and bla bla bla .. and save on the same solution file that I used before.
The ideal situation is to read the files whitout stoping the execution of the code .. For example clicking a buttom to pass to the next file and saving all the solutions to the same file. That is beacause sometimes Im going to have more than a 100 files and this will give me a hard time if a forget in which file I was working. The idea is to make an automatic process.
Please .. I have been trying to find a solution to this while Im working in other part of the code. If someone could suggest me a solution it would be great.
Thanks.Hello everyone,
Well Im sorry if I didn't post my .vi ... I was working on it ... and I found a solution (whit some help that I found on the forums) but Im not happy at all ... because I still have to give the last part of the file name.
For example at the beginning I have to input the file name without the final number of the event ...
C:\Users\Irish\Desktop\Hydraulic Fracturing\E1_evento
then I finish adding the file number that I want to process on the folder
C:\Users\Irish\Desktop\Hydraulic Fracturing\E1_evento2.txt or 9.text or ... just the number ...
This is the case when I want to process every file specifying the file .. but what could you suggest me to do process all the data file by file ?
I attached the part of the code that Im using for this specific problem ...
Im using Labview 8.5
Thanks ...
Message Edited by Alvaro_Ortiz on 08-26-2009 03:14 PM
Attachments:
MultReadFiles.vi 58 KB -
Reading email in outlook with c# and parsing the body
Hello,
I don't know where to start.
The organization I work for uses different user web forms to collect user/client feedback. Instead of having those forms populate a table, they have them emailed to me as text in the body of an email for me to decide what to do with. My (local) boss wants
me to upload the data into our CRM. Everyone expects me to do that by hand ( which is now getting out of hand :D.)
I need to read an outlook 2010 email in a shared mailbox (to which I do not know the account password for mail server access) and parse the body data into a data table.
If I can get some help understanding how to access the individual email file(s) and read the data into a string array or something that achieves this result, I can take it from there. All suggestions are welcome however going back to the admin who
is in another country, won't make changes and doesn't speak english are not paths I can follow.
My glass here, is half full with the opportunity to resolve this challenge.Hello,
You can develop a VBA macro for handling new emails in the shared mailbox. I'd suggest starting from the
Getting Started with VBA in Outlook 2010 article. If you see a shared mailbox in your Outlook profile you can subscribe to the Inbox events (for example, ItemAdd) in the following way:
Dim WithEvents myInboxMailItem As Outlook.Items
Private Sub myInboxMailItem_ItemAdd(ByVal Item As Object)
Call MsgBox("Item Added", vbOKOnly, "[email protected]")
End Sub
Private Sub Initialize_Handler()
Dim fldInbox As Outlook.MAPIFolder
Dim gnspNameSpace As Outlook.NameSpace
Set gnspNameSpace = Outlook.GetNamespace("MAPI") 'Outlook Object
Set fldInbox = gnspNameSpace.Folders("[email protected]").Folders("Inbox")
Set myInboxMailItem = fldInbox.Items
End Sub
Private Sub Application_Startup()
Call Initialize_Handler
End Sub
In the ItemAdd event handler you can get all the required information parse the message body. The Outlook object model provides
three main ways for working with item bodies: Body, HTMLBody and WordEditor. -
Reading a file line by line and executing the code
I need to read a file line by line and execute them simultaneously.
I use BufferedReader for reading , but for executing i tried a lot , but could not find a solution.
Kindly help and try to brief me.If you're hoping to execute lines of java source code on the fly...then forget it. Java is a compiled language. It doesn't have an "eval" statement like other languages.
Now, you can write an interpreter for a language in Java. And I suppose you could write an interpreter for Java in Java (although at that point, you might as well choose to interpret a different language; it would probably be easier). But that would be a pretty big task. -
Submit ALV report in Background & exporting list to memory and return
Dear all,
I created one Z program (ZPROGRAM2).
Here i use SUBMIT ZPRORAM1_ALV exporting list to memory and return.
call function 'LIST_FROM_MEMORY'.
call function 'TABLE_COMPRESS' .
ZPRORAM1_ALV output i send mail.
This all are working in foreground.
If i schedule ZPROGRAM2 in background. that SUBMIT ZPRORAM1_ALV statement not working.
Please give me the Solution.
Thanks,
Durai.VIt is because of the ALV output that you are using. Check the condition sy-batch = 'X' (background processing) and then display a classical report. It will work then.
Thanks,
Jayant -
ALV report output to excel file, zip it and send to email
my requirement is to run a report then the result will be sent to email. Attachment is an excel file that is zipped since file size is about 25MB
I've search several forums and found a sap template in sending email with excel file attachment, it is BCS_EXAMPLE_7
but it should be zipped, what i found is this CL_ABAP_ZIP, but with my understanding, the file needs to be in PDF format to be able to zip
has anyone had the same requirement before?
Would be thankful to your input guys, thanks!any ideas guys?
-
My trackpad becomes REALLY unresponsive after I plug in a USB mouse. It seems like the cursor is broken and stuck on a permanent left click or something. I'm unable to select text or do any other sort of action that requires you to hold down the trackpad and drag. Mouse icons don't update as I scroll over different text and links. The trackpad is usually stuck in this unresponsive state until I restart my macbook which is extremely inconvenient if I have to do this after every time I use a USB mouse. Are there any fixes to this?
Melophage,
I don't leave it outside. Usually when I leave it overnight, I do so under the same conditions as when I leave it plugged in, and this morning I only left it for about an hour in my house and it did the same thing.
LowLuster,
I actually have a new hard drive I bought a while back and have been meaning to switch it out with the one that's in there now. I'll follow your instruction, then make the switch I had planned on and report back.
Maybe you are looking for
-
I upgraded to ios8 and can no longer connect my iPad to the projector in my classroom.
I'm not able to connect my iPad to the projector in my classroom after upgrading to ios8. Any thoughts as to why this device is not being recognized any longer?
-
i have movies in mp4 format which is compatible with my ipod but i can't seem to be able to drag those files into my itunes. how can i upload my videos onto my ipod if i can't get them into my itunes?? ): can somebody help me pls?
-
Flash Builder freeze on intellisense
Flash Builder keeps freezing whenever I try to choose something from the intellisense popup. Have anyone else experienced this problem and have a solution? (I use Flash Builder 4.5.1 on OSX 10.6.8)
-
Screen shows dim 'charged' icon - ipod doesn't sleep properly
I am having the same issue as described in the thread below and see no answer there. I can fully charge my ipod and it plays, etc. fine. When I try to put it to sleep, it goes black for a second and the comes back to dim with the "charged" icon on th
-
is there a way of exporting the results of a survey to a csv file? and how is it possible?