How to build my own SELECT-OPTIONS?
Hi experts,
I hv 4 values like for a field, (say VBAK-BNAME),
NAME_A
NAME_D
NAME_M
NAME_Z
My selection- screen is like,
SELECT-OPTIONS: MANAGER FOR VBAK-BNAME.
So,
1) How to build the SELECT-OPTIONS table in my ABAP code?
I mean, if the user enters the NAME_A TO NAME_Z in select-options, the system shuld take in-between NAMEs also!
(Actually, I thiught that, the SAP will take care of building the select-options table based on Alphabetical Order, but, When I observed in debug mode, its not like that!)
2) And Where I hv to write the code for building select-options? I mean, Is it DATA DECLARATION part, AT SELECTION SCREEN or AT SELECTION SCREEN OUTPUT or START OF SELECTION?
thanq.
Message was edited by:
Sridhar
Message was edited by:
Sridhar
Hi,
Pls. suggest me other than RANGES?
Well, if you don't want to use RANGE then you can do it at SELECT statement.
SELECT BNAME
INTO TABLE ITAB
FROM VBAK
WHERE BNAME IN ( NAME_A, NAME_D, NAME_M, NAME_Z )
OR
SELECT BNAME
INTO TABLE ITAB
FROM VBAK
WHERE BNAME BETWEEN 'NAME_A' AND 'NAME_Z'.
2) under which event i hv to write it?
If you are using in SELECT statement, then you use at START-OF-SELECTION.
If you are buiding RANGE, then you can use at any events such as INITIALIZATION, AT SELECTION-SCREEN OUTPUT, START-OF-SELECTION, etc.
Regards,
Ferry Lianto
Similar Messages
-
How to define our own selection screen for logical database in abap-hr?
Hi Friends,
Can u please help me
How to define your own selection screens for logical database.
we use to do like(goto->attributes-HRReportcatagerious ).but How to desin using customer table like t599c, t599f and how to add to my logical database?
Thanks in advance
charancheck out this online help
http://help.sap.com/saphelp_erp2004/helpdata/en/9f/dba65c35c111d1829f0000e829fbfe/frameset.htm
Regards
Raja -
How can we pass the select-option value to modulepool program?
hi,
how can we pass the select-option value to modulepool program ?
Because if i declared select-options in executable program and i used SSCRFIELDS to define push buttons in selection screen.
My requirement if enter the values to select-options and press UPDATE pussbotton then i want call screen which contains tablecontrol.
How i get select-option values to PAI of call screen for getting the data from database table to my internal table?Oh I thought that you have selection-screen and again you are working on dialog programming.
if you want to use select-option directly in module pool then it is not possible.
but you can do other way.
create two varaiables
data : v_kun_low like kna1-kunnr,
v_kun_high like kna1-kunnr.
use these two variables in layout ,let user knows that he can not give options like gt,lt,eq ,it will be always BT.
and also when you see normal report program,you can use multiple values in either low or high,but here it is not possibel.
use can enter only low value and high value.
when you come to program point of view
declare one range
ranges r_kunnr for kna1-kunnr.
do the coding like
r_kunnr-low = v_kun_low.
r_kunnr-high = v_kun_high.
r_kunnr-options = 'BT'.
r_kunnr-sign = 'I'.
append r_kunnr.
now you can use r_kunnr in select query ,it will work like select-option.
other than this there is no option.
Thanks
Seshu -
How I build my own libraries of classes/methods in java ?
How I build my own libraries of classes/methods in java ? how then I refer a functionX() (i mean method) in LibraryX ? can you give a short/brief example of a library with a class with a method and a main method of normal class calling this method (of external's added library's) ?
Just another cross poster.
[http://www.java-forums.org/new-java/12389-how-i-build-my-own-libraries-classes-methods-java.html]
db
edit And [http://forums.java.net/jive/thread.jspa?messageID=305387]
Edited by: Darryl.Burke -
How to do validations for select-options
Hi gurus,
can you suggest me
how to do validations for select-options
Thanks&ragards,
Kals.HI,
TABLES: BKPF.
TYPES: BEGIN OF TY_BKPF,
BUKRS TYPE BUKRS, "COMPANY CODE
GJAHR TYPE GJAHR, "FISCAL YEAR
MONAT TYPE MONAT, "FISCAL PERIOD
DATA: T_BKPF TYPE TABLE OF TY_BKPF,
W_BKPF TYPE TY_BKPF.
SELECTION-SCREEN : BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
SELECT-OPTIONS: S_CODE FOR BKPF-BUKRS,
S_YEAR FOR BKPF-GJAHR,
S_PERIOD FOR BKPF-MONAT.
SELECTION-SCREEN: END OF BLOCK B1.
AT SELECTION-SCREEN *
IF S_CODE IS INITIAL OR S_YEAR IS INITIAL OR S_PERIOD IS INITIAL.
MESSAGE E000(0) WITH 'ENTER VLAUES'.
ENDIF.
SELECT SINGLE * FROM BKPF WHERE BUKRS IN S_CODE.
IF SY-SUBRC <> 0.
MESSAGE E000(0) WITH 'ENTER VALID VALUES'.
ENDIF.
reward if useful
thanks and regards -
How to use offset for select-option parameter ?
Hi experts
could anybody please let me know how to use offset for select-option parameter. i can able to use offset for table fields, variabiles and all , but don't know how to use for parameters.
following is my code
SELECT-OPTIONS: s_prctr FOR vbsegs-prctr OBLIGATORY.
here "prctr" length is 10.
i'm using two tables 1. vbsegd-bupla
2. vbsegs-prctr
here prctr+6(4) = bupla.
"Bupla" length is 4
SELECT belnr gjahr bukrs bupla sgtxt buzei FROM vbsegd INTO CORRESPONDING FIELDS OF TABLE it_vbsegd FOR ALL ENTRIES IN it_vbkpf
WHERE belnr = it_vbkpf-belnr
AND gjahr = it_vbkpf-gjahr
AND bukrs = it_vbkpf-bukrs
AND bupla IN s_prctr.
the above statement is not working as prctr and bupla lenths are different. here i want to use offset.
SELECT belnr gjahr bukrs prctr sgtxt buzei FROM vbsegs INTO CORRESPONDING FIELDS OF TABLE it_vbsegs FOR ALL ENTRIES IN it_vbkpf
WHERE belnr = it_vbkpf-belnr
AND gjahr = it_vbkpf-gjahr
AND bukrs = it_vbkpf-bukrs
AND prctr IN s_prctr.
this is working as prctr and s_prctr lengths are equal.
could anybody please help me out in this.
Thanks in advance.
regards
satishBelow code will work for you.
SELECT-OPTIONS: s_prctr FOR vbsegs-prctr OBLIGATORY.
RANGES: s_bupla FOR vbsegd-bupla.
s_bupla[] = s_prctr[].
DELETE ADJACENT DUPLICATES FROM s_bupla.
SELECT belnr gjahr bukrs bupla sgtxt buzei FROM vbsegd INTO CORRESPONDING FIELDS OF TABLE it_vbsegd FOR ALL ENTRIES IN it_vbkpf
WHERE belnr = it_vbkpf-belnr
AND gjahr = it_vbkpf-gjahr
AND bukrs = it_vbkpf-bukrs
AND bupla IN s_bupla. -
How to pass values to select options of custom transactions?
I have to call custom transaction-ZMM_POST from my custom report.
I have to pass values to select options(Not to parameters) of ZMM_POST from my report only.
Please tell me how to pass values to select options of custom transactions?Have you tried this?
DATA: T_RSPARAMS TYPE STANDARD TABLE OF RSPARAMS WITH HEADER LINE.
T_RSPARAMS-SELNAME = "S_BUKRS".
T_RSPARAMS-KIND = "S".
T_RSPARAMS-SIGN = "I".
T_RSPARAMS-OPTION = "BT".
T_RSPARAMS-LOW = "100".
T_RSPARAMS-HIGH = "300"
APPEND T_RSPARAMS.
SUBMIT Z_DUMMY WITH SELECTION-TABLE T_RSPARAMS.
Greetings,
Blag. -
How to develop ALV and select-option element in BSP? Help!
Hi Experts,
I have a requirement where I have a selection screen with 3 select-option elements and a search button. On clicking the search button an ALV table report has to be shown.
The ALV table is used for new row/rows entry, delete row/rows and update row/rows data. This is something like table control in normal ABAP.
Additionaly, I want the download to Excel, sorting, filtering, column swapping options in ALV.
How can I achieve this in BSP?
Is there any existing SElect-option and ALV component in BSP?
Any code sample will be really helpfull.
How much development time will it take?
Please help!
Thanks
GopalI think you will find that most of what you are looking for does NOT exist out of the box for BSP. There is no delivered selection-option or value help. I ended up creating my own over the years (You can find some versions online here in SDN in my weblogs - however a complete implementation of select-options was only delivered along with the Advanced BSP Programming book).
There is no ALV either. However with the htmlb:tableView, you can acomplish quite a bit. You may have to learn about table view iterators to get it all done. Downloading to Excel also isn't delivered. I developed a reusable BSP Extension element for this as well (can be found on SDN in my weblogs or with the Advanced BSP Programming book).
If you plan to recreate all these elements by yourself, your project will take some time. It took a while to build so many complex UI elements.
What release are you running on? In Netweaver04S you have Web Dynpro ABAP. WDA has delivered components for value help, select-options, and ALV. -
How to read data from select Options in another view without using context
I have 2 views, one for selection screen and another for displaying result.
In selection screen view I have define a select options with the help of webdynpro component.
Now my object is display result in result view based on entry of selection screen.
I don't want to do binding in context node, without that how I can read data of select option
in result view?
Regards,
Rasmi Ranjan MishraSolve by own.
If I define the Select options in component controller, then it will be global in nature. so i can get the value of select options
in another view also.
Regards,
Rasmi Ranjan Mishra -
ECC6.0 t-code COOIS - how to get the "Profile" select-option list
Hi PP Gurus
We are implementing ECC6.0
We upgraded one of the systems from 4.7 to ECC6.0 (and also kept data: documents, users profiles, variants,u2026etc).
My question is regarding standard transaction COOIS.
I do comparison in current 4.7 and ECC6.0 systems (I have SAP_ALL and SAP_NEW in both systems).
The thing is that in our ECC6.0 system the transaction COOIS doesnu2019t display Profile on select-options screen.
There are only the following items (select-option screen of COOIS in ECC6.0):
-LIST
-LAYOUT
-Prod.orders checkbox
-Planned orders checkbox
u2026And u2018Selectionu2019 tab with other fields
In the current Enterprise 4.7 system the transaction COOIS displays the following select-option screen:
-LIST
-PROFILE
-LAYOUT
-Prod.orders checkbox
-Planned orders checkbox
u2026And u2018Selectionu2019 tab with other fields
Questions:
1. Is that possible to maintain / see and select a PROFILE in COOIS of ECC6 (or due to new functionality it no more available on that screen ?) How to do that?
2. Looking at layouts (I ran COOIS in two systems and compared the results) I canu2019s see in ECC6.0 some icons like u2018Refreshu2019, u2018Order logu2019, u2018Display order componentsu2019, u2018Long textu2019 , u2026.) But all of them are in 4.7 layout. How to get them in ECC6.0 ?
What I have already explored:
u2022 ECC6.0 has a new config. t-code COISN (4.7 has only COIS) . I created my new overall profile there, set my own layout, but running COOIS still canu2019t see/use the PROFILE;
u2022 I have compared the standard structure PPIO_ENTRY_SC1100 in 4.7 and ECC6.0 and found the new component COIS_LISTTYP in ECC6.0. In this situation I ran a new t-code u201CDefine New List Typesu201D (it doesnu2019t exist in 4.7) and created my new entry, but still canu2019t see PROFILE on select-option screen of COOIS in ECC6.0;
u2022 I also tried situation when both config. transaction COIS (in 4.7 and ECC6.0) had the SAME overall profiles u2013 still canu2019t see PROFILE on select-option screen of COOIS in ECC6.0;
u2022 I found a new icon u201CNavigation profileu201D in result layout of COOIS ECC6.0 Is that right place where I can maintain the icons I need (see my second question) ?
THANK YOU.Hi,
The reports are modified if am right as of ECC 5.0. Refer to note - 747469 which gives a list of all reports modified.
If am right by profile you mean navigation profile, this is now in the display screen. The content remains, only thing is the layout is modified & more structured. So i would suggest you to have a look around in COOIS report & you will find the info.
The navigation profile is adjacent to the icon called Environment (its a drop down list).
Revert if you face any issues.
Regards,
Vivek -
How to build my own SOAP envelope
Hi
after a lot of work I have now realised that my SOAP to SOAP scenario can't use SAP XI std SOAP ENVELOPE on the receiver part.
How to I build my own SOAP ENV in my RECEIVER payload? iMaybe in the mapping or in the WSDL/XSD?
Any guides or experienses are welcome
hope someone can help
cheersHi Bowie,
Here is one possible approach...
1) Set "Do Not Use SOAP Envelope" in your Receiver SOAP Adapter.
2) Add this xsl as a second step in your interface mapping.
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope">
<env:Body>
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</env:Body>
</env:Envelope>
</xsl:template>
<xsl:template match="@*|node()">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
You can then modify the soap envelope nodes above to create what you need.
-Russ -
How to display our own selected data in a search help using a exit
Hello,
I had created a Search Help Exit to restrict the values to be displayed in the search help. This code was written under the event 'DISP' in the exit. But it is not giving the desired result. So I want to replace the RECORD_TAB of the exit with my own selected data. For this I had written code for selection under the event 'SELECT'. But when I try to overwrite RECORD_TAB with this, this create errors.
What should I do to overwrite the values of the RECORD_TAB field with my own values?
Regards,
AbijithHi,
This is how we implemented the code modify the values in search help exit.
Check if display process button is pressed
IF callcontrol-step = 'DISP'.
Read the parameter ID for company code.
GET PARAMETER ID 'BUK' FIELD lv_bukrs.
IF sy-subrc EQ 0.
lwa_bukrs-sign = 'I'.
lwa_bukrs-option = 'EQ'.
lwa_bukrs-low = lv_bukrs.
APPEND lwa_bukrs TO lr_bukrs.
ENDIF.
Check if any entry is made in Test account/Testity account name
LOOP AT shlp-selopt INTO lwa_selopt.
CASE lwa_selopt-shlpfield.
WHEN 'ZZTEST'.
lwa_roy-sign = lwa_selopt-sign.
lwa_roy-option = lwa_selopt-option.
lwa_roy-low = lwa_selopt-low.
APPEND lwa_roy TO lr_roy.
WHEN 'ZZTEST_NAME'.
lwa_roy_name-sign = lwa_selopt-sign.
lwa_roy_name-option = lwa_selopt-option.
lwa_roy_name-low = lwa_selopt-low.
APPEND lwa_roy_name TO lr_roy_name.
ENDCASE.
ENDLOOP.
Get customer in entered for a company code
SELECT kunnr
bukrs
FROM knb1
INTO TABLE lt_knb1
WHERE kunnr IN lr_roy
AND bukrs IN lr_bukrs.
IF sy-subrc EQ 0.
SORT lt_knb1 BY kunnr.
Get customer name for the customer.
SELECT kunnr
name1
FROM kna1
INTO TABLE lt_kna1
FOR ALL ENTRIES IN lt_knb1
WHERE kunnr EQ lt_knb1-kunnr
AND mcod1 IN lr_roy_name.
IF sy-subrc EQ 0.
SORT lt_kna1 BY kunnr.
ENDIF.
ENDIF.
Get Values for Testty account selected by standard search help
CALL FUNCTION 'F4UT_PARAMETER_VALUE_GET'
EXPORTING
parameter = 'Ztest'
fieldname = 'Ztest' " Reference to search help parameter
TABLES
shlp_tab = shlp_tab " Reference to field of Seatinfo
record_tab = record_tab
results_tab = lt_test_help
CHANGING
shlp = shlp
callcontrol = callcontrol.
Get Values for Testty account Name selected by standard search help
CALL FUNCTION 'F4UT_PARAMETER_VALUE_GET'
EXPORTING
parameter = 'Ztest1'
fieldname = 'Ztest1' " Reference to search help parameter
TABLES
shlp_tab = shlp_tab " Reference to field of Seatinfo
record_tab = record_tab
results_tab = lt_roy_help
CHANGING
shlp = shlp
callcontrol = callcontrol.
LOOP AT lt_knb1 INTO lwa_knb1.
CLEAR lwa_kna1.
READ TABLE lt_kna1
INTO lwa_kna1
WITH KEY kunnr = lwa_knb1-kunnr
BINARY SEARCH.
IF sy-subrc EQ 0.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = lwa_kna1-kunnr
IMPORTING
output = lv_kunnr.
lwa_roy_help-ztest1 = lv_kunnr.
lwa_roy_help-ztest = lwa_kna1-name1.
APPEND lwa_roy_help TO lt_roy_help .
ENDIF.
ENDLOOP.
SORT lt_ztest_help.
DELETE ADJACENT DUPLICATES FROM lt_roy_help COMPARING ZTEST1.
Finally transport the computed numbers into the search help data.
CALL FUNCTION 'F4UT_PARAMETER_RESULTS_PUT'
EXPORTING
parameter = 'ZTEST1'
fieldname = 'ZTEST1'" Reference to search help parameter
TABLES
shlp_tab = shlp_tab " Reference to field of Seatinfo
record_tab = record_tab
source_tab = lt_roy_help
CHANGING
shlp = shlp
callcontrol = callcontrol.
Finally transport the computed numbers into the search help data.
CALL FUNCTION 'F4UT_PARAMETER_RESULTS_PUT'
EXPORTING
parameter = 'ZTEST''
fieldname = 'ZTEST'' " Reference to search help parameter
TABLES
shlp_tab = shlp_tab " Reference to field of Seatinfo
record_tab = record_tab
source_tab = lt_roy_help
CHANGING
shlp = shlp
callcontrol = callcontrol.
ENDIF.
Nabheet -
How to set the parameter selection *optional* for each subreport?
Hi,
I am using Crystal Reprots 11.
I create 10 subreports, and each subreport contains a Parameters Field.
The 10 subreports are put in 10 footer sections in increasing order, i.e. subreport1, subreport2, subreport3, ..., subreport10.
When I use "Print Preview" to take a look at the whole report, CR prompts a "Edit Values" window for selecting parameter values for all 10 subreports.
For example, if I only select parameter values for subreport1 and click "OK", 9 error messages on the "Edit Values" window come out above the selection list box of every other subreports (i.e. subreport2 ~ subreport10) showing that: 'The value is not valid'.
Sometimes, I just want to review some specific subreports but not all.
How should I do to set the parameter selection optional (not mandatory) for each subreport?
Thank you in adavance.
Edited by: Holdup on Feb 17, 2012 3:44 PMHi,
Here's how you can make the prompts optional (Assuming you're using CR 2008 or higher):
1) Go into each subreport
2) You should see the parameter in the Field Explorer. Right-click the name and select Edit > Look for an option called 'Optional Prompt'. Set it to true
3) If you have a record selection in the subreport, then you need to modify the selection formula to something like this:
if not(hasvalue({?Parameter_Name})) then True else = {?Parameter_Name}
Hope this helps!
-Abhilash -
How to build your own install img?
How do I build my own arch install image...iirc there are tools but I don't know how to use them.
Also is it possible to use the usb .img installer off of one's harddrive? I know I can use dd to put it on a partition, but was wondering if it would be able to boot and install properly.This is from an email by Dieter to the arch-releng list:
git clone http://projects.archlinux.org/git/archiso.git
cd archiso/archiso
sudo make install #to be packaged later
cd ../configs/install-iso
# change version in Makefile
# if on x86_64, remove intel-536ep and intel-537 from packages.list
./buildall.sh
scp release/* ...somewhere... -
How to add OBLIGATORY for SELECT-OPTIONS
Hi experts,
I can use OBLIGATORY for PARAMETERS
PARAMETERS :s_WMno TYPE LINK-LGNUM DEFAULT 'SCA' OBLIGATORY.
I want to add OBLIGATORY for SELECT-OPTIONS. How to do this?
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME .
SELECT-OPTIONS: s_matnr FOR mara-matnr .
SELECTION-SCREEN END OF BLOCK b1.
Many thanks.Hi,
TABLES spfli.
SELECT-OPTIONS : carrid FOR spfli-carrid OBLIGATORY. " This makes only Low field Obligatory
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF screen-name = 'CARRID-HIGH'. " To make High field also obligatory
screen-required = 1.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
Cheerz
Ram
Maybe you are looking for
-
Non SD invoice in COPA reporting and other expenses
Hi Guys, With reference to my previous thread, is it the right way to assign non SD invoice to value fields thru PA transfer structure. What would be the business impact of this. and do we need to do assessment to this PA trasfer structure. And how t
-
Looking for a Dictation App for my Iphone and MacBook Pro. Want to send all dictation to Word. I have Dragon. Should I purchase Dragon Premium or Dragon for Mac?
-
your not register as developer Please register in the OSS How would i know weather i am getting error for old systemBW3.5 or new systemBI7.0 Please some can tell me how would i find this ? does it identify with installation number
-
Photoshop document size problem.
When I set the display settings to make more working space, Photoshop CC is showing wrong document size. It's scaling down both interface and the very document, what it shouldn't... it should scale down only the interface, and leave the document size
-
Your system administrator has restricted access to this app.
Enabled the Endpoint role on primary site server. Enabled Endpoint protection in Default Client Settings We have Default Client Antimalware Policy set. When I click on System Center EndPoint Protection in All Programs I get following error: Your syst