Widget for displaying sample HTML
I am trying to build a widget that has an area that will display sample of ~20 line HTML code. This sample code must be selectable so the user will be able to copy + paste it into their own text editor.
Currently I am using an xtype displayfield and using the fieldDescription to put my HTML code inside. I realized though that this fieldDescription does not allow me to format my code. I also tried using an xtype textarea and setting the emptyText as my HTML code, but clicking in the textarea would remove the HTML code.
The reason for this is that I have a textarea where the user will be populating a textarea with HTML code. This HTML code must be structured in a certain way so the CSS will format their code correctly. I want to include an example of how this HTML code should be structured.
EDIT - It will be great if I can apply the font-face Courier to this for ease of readability.
Hello,
From above what i would understood that you want to have a field in your dialog which will prepopulate a predefined html structure and same can be used while authoring the content in same attribute fields. If that is correct then i dont think you need to create a new widget because same can be achieved by setting up the property "defaultValue" with your defined HTML format as value on field attribute (let say textarea).
So it will be like as below
defaultValue String <html>what ever html format you want to place that can be used while authoring</html>
If you are using any richtext widget instead of textarea the same will apply but as RTE default includes <p> tag you can control it using property "removeSingleParagraphContainer" or "singleParagraphContainerReplacement" for more details plz refer http://dev.day.com/docs/en/cq/current/widgets-api/index.html?class=CQ.form.RichText
Richtext will have more feature compare to textarea like applying css etc... for information on setting up richtext editor plz refer http://dev.day.com/docs/en/cq/current/administering/configuring_rich_text_editor.html
I hope above will help you to proceed. let me know for more information if you needed.
Thanks,
Pawan
Similar Messages
-
An interesting widget for displaying timelines
Here's something fun for the weekend.
I recently found the SIMILE Timeline widget from http://simile.mit.edu/timeline .
It lets you display time-based data in drag-able bands with different time scales.
Best of all, it works easily with APEX.
Here is a simple demo:
http://apex.oracle.com/pls/otn/f?p=50734:1
With instructions:
http://apex.oracle.com/pls/otn/f?p=50734:2
DougRobert,
By "Scripts in HTML Region (Use a PL/SQL Region to make it dynamic)", I meant that I used the text of the script as
the source of an HTML region. (With no template)
If you didn't want the scripts to be hard-coded, you could have them generated by
a PL/SQL process in a PL/SQL region.
The "xml has no properties" error probably means that the script is working, but the ALLEMPS On Demand process
isn't working or isn't returning any data.
It is expecting the TLTest package to exist in your schema.
Here's a link to download an export of the application so you can try it in your workspace:
http://apex.oracle.com/pls/otn/wwv_flow_file_mgr.get_file?p_security_group_id=563610923303911988&p_fname=f107_TL.sql&p_inline=NO
You'll need a copy of the EMPLOYEES table from the HR sample schema, or something similar.
I'll try to improve my instructions later today.
Doug -
IWeb widget for idisk or HTML Code
I've created an iFrame page for my website that links to my iDisk public folder using the HTML Snippet.
I've password protected my public folder so is there anyway to include authentication in the HTML snippet so that the iframe page automatically logs into my public folder? If so, could someone provide me with a code template?
Otherwise is there a widget that can create iFrame snippets and also has a GUI to include authentication credential?
Thanks
Message was edited by: One48This is the code:
<iframe height="XXXpx" allowTransparency="true" frameborder="0" scrolling="no" style="width:XXXpx;border:none" src="URL TO ITEM TO BE EMBEDDED"></iframe>
OT -
Widget for displaying Tasks in a Calendar format ?
Our application has a requirement of showing the ToDo list in a calendar format, similar to what the Oracle Calendar shows. The user should have the ability to directly adds tasks to a certain date, scroll the calendar dates back and forward etc. Basically, we need the calendaring UI.
Is there a quick way of enabling this in our product using the Calendar SDK without trying to reinvent the wheel ? The application is web-based but should have the necessary richness.
If this is not the right forum to ask the question then can you point me to one ?
Thanks,
ShaileshHello,
From above what i would understood that you want to have a field in your dialog which will prepopulate a predefined html structure and same can be used while authoring the content in same attribute fields. If that is correct then i dont think you need to create a new widget because same can be achieved by setting up the property "defaultValue" with your defined HTML format as value on field attribute (let say textarea).
So it will be like as below
defaultValue String <html>what ever html format you want to place that can be used while authoring</html>
If you are using any richtext widget instead of textarea the same will apply but as RTE default includes <p> tag you can control it using property "removeSingleParagraphContainer" or "singleParagraphContainerReplacement" for more details plz refer http://dev.day.com/docs/en/cq/current/widgets-api/index.html?class=CQ.form.RichText
Richtext will have more feature compare to textarea like applying css etc... for information on setting up richtext editor plz refer http://dev.day.com/docs/en/cq/current/administering/configuring_rich_text_editor.html
I hope above will help you to proceed. let me know for more information if you needed.
Thanks,
Pawan -
Display external html page in (Collapsible Panel widget)
i everybody
is there a way to display external html page in (Collapsible Panel widget)
All the example a seen is with raw text in it
is the panel can display different object instead of simple text
At least a internal designed html page
ThanksThanks... surely a easy one for you
But its a great tool and its exatly what i want
even my js button works trough it
Thanks again -
SAP HANA Cloud Portal : Make Widget For Java Application and Display in HANA Portal
Hi Experts,
I have created one Java Application using eclipse luno.
I have successfully deploy on my hanatrial version and able to see the Started Application under the Java Application.
Can anyone have idea how to use this application in HANA portal and display/ run this Java Application in SAP HANA Cloud Portal Website.
I want to know is it possible or not ? and yes then how its possible ?
What are the steps require to make Widget for this java apps and publish on portal.
Many Thanks,
MithunHi Mithun,
yes it's possible and relatively easy - follow Chapter 7 of the guide -
ESPM WebShop Extension
Regards
Kenny -
Provide Sample Program for Display Symbol?
Hi All,
I want write program for display symbol in S94, but want to know which table i can refer, please provide me a sample program for that.
Regards
AvinavHi,
Do you mean the ICONS ?
TYPE-POOLS : ICON
In your code use the icon name.
In case of ALV, in the fieldcatalog mention wa_fielcat-icon = 'X'.
Thanks
Swarna -
I have a page with spry tabbed panels, in CS3, and I need to display inline HTML content (data tables) within the tabs, but am having trouble finding a lightbox type application that does more than images.
I've used Highslide in the past, but it seems to have a conflict with the spry code, & will not display in IE8 on Windows...
I need a fairly easy to implement solution, but am not sure what will work best.
There are some decent looking jquery plugins about, but I'm not familiar with implementing jquery..
I'd love any suggestions, so that we can get this site out.
Thanks!
-jon harrisHi,
perhaps it would be better to start first with a ready-made solution. Later, when you see the mode of operation and how they work you could use a DW-flash-show, ok?
Just look around in and on these pages and don't get confused by the large range, look at the different sides in peace, it is worthwhile.
http://www.lokeshdhakar.com/projects/lightbox2/ (I use it)
http://www.shadowbox-js.com/ (I use it too)
Countless (57 possibilities) :-)
http://www.1stwebdesigner.com/resources/57-free-image-gallery-slideshow-and-lightbox-solut ions/
...and here some tutorials:
http://www.google.de/#q=dreamweaver+slideshow&hl=de&prmd=v&source=univ&tbs=vid:1&tbo=u&ei= 2FrqS-X0MoqMOOrv2OkK&sa=X&oi=video_result_group&ct=title&resnum=4&ved=0CDMQqwQwAw&fp=79a60 95848c03fc9
DW extensions: http://www.fourlevel.com/extensions.htm
Hans-G. -
How can I display the HTML page from servlet which is called by an applet
How can I display the HTML page from servlet which is called by an
applet using the doPost method. If I print the response i can able to see the html document. How I can display it in the browser.
I am calling my struts action class from the applet. I want to show the response in the same browser.
Code samples will be appreciated.hi
I got one way for this .
call a javascript in showDocument() to submit the form -
IWeb doesn't offer widget for Facebook "Like" button?
Is it true that iWeb doesn't offer a widget for adding a Facebook LIKE button? The code offered to copy by Facebook doesn't work when I paste it into a text box on my iWeb site.
Thanks for any insights fellow users can offer. My free trial will be ending soon and I'd only sign up for the year if these issues can be resolved.That's because you don't paste html code into a text box. You need to copy and paste any kind of html code into an html snippet placed on your page where you want the code to appear. Copy and paste the code into the snippet and click on Apply and it should display.
-
Displaying the HTML content ( VO attribute) as tooltip description.
Hi all,
I am doing a customization, where I need to display the VO attribute value as a tool tip for a link in advanced table column.
The VO attribute value is a "HTML" text.
Now, in the tool tip also, it is displaying in HTML format.
Do anyone know how to convert this HTML format to a string format.
Thanks in advance.Hi Gyan,
This is one sample.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7652.14">
<TITLE>RE: RE: [NETAPP LOG # 2611146] (Ref. # RQST00000068819) VFM</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->
<P><FONT COLOR="#0000FF" SIZE=2 FACE="Comic Sans MS">Hi John,</FONT>
</P>
<P><FONT COLOR="#0000FF" SIZE=2 FACE="Comic Sans MS">Further to the telecon please find the latest logs attached:</FONT>
</P>
<P><FONT FACE="Arial" SIZE=2 COLOR="#000000"> <<SFILE-BOTTOM_ReplicationAgent.exe_Events.zip>> </FONT><FONT FACE="Arial" SIZE=2 COLOR="#000000"> <<SYSTOOLS_Server.exe_Default.zip>> </FONT>
<BR><FONT FACE="Comic Sans MS">Thanks and Regards,</FONT>
<BR><FONT FACE="Comic Sans MS"> </FONT>
<BR><B><FONT FACE="Comic Sans MS">Vasuki N S</FONT></B>
<BR><B><FONT FACE="Comic Sans MS">Technical Support Engineer</FONT></B>
<BR><FONT FACE="Comic Sans MS">----------------------------------------------------------------------------</FONT>
<BR><U><FONT COLOR="#0000FF" FACE="Comic Sans MS">[email protected]</FONT></U>
<BR><FONT FACE="Comic Sans MS">Working Hours Wed - Sat: 1PM – 12AM EST </FONT>
<BR><FONT FACE="Comic Sans MS">For technical assistance outside my regular working hours, please call:</FONT>
<BR><FONT FACE="Comic Sans MS">US & Canada 888-4-NETAPP // * EMEA+Europe 00-800-44-NETAPP // * Asia/Pacific 800-8008-0800</FONT>
</P>
<BR>
<P><FONT SIZE=1 FACE="Tahoma">_____________________________________________ </FONT>
<BR><B><FONT SIZE=1 FACE="Tahoma">From: </FONT></B> <FONT SIZE=1 FACE="Tahoma">Ns, Vasuki </FONT>
<BR><B><FONT SIZE=1 FACE="Tahoma">Sent: </FONT></B> <FONT SIZE=1 FACE="Tahoma">Thursday, November 29, 2007 7:52 PM</FONT>
<BR><B><FONT SIZE=1 FACE="Tahoma">To: </FONT></B> <FONT SIZE=1 FACE="Tahoma">'[email protected]'</FONT>
<BR><B><FONT SIZE=1 FACE="Tahoma">Cc: </FONT></B> <FONT SIZE=1 FACE="Tahoma">'[email protected]'; '[email protected]'; '[email protected]'; Vantive CS; Gough,William</FONT>
<BR><B><FONT SIZE=1 FACE="Tahoma">Subject: </FONT></B> <FONT SIZE=1 FACE="Tahoma">RE: [NETAPP LOG # 2611146] (Ref. # RQST00000068819) VFM</FONT>
</P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Hi Mike,</FONT>
</P>
<P><FONT SIZE=2 FACE="Comic Sans MS">I would like to inform you that I have taken the ownership of this case and will be working with you for requisite case follow-up.</FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Please do let us know if you have further issues/queries with respect to this case?</FONT>
</P>
<P><FONT SIZE=2 FACE="Comic Sans MS">------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Please note my working hours of 1 PM until 12 AM EST on Wednesday through Saturday. If you need immediate assistance outside of these hours, please call into the TECH SUPPORT </FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">HOT LINE 1888 463 8277 and reference your case number, the next available engineer will be able to assist you</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Thanks and Regards,</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS"> </FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Vasuki N S</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Technical Support Engineer</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Network Appliance ® Inc. </FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Email:[email protected]</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">-------------------------------------------------------------------------------------------------------</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Get answers NOW! @ </FONT><U><FONT COLOR="#0000FF" SIZE=2 FACE="Comic Sans MS">http://now.netapp.com</FONT></U><FONT SIZE=2 FACE="Comic Sans MS"> or @ </FONT><U><FONT COLOR="#0000FF" SIZE=2 FACE="Comic Sans MS">www.netapp.com</FONT></U>
<BR><FONT SIZE=2 FACE="Comic Sans MS">-------------------------------------------------------------------------------------------------------</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">For technical assistance outside my regular working hours, please call:</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">US & Canada 888-4-NETAPP // * EMEA+Europe 00-800-44-NETAPP // * Asia/Pacific 800-8008-0800 </FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS"> </FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Everyone at Network Appliance is committed to the highest level of customer satisfaction. If at any time you feel that you’re less than very satisfied with our support, please contact my manager, David Bauer [email protected].</FONT></P>
<BR>
<P><FONT SIZE=2 FACE="Comic Sans MS">From: Bingen, Chance </FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Sent: Thursday, November 29, 2007 11:34 AM</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">To: 'Luu, Mike'; Support</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Cc: FS Support; Vantive CS; Gough,William; Khe Lam</FONT>
<BR><FONT SIZE=2 FACE="Comic Sans MS">Subject: RE: [NETAPP LOG # 2611146] (Ref. # RQST00000068819) VFM</FONT>
</P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Thanks, Mike!</FONT>
</P>
<P><FONT SIZE=2 FACE="Comic Sans MS">I appreciate the logs. I was searching them for a listing of kfeintuc's file you mentioned previously, and didn't see it listed in the server or RA default logs you sent.</FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Was the RA log you sent from the VFM server or from the source server? And is the source server a Windows box or a filer?</FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">As it is, we see lots of file in use type errors, such as this one: "0x80070020 - The process cannot access the file because it is being used by another process." for "DefaultCopier::OnException: CIFSHandleCache::GetHandle: via CIFSVolumeProvider::ScanAltDataStreams_UsingQIF, CreateFile(<\\bri-net\p$\PShare\Neuroscience\Y Shi Grp\Individual\shli\old pc\COH-project issues\Tissue preperation records-Shengxiu.xls>,R--,--,00000000) failed"</FONT></P>
<P><FONT SIZE=2 FACE="Comic Sans MS">This may be expected given the environment.</FONT>
</P>
<P><FONT SIZE=2 FACE="Comic Sans MS">Thanks!</FONT>
</P>
</BODY>
</HTML> -
Wait for Next Sample Clock error, or 'How do I put this VI on a diet'?
Hello!
In the attached VI I've been running since June, I have all the functionality I need. No questions there at all, thanks to much time and help from this board!
My nagging problem is that any time I use the PC for other minor tasks other than Labview, it will display the following error:
209802 occurred at DAQmx Wait For Next Sample Clock.vi:1
A search earlier in the month indicated that it could have been a result of my old and outdated PC; I've since replaced it with a brand-new dell dimension 1100. Celeron 2.53ghz with 1.00gb of ram. Should be enough to service Labview and other minor tasks (automatic antivirus updating and also maintenance tasks). However, any time any other program opens or even if the screen is scrolled around on Labview quickly, I get that same error.
Resource usage when idle, with nothing but this VI running is 5-10%, all labview. Upon scrolling the VI, it quickly jumps to the 58-60% and above mark and soon throws that error.
I know that there's a lot of code here that can be cleaner--I know that even though it's functioning correctly, there could be a less resource-hogging way to go about it. Can anyone give me any suggestions on how to make this VI a little 'lighter'?
Thanks so much in advance,
Ralph
Still confused after 8 years.
Attachments:
Currently Running 063006.vi 899 KBHi Ralph,
The wait.vi waits until the amount of time has passed. While the wait on next ms.vi uses some kind of quotient and remainder on the computer time until the remainder passed zero.
In this way you can synchronize 2 loops, and somehow it is less time-consuming. The only difference you will see is in the first run!
There you see a smaller amount of time:
Message Edited by TonP on 10-04-2006 04:21 PM
Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
Nederlandse LabVIEW user groep www.lvug.nl
My LabVIEW Ideas
LabVIEW, programming like it should be!
Attachments:
Example_BD.png 2 KB -
I Need Interactive Report for displaying vendor information. Based on the s
Interactive Report for displaying vendor information. Based on the selection made by the corresponding Vendor Bank Details are listed such that the line selected in the basic list was visible along with the secondary list.
hi
Hi
Use the Table LFA1 and LFB1 in the basic list
and LFBK table details in the secondary list
see the sample code related to customer Sales orders
modify it with the Vendor tables
REPORT ZTEJ_INTAB1 LINE-SIZE 103 LINE-COUNT 35(5) NO STANDARD PAGE
HEADING.
*TABLES DECLARATION
TABLES : KNA1, VBAK, VBAP.
*SELECT OPTIONS
SELECT-OPTIONS: CUST_NO FOR KNA1-KUNNR.
*INITIALIZATION
INITIALIZATION.
CUST_NO-LOW = '01'.
CUST_NO-HIGH = '5000'.
CUST_NO-SIGN = 'I'.
CUST_NO-OPTION = 'BT'.
APPEND CUST_NO.
*SELECTION SCREEN VALIDATION
AT SELECTION-SCREEN ON CUST_NO.
LOOP AT SCREEN.
IF CUST_NO-LOW < 1 OR CUST_NO-HIGH > 5000.
MESSAGE E001(ZTJ1).
ENDIF.
ENDLOOP.
*BASIC LIST SELECTION
START-OF-SELECTION.
SELECT KUNNR NAME1 ORT01 LAND1 INTO
(KNA1-KUNNR, KNA1-NAME1,KNA1-ORT01,KNA1-LAND1)
FROM KNA1
WHERE KUNNR IN CUST_NO.
WRITE:/1 SY-VLINE,
KNA1-KUNNR UNDER 'CUSTOMER NO.' HOTSPOT ON,
16 SY-VLINE,
KNA1-NAME1 UNDER 'NAME',
61 SY-VLINE,
KNA1-ORT01 UNDER 'CITY',
86 SY-VLINE,
KNA1-LAND1 UNDER 'COUNTRY',
103 SY-VLINE.
HIDE: KNA1-KUNNR.
ENDSELECT.
ULINE.
*SECONDARY LIST ACCESS
AT user-command.
IF SY-UCOMM = 'IONE'.
PERFORM SALES_ORD.
ENDIF.
IF SY-UCOMM = 'ITWO'.
PERFORM ITEM_DET.
ENDIF.
*TOP OF PAGE
TOP-OF-PAGE.
FORMAT COLOR 1.
WRITE : 'CUSTOMER DETAILS'.
FORMAT COLOR 1 OFF.
ULINE.
FORMAT COLOR 3.
WRITE : 1 SY-VLINE,
3 'CUSTOMER NO.',
16 SY-VLINE,
18 'NAME',
61 SY-VLINE,
63 'CITY',
86 SY-VLINE,
88 'COUNTRY',
103 SY-VLINE.
ULINE.
FORMAT COLOR 3 OFF.
*TOP OF PAGE FOR SECONDARY LISTS
TOP-OF-PAGE DURING LINE-SELECTION.
*TOP OF PAGE FOR 1ST SECONDARY LIST
IF SY-UCOMM = 'IONE'.
ULINE.
FORMAT COLOR 1.
WRITE : 'SALES ORDER DETAILS'.
ULINE.
FORMAT COLOR 1 OFF.
FORMAT COLOR 3.
WRITE : 1 SY-VLINE,
3 'CUSTOMER NO.',
16 SY-VLINE,
18 'SALES ORDER NO.',
40 SY-VLINE,
42 'DATE',
60 SY-VLINE,
62 'CREATOR',
85 SY-VLINE,
87 'DOC DATE',
103 SY-VLINE.
ULINE.
ENDIF.
FORMAT COLOR 3 OFF.
*TOP OF PAGE FOR 2ND SECONDARY LIST
IF SY-UCOMM = 'ITWO'.
ULINE.
FORMAT COLOR 1.
WRITE : 'ITEM DETAILS'.
ULINE.
FORMAT COLOR 1 OFF.
FORMAT COLOR 3.
WRITE : 1 SY-VLINE,
3 'SALES ORDER NO.',
40 SY-VLINE,
42 'SALES ITEM NO.',
60 SY-VLINE,
62 'ORDER QUANTITY',
103 SY-VLINE.
ULINE.
ENDIF.
FORMAT COLOR 3 OFF.
*END OF PAGE
END-OF-PAGE.
ULINE.
WRITE :'USER :',SY-UNAME,/,'DATE :', SY-DATUM, 85 'END OF PAGE:',
SY-PAGNO.
SKIP.
*& Form SALES_ORD
*& FIRST SECONDARY LIST FORM
FORM SALES_ORD .
SELECT KUNNR VBELN ERDAT ERNAM AUDAT INTO
(VBAK-KUNNR, VBAK-VBELN, VBAK-ERDAT, VBAK-ERNAM, VBAK-AUDAT)
FROM VBAK
WHERE KUNNR = KNA1-KUNNR.
WRITE:/1 SY-VLINE,
VBAK-KUNNR UNDER 'CUSTOMER NO.' HOTSPOT ON,
16 SY-VLINE,
VBAK-VBELN UNDER 'SALES ORDER NO.' HOTSPOT ON,
40 SY-VLINE,
VBAK-ERDAT UNDER 'DATE',
60 SY-VLINE,
VBAK-ERNAM UNDER 'CREATOR',
85 SY-VLINE,
VBAK-AUDAT UNDER 'DOC DATE',
103 SY-VLINE.
HIDE : VBAK-VBELN.
ENDSELECT.
ULINE.
ENDFORM. " SALES_ORD
*& Form ITEM_DET
*& SECOND SECONDARY LIST FORM
FORM ITEM_DET .
SELECT VBELN POSNR KWMENG INTO
(VBAP-VBELN, VBAP-POSNR, VBAP-KWMENG)
FROM VBAP
WHERE VBELN = VBAK-VBELN.
WRITE : /1 SY-VLINE,
VBAP-VBELN UNDER 'SALES ORDER NO.',
40 SY-VLINE,
VBAP-POSNR UNDER 'SALES ITEM NO.',
60 SY-VLINE,
VBAP-KWMENG UNDER 'ORDER QUANTITY',
103 SY-VLINE.
ENDSELECT.
ULINE.
ENDFORM. " ITEM_DET
REPORT demo_list_at_pf.
START-OF-SELECTION.
WRITE 'Basic List, Press PF5, PF6, PF7, or PF8'.
AT pf5.
PERFORM out.
AT pf6.
PERFORM out.
AT pf7.
PERFORM out.
AT pf8.
PERFORM out.
FORM out.
WRITE: 'Secondary List by PF-Key Selection',
/ 'SY-LSIND =', sy-lsind,
/ 'SY-UCOMM =', sy-ucomm.
ENDFORM.
After executing the program, the system displays the basic list. The user can press the function keys F5 , F6 , F7 , and F8 to create secondary lists. If, for example, the 14th key the user presses is F6 , the output on the displayed secondary list looks as follows:
Secondary List by PF-Key Selection
SY-LSIND = 14
SY-UCOMM = PF06
Example for AT USER-COMMAND.
REPORT demo_list_at_user_command NO STANDARD PAGE HEADING.
START-OF-SELECTION.
WRITE: 'Basic List',
/ 'SY-LSIND:', sy-lsind.
TOP-OF-PAGE.
WRITE 'Top-of-Page'.
ULINE.
TOP-OF-PAGE DURING LINE-SELECTION.
CASE sy-pfkey.
WHEN 'TEST'.
WRITE 'Self-defined GUI for Function Codes'.
ULINE.
ENDCASE.
AT LINE-SELECTION.
SET PF-STATUS 'TEST' EXCLUDING 'PICK'.
PERFORM out.
sy-lsind = sy-lsind - 1.
AT USER-COMMAND.
CASE sy-ucomm.
WHEN 'FC1'.
PERFORM out.
WRITE / 'Button FUN 1 was pressed'.
WHEN 'FC2'.
PERFORM out.
WRITE / 'Button FUN 2 was pressed'.
WHEN 'FC3'.
PERFORM out.
WRITE / 'Button FUN 3 was pressed'.
WHEN 'FC4'.
PERFORM out.
WRITE / 'Button FUN 4 was pressed'.
WHEN 'FC5'.
PERFORM out.
WRITE / 'Button FUN 5 was pressed'.
ENDCASE.
sy-lsind = sy-lsind - 1.
FORM out.
WRITE: 'Secondary List',
/ 'SY-LSIND:', sy-lsind,
/ 'SY-PFKEY:', sy-pfkey.
ENDFORM.
<b>Vendor performance report</b>
See this sample code
*"Table declarations...................................................
TABLES:
EKKO, " Purchasing Document Header
CDHDR, " Change document header
SSCRFIELDS. " Fields on selection screens
*"Selection screen elements............................................
SELECT-OPTIONS:
S_EBELN FOR EKKO-EBELN, " Purchasing Document Number
S_LIFNR FOR EKKO-LIFNR, " Vendor's account number
S_EKGRP FOR EKKO-EKGRP, " Purchasing group
S_BEDAT FOR EKKO-BEDAT, " Purchasing Document Date
S_UDATE FOR CDHDR-UDATE. " Creation date of the change
" document
*" Data declarations...................................................
Field String to hold Purchase Document Number *
DATA:
BEGIN OF FS_EBELN,
EBELN(90) TYPE C, " Purchase Document Number
ERNAM TYPE EKKO-ERNAM, " Name of Person who Created
" the Object
LIFNR TYPE EKKO-LIFNR, " Vendor's account number
EKGRP TYPE EKKO-EKGRP, " Purchasing group
BEDAT TYPE EKKO-BEDAT, " Purchasing Document Date
END OF FS_EBELN,
Field String to hold Purchase Document Header *
BEGIN OF FS_EKKO,
EBELN TYPE EKKO-EBELN, " Purchasing Document Number
ERNAM TYPE EKKO-ERNAM, " Name of Person who Created the
" Object
LIFNR TYPE EKKO-LIFNR, " Vendor's account number
EKGRP TYPE EKKO-EKGRP, " Purchasing group
BEDAT TYPE EKKO-BEDAT, " Purchasing Document Date
END OF FS_EKKO,
Field String to hold Account Number and name of the Vendor *
BEGIN OF FS_LFA1,
LIFNR TYPE LFA1-LIFNR, " Account Number of Vendor
NAME1 TYPE LFA1-NAME1, " Name1
END OF FS_LFA1,
Field String to hold Change date and the name of the user *
BEGIN OF FS_CDHDR,
OBJECTCLAS TYPE CDHDR-OBJECTCLAS, " Object Class
OBJECTID TYPE CDHDR-OBJECTID, " Object value
CHANGENR TYPE CDHDR-CHANGENR, " Document change number
USERNAME TYPE CDHDR-USERNAME, " User name
UDATE TYPE CDHDR-UDATE, " Creation date of the change
" document
END OF FS_CDHDR,
Field String to hold Change document items *
BEGIN OF FS_CDPOS,
OBJECTCLAS TYPE CDPOS-OBJECTCLAS," Object class
OBJECTID(10) TYPE C, " Object Value
CHANGENR TYPE CDPOS-CHANGENR, " Document change number
TABNAME TYPE CDPOS-TABNAME, " Table Name
FNAME TYPE CDPOS-FNAME, " Field Name
VALUE_NEW TYPE CDPOS-VALUE_NEW, " New contents of changed field
VALUE_OLD TYPE CDPOS-VALUE_OLD, " Old contents of changed field
END OF FS_CDPOS,
Field String to hold Date Element Name *
BEGIN OF FS_DATAELE,
TABNAME TYPE DD03L-TABNAME, " Table Name
FIELDNAME TYPE DD03L-FIELDNAME, " Field Name
ROLLNAME TYPE DD03L-ROLLNAME, " Data element (semantic domain)
END OF FS_DATAELE,
Field String to hold Short Text of the Date Element *
BEGIN OF FS_TEXT,
ROLLNAME TYPE DD04T-ROLLNAME, " Data element (semantic domain)
DDTEXT TYPE DD04T-DDTEXT, " Short Text Describing R/3
" Repository Objects
END OF FS_TEXT,
Field String to hold data to be displayed on the ALV grid *
BEGIN OF FS_OUTTAB,
EBELN TYPE EKKO-EBELN, " Purchasing Document Number
ERNAM TYPE EKKO-ERNAM, " Name of Person who Created the
" Object
LIFNR TYPE EKKO-LIFNR, " Vendor's account number
EKGRP TYPE EKKO-EKGRP, " Purchasing group
BEDAT TYPE EKKO-BEDAT, " Purchasing Document Date
WERKS TYPE LFA1-WERKS, " Plant
NAME1 TYPE LFA1-NAME1, " Name1
USERNAME TYPE CDHDR-USERNAME, " User name
UDATE TYPE CDHDR-UDATE, " Creation date of the change
" document
DDTEXT TYPE DD04T-DDTEXT, " Short Text Describing R/3
" Repository Objects
VALUE_NEW TYPE CDPOS-VALUE_NEW, " New contents of changed field
VALUE_OLD TYPE CDPOS-VALUE_OLD, " Old contents of changed field
END OF FS_OUTTAB,
Internal table to hold Purchase Document Number *
T_EBELN LIKE STANDARD TABLE
OF FS_EBELN,
Internal table to hold Purchase Document Header *
T_EKKO LIKE STANDARD TABLE
OF FS_EKKO,
Temp Internal table to hold Purchase Document Header *
T_EKKO_TEMP LIKE STANDARD TABLE
OF FS_EKKO,
Internal table to hold Account number and Name of the Vendor *
T_LFA1 LIKE STANDARD TABLE
OF FS_LFA1,
Internal Table to hold Change date and the name of the user *
T_CDHDR LIKE STANDARD TABLE
OF FS_CDHDR,
Internal Table to hold Change document items *
T_CDPOS LIKE STANDARD TABLE
OF FS_CDPOS,
Temp. Internal Table to hold Change document items *
T_CDPOS_TEMP LIKE STANDARD TABLE
OF FS_CDPOS,
Internal Table to hold Data Element Name *
T_DATAELE LIKE STANDARD TABLE
OF FS_DATAELE,
Temp. Internal Table to hold Data Element Name *
T_DATAELE_TEMP LIKE STANDARD TABLE
OF FS_DATAELE,
Internal Table to hold Short Text of the Date Element *
T_TEXT LIKE STANDARD TABLE
OF FS_TEXT,
Internal Table to hold data to be displayed on the ALV grid *
T_OUTTAB LIKE STANDARD TABLE
OF FS_OUTTAB.
C L A S S D E F I N I T I O N *
CLASS LCL_EVENT_HANDLER DEFINITION DEFERRED.
*" Data declarations...................................................
Work variables *
DATA:
W_EBELN TYPE EKKO-EBELN, " Purchasing Document Number
W_LIFNR TYPE EKKO-LIFNR, " Vendor's account number
W_EKGRP TYPE EKKO-EKGRP, " Purchasing group
W_VALUE TYPE EKKO-EBELN, " Reflected Value
W_SPACE VALUE ' ', " Space
W_FLAG TYPE I, " Flag Variable
W_VARIANT TYPE DISVARIANT, " Variant
*--- ALV Grid
W_GRID TYPE REF TO CL_GUI_ALV_GRID,
*--- Event Handler
W_EVENT_CLICK TYPE REF TO LCL_EVENT_HANDLER,
*--- Field catalog table
T_FIELDCAT TYPE LVC_T_FCAT.
AT SELECTION-SCREEN EVENT *
AT SELECTION-SCREEN ON S_EBELN.
Subroutine to validate Purchase Document Number.
PERFORM VALIDATE_PD_NUM.
AT SELECTION-SCREEN ON S_LIFNR.
Subroutine to validate Vendor Number.
PERFORM VALIDATE_VEN_NUM.
AT SELECTION-SCREEN ON S_EKGRP.
Subroutine to validate Purchase Group.
PERFORM VALIDATE_PUR_GRP.
START-OF-SELECTION EVENT *
START-OF-SELECTION.
Subroutine to select all Purchase orders.
PERFORM SELECT_PO.
CHECK W_FLAG EQ 0.
Subroutine to select Object values.
PERFORM SELECT_OBJ_ID.
CHECK W_FLAG EQ 0.
Subroutine to select Changed values.
PERFORM SELECT_CHANGED_VALUE.
CHECK W_FLAG EQ 0.
Subroutine to Select Purchase Orders.
PERFORM SELECT_PUR_DOC.
Subroutine to select Vendor Details.
PERFORM SELECT_VENDOR.
Subroutine to select Text for the Changed values.
PERFORM DESCRIPTION.
END-OF-SELECTION EVENT *
END-OF-SELECTION.
IF NOT T_EKKO IS INITIAL.
Subroutine to populate the Output Table.
PERFORM FILL_OUTTAB.
Subroutine to build Field Catalog.
PERFORM PREPARE_FIELD_CATALOG CHANGING T_FIELDCAT.
CALL SCREEN 100.
ENDIF. " IF NOT T_EKKO...
CLASS LCL_EVENT_HANDLER DEFINITION
Defining Class which handles events
CLASS LCL_EVENT_HANDLER DEFINITION .
PUBLIC SECTION .
METHODS:
HANDLE_HOTSPOT_CLICK
FOR EVENT HOTSPOT_CLICK OF CL_GUI_ALV_GRID
IMPORTING E_ROW_ID E_COLUMN_ID.
ENDCLASS. " LCL_EVENT_HANDLER DEFINITION
CLASS LCL_EVENT_HANDLER IMPLEMENTATION
Implementing the Class which can handle events
CLASS LCL_EVENT_HANDLER IMPLEMENTATION .
*---Handle Double Click
METHOD HANDLE_HOTSPOT_CLICK .
Subroutine to get the HotSpot Cell information.
PERFORM GET_CELL_INFO.
SET PARAMETER ID 'BES' FIELD W_VALUE.
CALL TRANSACTION 'ME23N'.
ENDMETHOD. " HANDLE_HOTSPOT_CLICK
ENDCLASS. " LCL_EVENT_HANDLER
*& Module STATUS_0100 OUTPUT
PBO Event
MODULE STATUS_0100 OUTPUT.
SET PF-STATUS 'OOPS'.
SET TITLEBAR 'TIT'.
Subroutine to fill the Variant Structure
PERFORM FILL_VARIANT.
IF W_GRID IS INITIAL.
CREATE OBJECT W_GRID
EXPORTING
I_SHELLSTYLE = 0
I_LIFETIME =
I_PARENT = CL_GUI_CONTAINER=>SCREEN0
I_APPL_EVENTS =
I_PARENTDBG =
I_APPLOGPARENT =
I_GRAPHICSPARENT =
I_NAME =
I_FCAT_COMPLETE = SPACE
EXCEPTIONS
ERROR_CNTL_CREATE = 1
ERROR_CNTL_INIT = 2
ERROR_CNTL_LINK = 3
ERROR_DP_CREATE = 4
OTHERS = 5.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF. " IF SY-SUBRC <> 0
CALL METHOD W_GRID->SET_TABLE_FOR_FIRST_DISPLAY
EXPORTING
I_BUFFER_ACTIVE =
I_BYPASSING_BUFFER =
I_CONSISTENCY_CHECK =
I_STRUCTURE_NAME =
IS_VARIANT = W_VARIANT
I_SAVE = 'A'
I_DEFAULT = 'X'
IS_LAYOUT =
IS_PRINT =
IT_SPECIAL_GROUPS =
IT_TOOLBAR_EXCLUDING =
IT_HYPERLINK =
IT_ALV_GRAPHICS =
IT_EXCEPT_QINFO =
IR_SALV_ADAPTER =
CHANGING
IT_OUTTAB = T_OUTTAB
IT_FIELDCATALOG = T_FIELDCAT
IT_SORT =
IT_FILTER =
EXCEPTIONS
INVALID_PARAMETER_COMBINATION = 1
PROGRAM_ERROR = 2
TOO_MANY_LINES = 3
OTHERS = 4
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF. " IF SY-SUBRC <> 0.
ENDIF. " IF W_GRID IS INITIAL
CREATE OBJECT W_EVENT_CLICK.
SET HANDLER W_EVENT_CLICK->HANDLE_HOTSPOT_CLICK FOR W_GRID.
ENDMODULE. " STATUS_0100 OUTPUT
*& Module USER_COMMAND_0100 INPUT
PAI Event
MODULE USER_COMMAND_0100 INPUT.
CASE SY-UCOMM.
WHEN 'BACK'.
LEAVE TO SCREEN 0.
WHEN 'EXIT'.
LEAVE PROGRAM.
WHEN 'CANCEL'.
LEAVE TO SCREEN 0.
ENDCASE.
ENDMODULE. " USER_COMMAND_0100 INPUT
*& Form PREPARE_FIELD_CATALOG
Subroutine to build the Field catalog
<--P_T_FIELDCAT Field Catalog Table
FORM PREPARE_FIELD_CATALOG CHANGING PT_FIELDCAT TYPE LVC_T_FCAT .
DATA LS_FCAT TYPE LVC_S_FCAT.
Purchasing group...
LS_FCAT-FIELDNAME = 'EKGRP'.
LS_FCAT-REF_TABLE = 'EKKO'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Purchasing Document Number...
LS_FCAT-FIELDNAME = 'EBELN'.
LS_FCAT-REF_TABLE = 'EKKO' .
LS_FCAT-EMPHASIZE = 'C411'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
LS_FCAT-HOTSPOT = 'X'.
APPEND LS_FCAT TO PT_FIELDCAT .
CLEAR LS_FCAT .
Name of Person who Created the Object...
LS_FCAT-FIELDNAME = 'ERNAM'.
LS_FCAT-REF_TABLE = 'EKKO'.
LS_FCAT-OUTPUTLEN = '15' .
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Purchasing Document Date...
LS_FCAT-FIELDNAME = 'BEDAT'.
LS_FCAT-REF_TABLE = 'EKKO'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Vendor's account number...
LS_FCAT-FIELDNAME = 'LIFNR'.
LS_FCAT-REF_TABLE = 'EKKO'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Account Number of Vendor or Creditor...
LS_FCAT-FIELDNAME = 'NAME1'.
LS_FCAT-REF_TABLE = 'LFA1'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
LS_FCAT-COLTEXT = 'Vendor Name'(001).
LS_FCAT-SELTEXT = 'Vendor Name'(001).
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Creation date of the change document...
LS_FCAT-FIELDNAME = 'UDATE'.
LS_FCAT-REF_TABLE = 'CDHDR'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
LS_FCAT-COLTEXT = 'Change Date'(002).
LS_FCAT-SELTEXT = 'Change Date'(002).
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
User name of the person responsible in change document...
LS_FCAT-FIELDNAME = 'USERNAME'.
LS_FCAT-REF_TABLE = 'CDHDR'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '10'.
LS_FCAT-COLTEXT = 'Modified by'(003).
LS_FCAT-SELTEXT = 'Modified by'(003).
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Short Text Describing R/3 Repository Objects...
LS_FCAT-FIELDNAME = 'DDTEXT'.
LS_FCAT-REF_TABLE = 'DD04T'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '15'.
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
Old contents of changed field...
LS_FCAT-FIELDNAME = 'VALUE_OLD'.
LS_FCAT-REF_TABLE = 'CDPOS'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '12'.
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
New contents of changed field...
LS_FCAT-FIELDNAME = 'VALUE_NEW'.
LS_FCAT-REF_TABLE = 'CDPOS'.
LS_FCAT-INTTYPE = 'C'.
LS_FCAT-OUTPUTLEN = '12'.
APPEND LS_FCAT TO PT_FIELDCAT.
CLEAR LS_FCAT.
ENDFORM. " PREPARE_FIELD_CATALOG
*& Form SELECT_PO
Subroutine to select all the Purchase Orders
There are no interface parameters to be passed to this subroutine.
FORM SELECT_PO .
SELECT EBELN " Purchasing Document Number
ERNAM " Name of Person who Created
" the Object
LIFNR " Vendor's account number
EKGRP " Purchasing group
BEDAT " Purchasing Document Date
FROM EKKO
PACKAGE SIZE 10000
APPENDING TABLE T_EBELN
WHERE EBELN IN S_EBELN
AND BEDAT IN S_BEDAT.
ENDSELECT.
IF SY-SUBRC NE 0.
W_FLAG = 1.
MESSAGE S401(M8).
ENDIF. " IF SY-SUBRC NE 0
ENDFORM. " SELECT_PO
*& Form SELECT_OBJ_ID
Subroutine to select Object ID
There are no interface parameters to be passed to this subroutine.
FORM SELECT_OBJ_ID .
IF NOT T_EBELN IS INITIAL.
SELECT OBJECTCLAS " Object Class
OBJECTID " Object value
CHANGENR " Document change number
USERNAME " User name
UDATE " Creation date
FROM CDHDR
INTO TABLE T_CDHDR
FOR ALL ENTRIES IN T_EBELN
WHERE OBJECTID EQ T_EBELN-EBELN
AND UDATE IN S_UDATE
AND TCODE IN ('ME21N','ME22N','ME23N').
ENDSELECT.
IF SY-SUBRC NE 0.
W_FLAG = 1.
MESSAGE S833(M8) WITH 'Header Not Found'(031).
ENDIF. " IF SY-SUBRC NE 0.
ENDIF. " IF NOT T_EBELN IS INITIAL
ENDFORM. " SELECT_OBJ_ID
*& Form SELECT_CHANGED_VALUE
Subroutine to select Changed Values
There are no interface parameters to be passed to this subroutine.
FORM SELECT_CHANGED_VALUE .
IF NOT T_CDHDR IS INITIAL.
SELECT OBJECTCLAS " Object class
OBJECTID " Object value
CHANGENR " Document change number
TABNAME " Table Name
FNAME " Field Name
VALUE_NEW " New contents of changed field
VALUE_OLD " Old contents of changed field
FROM CDPOS
PACKAGE SIZE 10000
APPENDING TABLE T_CDPOS
FOR ALL ENTRIES IN T_CDHDR
WHERE OBJECTCLAS EQ T_CDHDR-OBJECTCLAS
AND OBJECTID EQ T_CDHDR-OBJECTID
AND CHANGENR EQ T_CDHDR-CHANGENR.
ENDSELECT.
IF SY-SUBRC NE 0.
W_FLAG = 1.
MESSAGE S833(M8) WITH 'Item Not Found'(032).
ENDIF. " IF SY-SUBRC NE 0.
ENDIF. " IF NOT T_CDHDR IS INITIAL
T_CDPOS_TEMP[] = T_CDPOS[].
ENDFORM. " SELECT_CHANGED_VALUE
*& Form SELECT_PUR_DOC
Subroutine to select Purchase Order Details
There are no interface parameters to be passed to this subroutine.
FORM SELECT_PUR_DOC .
IF NOT T_CDPOS IS INITIAL.
SORT T_EBELN BY EBELN.
LOOP AT T_CDPOS INTO FS_CDPOS.
READ TABLE T_EBELN INTO FS_EBELN WITH KEY EBELN =
FS_CDPOS-OBJECTID BINARY SEARCH.
IF SY-SUBRC NE 0.
DELETE TABLE T_EBELN FROM FS_EBELN.
ENDIF. " IF SY-SUBRC NE 0.
ENDLOOP. " LOOP AT T_CDPOS...
LOOP AT T_EBELN INTO FS_EBELN.
MOVE FS_EBELN-EBELN TO FS_EKKO-EBELN.
MOVE FS_EBELN-ERNAM TO FS_EKKO-ERNAM.
MOVE FS_EBELN-LIFNR TO FS_EKKO-LIFNR.
MOVE FS_EBELN-EKGRP TO FS_EKKO-EKGRP.
MOVE FS_EBELN-BEDAT TO FS_EKKO-BEDAT.
APPEND FS_EKKO TO T_EKKO.
ENDLOOP. " LOOP AT T_EBELN...
T_EKKO_TEMP[] = T_EKKO[].
ENDIF. " IF NOT T_CDPOS IS INITIAL
ENDFORM. " SELECT_PUR_DOC
*& Form SELECT_VENDOR
Subroutine to select Vendor details
There are no interface parameters to be passed to this subroutine.
FORM SELECT_VENDOR .
IF NOT T_EKKO IS INITIAL.
SORT T_EKKO_TEMP BY LIFNR.
DELETE ADJACENT DUPLICATES FROM T_EKKO_TEMP COMPARING LIFNR.
SELECT LIFNR " Account Number of Vendor or
" Creditor
NAME1 " Name 1
FROM LFA1
INTO TABLE T_LFA1
FOR ALL ENTRIES IN T_EKKO_TEMP
WHERE LIFNR EQ T_EKKO_TEMP-LIFNR.
IF SY-SUBRC NE 0.
MESSAGE S002(M8) WITH 'Master Details'(033).
ENDIF. " IF SY-SUBRC NE 0.
ENDIF. " IF NOT T_EKKO IS INITIAL
ENDFORM. " SELECT_VENDOR
*& Form DESCRIPTION
Subroutine to get the description
There are no interface parameters to be passed to this subroutine.
FORM DESCRIPTION .
IF NOT T_CDPOS IS INITIAL.
SORT T_CDPOS_TEMP BY TABNAME FNAME.
DELETE ADJACENT DUPLICATES FROM T_CDPOS_TEMP COMPARING TABNAME FNAME
SELECT TABNAME " Table Name
FIELDNAME " Field Name
ROLLNAME " Data element
FROM DD03L
INTO TABLE T_DATAELE
FOR ALL ENTRIES IN T_CDPOS_TEMP
WHERE TABNAME EQ T_CDPOS_TEMP-TABNAME
AND FIELDNAME EQ T_CDPOS_TEMP-FNAME.
IF NOT T_DATAELE IS INITIAL.
T_DATAELE_TEMP[] = T_DATAELE[].
SORT T_DATAELE_TEMP BY ROLLNAME.
DELETE ADJACENT DUPLICATES FROM T_DATAELE_TEMP COMPARING ROLLNAME.
SELECT ROLLNAME " Data element
DDTEXT " Short Text Describing R/3
" Repository Objects
FROM DD04T
INTO TABLE T_TEXT
FOR ALL ENTRIES IN T_DATAELE_TEMP
WHERE ROLLNAME EQ T_DATAELE_TEMP-ROLLNAME
AND DDLANGUAGE EQ SY-LANGU.
IF SY-SUBRC NE 0.
EXIT.
ENDIF. " IF SY-SUBRC NE 0.
ENDIF. " IF NOT T_DATAELE IS INITIAL.
ENDIF. " IF NOT T_CDPOS IS INITIAL.
ENDFORM. " DESCRIPTION
*& Form FILL_OUTTAB
Subroutine to populate the Outtab
There are no interface parameters to be passed to this subroutine.
FORM FILL_OUTTAB .
SORT T_CDHDR BY OBJECTCLAS OBJECTID CHANGENR.
SORT T_EKKO BY EBELN.
SORT T_LFA1 BY LIFNR.
SORT T_DATAELE BY TABNAME FIELDNAME.
SORT T_TEXT BY ROLLNAME.
LOOP AT T_CDPOS INTO FS_CDPOS.
READ TABLE T_CDHDR INTO FS_CDHDR WITH KEY
OBJECTCLAS = FS_CDPOS-OBJECTCLAS
OBJECTID = FS_CDPOS-OBJECTID
CHANGENR = FS_CDPOS-CHANGENR
BINARY SEARCH.
IF SY-SUBRC EQ 0.
MOVE FS_CDHDR-USERNAME TO FS_OUTTAB-USERNAME.
MOVE FS_CDHDR-UDATE TO FS_OUTTAB-UDATE.
READ TABLE T_EKKO INTO FS_EKKO WITH KEY
EBELN = FS_CDHDR-OBJECTID
BINARY SEARCH.
IF SY-SUBRC EQ 0.
MOVE FS_EKKO-EBELN TO FS_OUTTAB-EBELN.
MOVE FS_EKKO-ERNAM TO FS_OUTTAB-ERNAM.
MOVE FS_EKKO-LIFNR TO FS_OUTTAB-LIFNR.
MOVE FS_EKKO-EKGRP TO FS_OUTTAB-EKGRP.
MOVE FS_EKKO-BEDAT TO FS_OUTTAB-BEDAT.
READ TABLE T_LFA1 INTO FS_LFA1 WITH KEY
LIFNR = FS_EKKO-LIFNR
BINARY SEARCH.
IF SY-SUBRC EQ 0.
MOVE FS_LFA1-NAME1 TO FS_OUTTAB-NAME1.
ENDIF. " IF SY-SUBRC EQ 0.
ENDIF. " IF SY-SUBRC EQ 0.
ENDIF. " IF SY-SUBRC EQ 0.
MOVE FS_CDPOS-VALUE_NEW TO FS_OUTTAB-VALUE_NEW.
MOVE FS_CDPOS-VALUE_OLD TO FS_OUTTAB-VALUE_OLD.
READ TABLE T_DATAELE INTO FS_DATAELE WITH KEY
TABNAME = FS_CDPOS-TABNAME
FIELDNAME = FS_CDPOS-FNAME
BINARY SEARCH.
IF SY-SUBRC EQ 0.
READ TABLE T_TEXT INTO FS_TEXT WITH KEY
ROLLNAME = FS_DATAELE-ROLLNAME
BINARY SEARCH.
IF SY-SUBRC EQ 0.
MOVE FS_TEXT-DDTEXT TO FS_OUTTAB-DDTEXT.
ENDIF. " IF SY-SUBRC EQ 0.
ENDIF. " IF SY-SUBRC EQ 0.
APPEND FS_OUTTAB TO T_OUTTAB.
CLEAR FS_OUTTAB.
ENDLOOP.
ENDFORM. " FILL_OUTTAB
*& Form GET_CELL_INFO
Subroutine to get the Cell Information
--> W_VALUE Holds the value of Hotspot clicked
FORM GET_CELL_INFO .
CALL METHOD W_GRID->GET_CURRENT_CELL
IMPORTING
E_ROW =
E_VALUE = W_VALUE
E_COL =
ES_ROW_ID =
ES_COL_ID =
ES_ROW_NO =
ENDFORM. " GET_CELL_INFO
*& Form VALIDATE_PD_NUM
Subroutine to validate Purchase Document Number
There are no interface parameters to be passed to this subroutine.
FORM VALIDATE_PD_NUM .
IF NOT S_EBELN[] IS INITIAL.
SELECT EBELN " Purchase Document Number
FROM EKKO
INTO W_EBELN
UP TO 1 ROWS
WHERE EBELN IN S_EBELN.
ENDSELECT.
IF SY-SUBRC NE 0.
CLEAR SSCRFIELDS-UCOMM.
MESSAGE E717(M8).
ENDIF. " IF SY-SUBRC NE 0
ENDIF. " IF NOT S_EBELN[]...
ENDFORM. " VALIDATE_PD_NUM
*& Form VALIDATE_VEN_NUM
Subroutine to validate Vendor Number
There are no interface parameters to be passed to this subroutine.
FORM VALIDATE_VEN_NUM .
IF NOT S_LIFNR[] IS INITIAL.
SELECT LIFNR " Vendor Number
FROM LFA1
INTO W_LIFNR
UP TO 1 ROWS
WHERE LIFNR IN S_LIFNR.
ENDSELECT.
IF SY-SUBRC NE 0.
CLEAR SSCRFIELDS-UCOMM.
MESSAGE E002(M8) WITH W_SPACE.
ENDIF. " IF SY-SUBRC NE 0
ENDIF. " IF NOT S_LIFNR[]...
ENDFORM. " VALIDATE_VEN_NUM
*& Form VALIDATE_PUR_GRP
Subroutine to validate the Purchase Group
There are no interface parameters to be passed to this subroutine.
FORM VALIDATE_PUR_GRP .
IF NOT S_EKGRP[] IS INITIAL.
SELECT EKGRP " Purchase Group
FROM T024
INTO W_EKGRP
UP TO 1 ROWS
WHERE EKGRP IN S_EKGRP.
ENDSELECT.
IF SY-SUBRC NE 0.
CLEAR SSCRFIELDS-UCOMM.
MESSAGE E622(M8) WITH W_SPACE.
ENDIF. " IF SY-SUBRC NE 0
ENDIF. " IF NOT S_EKFRP[]...
ENDFORM. " VALIDATE_PUR_GRP
*& Form FILL_VARIANT
Subroutine to fill the Variant Structure
There are no interface parameters to be passed to this subroutine
FORM FILL_VARIANT .
Filling the Variant structure
W_VARIANT-REPORT = SY-REPID.
W_VARIANT-USERNAME = SY-UNAME.
ENDFORM. " FILL_VARIANT
<b>Reward if usefull</b> -
Interactive report for displaying customer information
hi,
how to create an interactive report for displaying customer information based on selection smade ,and corresponding bank details.pls check the sample code
Use the tables Kna1 and knbk to get the customer details.
***extract the data into internal table
select * from dbtab into itab.
*In the loop hide the field you want to trigger the interactive list.
loop at itab.
write: / itab-kunnr, itab-name1.
Hide itab-kunnr.
endloop.
use at line selecton to get desired output based on the condition
at line-selection.
select * fro dbab into itab where field = itab-kunnr.
awards points if help ful. -
[SOLVED] "Server is already active for display 0" in Terminals
So far, my searches haven't yielded any solutions to this.
When my system starts, it boots to a console login prompt (no gdm, etc...) and I have 'startx' in my .bashrc to start my desktop. The desktop starts and functions fine (or so it seems).
Problem 1: Anytime I open a Terminal window (or open new tabs inside a Terminal) I am greeted with the following:
Fatal server error:
Server is already active for display 0
If this server is no longer running, remove /tmp/.X0-lock
and start again.
Please consult the The X.Org Foundation support
at http://wiki.x.org
for help.
xinit: Server error.
Sometimes the last line is:
xinit: unexpected signal 2
Usually I just ^C to get a working prompt and go about my business, but this is getting really annoying.
Problem 2: I use Guake terminal and have it set to autostart in my .bashrc, but it doesn't work until I manually open a Terminal window. And if I close that (manually opened) window, Guake stops working. If I open another one manually, it works again...etc. I have a hunch this is related to the first problem.
Any nudges in the right direction would be appreciated.
My environment:
DE = Xfce4
Kernel = 2.6.31-ARCH
Xorg = xorg-server 1.7.3.901-1
Video = xf86-video-ati 6.12.99.git20091014-1
/etc/X11/xorg.conf:
Section "ServerFlags"
Option "AutoAddDevices" "True"
Endsection
Section "ServerLayout"
Identifier "X.org Configured"
Screen 0 "Screen0" 0 0
InputDevice "Mouse0" "CorePointer"
InputDevice "Keyboard0" "CoreKeyboard"
EndSection
Section "Files"
ModulePath "/usr/lib/xorg/modules"
FontPath "/usr/share/fonts/misc"
FontPath "/usr/share/fonts/100dpi:unscaled"
FontPath "/usr/share/fonts/75dpi:unscaled"
FontPath "/usr/share/fonts/TTF"
FontPath "/usr/share/fonts/Type1"
EndSection
Section "Module"
Load "glx"
Load "extmod"
Load "dri2"
Load "dbe"
Load "dri"
EndSection
Section "InputDevice"
Identifier "Keyboard0"
Driver "kbd"
EndSection
Section "InputDevice"
Identifier "Mouse0"
Driver "mouse"
Option "Protocol" "auto"
Option "Device" "/dev/input/mice"
Option "ZAxisMapping" "4 5 6 7"
EndSection
Section "Monitor"
#DisplaySize 340 190 # mm
Identifier "Monitor0"
VendorName "AUO"
ModelName "10ec"
EndSection
Section "Device"
### Available Driver options are:-
### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
### [arg]: arg optional
#Option "NoAccel" # [<bool>]
#Option "SWcursor" # [<bool>]
#Option "Dac6Bit" # [<bool>]
#Option "Dac8Bit" # [<bool>]
#Option "BusType" # [<str>]
#Option "CPPIOMode" # [<bool>]
#Option "CPusecTimeout" # <i>
#Option "AGPMode" # <i>
#Option "AGPFastWrite" # [<bool>]
#Option "AGPSize" # <i>
#Option "GARTSize" # <i>
#Option "RingSize" # <i>
#Option "BufferSize" # <i>
#Option "EnableDepthMoves" # [<bool>]
#Option "EnablePageFlip" # [<bool>]
#Option "NoBackBuffer" # [<bool>]
#Option "DMAForXv" # [<bool>]
#Option "FBTexPercent" # <i>
#Option "DepthBits" # <i>
#Option "PCIAPERSize" # <i>
#Option "AccelDFS" # [<bool>]
#Option "IgnoreEDID" # [<bool>]
#Option "CustomEDID" # [<str>]
#Option "DisplayPriority" # [<str>]
#Option "PanelSize" # [<str>]
#Option "ForceMinDotClock" # <freq>
#Option "ColorTiling" # [<bool>]
#Option "VideoKey" # <i>
#Option "RageTheatreCrystal" # <i>
#Option "RageTheatreTunerPort" # <i>
#Option "RageTheatreCompositePort" # <i>
#Option "RageTheatreSVideoPort" # <i>
#Option "TunerType" # <i>
#Option "RageTheatreMicrocPath" # <str>
#Option "RageTheatreMicrocType" # <str>
#Option "ScalerWidth" # <i>
#Option "RenderAccel" # [<bool>]
#Option "SubPixelOrder" # [<str>]
#Option "ShowCache" # [<bool>]
#Option "ClockGating" # [<bool>]
#Option "VGAAccess" # [<bool>]
#Option "ReverseDDC" # [<bool>]
#Option "LVDSProbePLL" # [<bool>]
#Option "AccelMethod" # <str>
#Option "DRI" "True" # [<bool>]
#Option "ConnectorTable" # <str>
#Option "DefaultConnectorTable" # [<bool>]
#Option "DefaultTMDSPLL" # [<bool>]
#Option "TVDACLoadDetect" # [<bool>]
#Option "ForceTVOut" # [<bool>]
#Option "TVStandard" # <str>
#Option "IgnoreLidStatus" # [<bool>]
#Option "DefaultTVDACAdj" # [<bool>]
#Option "Int10" # [<bool>]
#Option "EXAVSync" # [<bool>]
#Option "ATOMTVOut" # [<bool>]
#Option "R4xxATOM" # [<bool>]
#Option "ForceLowPowerMode" # [<bool>]
#Option "DynamicPM" # [<bool>]
Identifier "Card0"
Driver "radeon"
VendorName "ATI Technologies Inc"
BoardName "RS780M/RS780MN [Radeon HD 3200 Graphics]"
BusID "PCI:1:5:0"
EndSection
Section "Screen"
Identifier "Screen0"
Device "Card0"
Monitor "Monitor0"
SubSection "Display"
Viewport 0 0
Depth 1
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 4
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 8
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 15
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 16
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
/var/log/Xorg.0.log (filtered through grep for (WW) and (EE)):
(EE) RADEON(0): [dri] RADEONDRIGetVersion failed to open the DRM
(EE) RADEON(0): Acceleration initialization failed
(WW) AllowEmptyInput is on, devices using drivers 'kbd', 'mouse' or 'vmmouse' will be disabled.
(WW) Disabling Mouse0
(WW) Disabling Keyboard0
(WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
(WW) RADEON(0): LVDS Info:
(WW) RADEON(0): Direct rendering disabled
~/.xsession-errors:
/etc/gdm/Xsession: Beginning session setup...
/etc/gdm/Xsession: ssh-agent not found!
/etc/gdm/Xsession: Setup done, will execute: gnome-session
gnome-session[28618]: WARNING: Could not parse desktop file /home/jon/.config/autostart/xfce4-tips-autostart.desktop: Key file does not have key 'Name'
gnome-session[28618]: WARNING: could not read /home/jon/.config/autostart/xfce4-tips-autostart.desktop
gnome-session[28618]: WARNING: Could not parse desktop file /home/jon/.config/autostart/xfce4-settings-helper-autostart.desktop: Key file does not have key 'Name'
gnome-session[28618]: WARNING: could not read /home/jon/.config/autostart/xfce4-settings-helper-autostart.desktop
gnome-session[28618]: EggSMClient-WARNING: Invalid Version string '0.9.4' in /home/jon/.config/autostart/wicd.desktop
gnome-session[28618]: WARNING: Unable to find provider 'metacity' of required component 'windowmanager'
gnome-session[28618]: WARNING: Unable to find provider 'nautilus' of required component 'filemanager'
GNOME_KEYRING_SOCKET=/tmp/keyring-6lpdg3/socket
SSH_AUTH_SOCK=/tmp/keyring-6lpdg3/socket.ssh
(gnome-panel:28681): Gtk-CRITICAL **: gtk_accelerator_parse: assertion `accelerator != NULL' failed
** (gnome-panel:28681): WARNING **: Unable to parse mouse modifier '(null)'
tput: No value for $TERM and no -T specified
tput: No value for $TERM and no -T specified
tput: No value for $TERM and no -T specified
Can't locate XML/Parser.pm in @INC (@INC contains: /usr/lib/perl5/site_perl/5.10.1 /usr/share/perl5/site_perl/5.10.1 /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5/core_perl /usr/share/perl5/core_perl /usr/lib/perl5/current /usr/lib/perl5/site_perl/current .) at /usr/lib/xfce4/xfconf-migration/xfconf-migration-4.6.pl line 20.
BEGIN failed--compilation aborted at /usr/lib/xfce4/xfconf-migration/xfconf-migration-4.6.pl line 20.
(polkit-gnome-authentication-agent-1:28707): GLib-GObject-WARNING **: cannot register existing type `_PolkitError'
(polkit-gnome-authentication-agent-1:28707): GLib-CRITICAL **: g_once_init_leave: assertion `initialization_value != 0' failed
tput: No value for $TERM and no -T specified
tput: No value for $TERM and no -T specified
tput: No value for $TERM and no -T specified
Unable to open desktop file epiphany.desktop for panel launcher
Unable to open desktop file evolution.desktop for panel launcher
/usr/lib/python2.6/site-packages/wicd/gui.py:151: GtkWarning: gtk_toolbar_set_icon_size: assertion `icon_size != GTK_ICON_SIZE_INVALID' failed
self.wTree = gtk.glade.XML(gladefile)
ERROR:dbus.proxies:Introspect error on :1.70:/org/wicd/daemon: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NoReply: Message did not receive a reply (timeout by message bus)
ERROR:dbus.proxies:Introspect error on :1.70:/org/wicd/daemon: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NoReply: Message did not receive a reply (timeout by message bus)
ERROR:dbus.proxies:Introspect error on :1.70:/org/wicd/daemon: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NoReply: Message did not receive a reply (timeout by message bus)
Importing pynotify failed, notifications disabled.
Has notifications support False
Loading...
Connecting to daemon...
Can't connect to the daemon, trying to start it automatically...
Connected.
warning: ignoring exception org.freedesktop.DBus.Error.ServiceUnknown: The name :1.70 was not provided by any .service files
warning: ignoring exception org.freedesktop.DBus.Error.ServiceUnknown: The name :1.70 was not provided by any .service files
Importing pynotify failed, notifications disabled.
Has notifications support False
Loading...
Connecting to daemon...
Can't connect to the daemon, trying to start it automatically...
Connected.
warning: ignoring exception org.freedesktop.DBus.Error.ServiceUnknown: The name :1.70 was not provided by any .service files
(firefox:30931): GLib-WARNING **: g_set_prgname() called multiple times
Registering '@mozilla.org/module-loader/python;1' (libpyloader.so)
Registering '@mozilla.org/network/protocol/about;1?what=python' (pyabout.py)
(Terminal:32576): Terminal-WARNING **: Unable to load terminal preferences.
(firefox:1968): GLib-WARNING **: g_set_prgname() called multiple times
(Terminal:5816): Terminal-WARNING **: Unable to load terminal preferences.
(Terminal:9027): Terminal-WARNING **: Unable to load terminal preferences.
(Terminal:9027): Gtk-CRITICAL **: gtk_widget_realize: assertion `GTK_WIDGET_ANCHORED (widget) || GTK_IS_INVISIBLE (widget)' failed
(Terminal:9027): Gtk-CRITICAL **: gtk_widget_realize: assertion `GTK_WIDGET_ANCHORED (widget) || GTK_IS_INVISIBLE (widget)' failed
(Terminal:9027): Gdk-CRITICAL **: gdk_drawable_get_screen: assertion `GDK_IS_DRAWABLE (drawable)' failed
polkit-gnome-authentication-agent-1: Fatal IO error 11 (Resource temporarily unavailable) on X server :1.0.
firefox: Fatal IO error 2 (No such file or directory) on X server :1.0.
Thanks,
Munky
Last edited by munkyeetr (2010-01-13 20:26:51)In bashrc try something like
[ -z "$DISPLAY" ] && startx && {sleep 5; DISPLAY=0:0 setsid Guake; }
Maybe you are looking for
-
Problem sending .pdf with email in ECC 6.0
hi there, we are upgrading from r/3 4.6.c to ECC 6.0. i have the following problem: in many z-ababs we convert spool-files to pdf-files and send them with function SO_NEW_DOCUMENT_ATT_SEND_API1 via email. well, this is working okay, BUT: the ending '
-
LR2 renders PSCS2 files incorrectly
The problem goes like this: If I work on a picture in LR2, then edit it in PSCS3, it works fine. Printing in either PS or LR2 results in exactly the same print. The on-screen previews in LR2 are fine. If, on the other hand, I find a picture that had
-
Difference in ECC & SWI1 ?
hi Whats the main Difference between ECC 6.0 and SWI1 in SAP 4.6C ?
-
How to uninstall a DMG application
My question is just what it says. How do you uninstall a DMG application? Please don't say "Just drag it to the trash" because that's not uninstallation. I installed Adobe Reader and found it was slower than Preview, so I was looking for a way to uni
-
Hi, I need to send a message to a MQ Queue and automatically forward that message to another MQ Queue, so the first queue acts like a proxy. This capability is available in MQ Series API but, I need to use only JMS api. Regards, arturo