How to get the variant?
Hi,
I want to save the values used in selection screen of the classical report as variant and inturn use that variant while submit the report.
Please tell me how can I save that variant.
hi ,
1. if you want your fields to always have fixed values(variants) and avoid selecting variants, you can have default values for the variables. in the variable change screen, you can assign them.
or else, you can have personalised values for your user. when u are on the first screen where you need to input values, there is a icon "personalise values". check it out. you can have those values(variants)always populated for your login.
2. if you dont want to enter values at the runtime, you can remove the "user input variables" and restrict the query in the definition as per the required values.
or else you can have authorisation variables authorising users for certain values, and the query will run as per the values for which the respective user is authorised.
Hope this helps..
regards,
venkat.
Similar Messages
-
How to get the VARIANT name in the program
Hi Guys,
Can somebody tell me how to get the VARIANT name in a program.
I have to perform some code with specific variant only. So I want to check in program which variant has been used to call the program.
Thanks,Hi,
Variants are stored in table VARI and VARID.
You can use RS_ALL_VARIANTS_4_1_REPORT to get all the variants for a report program.
please check out the link below it will be helpful to you
Re: Programs for a transaction variant
Hope this helps.
ashish -
How to get the variants for LAV LIST or GRID?
Hi,
How to get the variants which are stored in table like JVSO1, using function module REUSE_ALV_VARIANT_F4 ?
Thanks.Hi,
Delcare
DATA : st_variant TYPE disvariant, "Work area for variant
st_variant1 TYPE disvariant. "Work area for variant
SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-041.
PARAMETERS : p_varnt TYPE disvariant-variant MODIF ID md8. "Variant
SELECTION-SCREEN END OF BLOCK b3.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_varnt.
*--Local Variables
DATA: l_exit(1) TYPE c. "ALV exit
*--Call the function module to display the list of Variants
CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
EXPORTING
is_variant = st_variant
i_save = c_save
IMPORTING
e_exit = l_exit
es_variant = st_variant1
EXCEPTIONS
not_found = 1
program_error = 2.
*--Check Subrc
IF sy-subrc <> 2 AND l_exit IS INITIAL.
p_varnt = st_variant1-variant.
ENDIF.
start-of-selection.
IF NOT p_varnt IS INITIAL.
CLEAR st_variant1.
MOVE st_variant TO st_variant1.
MOVE p_varnt TO st_variant1-variant.
*--Call the function module to check the variant exist
CALL FUNCTION 'REUSE_ALV_VARIANT_EXISTENCE'
EXPORTING
i_save = c_save
CHANGING
cs_variant = st_variant1.
st_variant = st_variant1.
ENDIF.
DATA : lv_repid TYPE sy-repid.
*--Pass the Report name
lv_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = lv_repid
it_fieldcat = it_fcat
is_variant = st_variant
it_events = it_events
i_save = 'A'
i_callback_user_command = 'USER_COMMAND'
TABLES
t_outtab = it_zsd_ra
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE e368(00) WITH 'Alv Display failed'(044) .
ENDIF.
regards,
Prashant -
How to get the variant name from the Selection Screen
Hi Friends,
I have a Selection Screen with Variants.In the Report which is classical,i need to get the <b>name</b> of the variant which is used in the selection screen..Can anyone help me in this?You can use system variable
SY-SLSET
Thanks
Seshu -
Getting the variant name when the report program is run in background
Hi All,
How to get the variant name for the report program when run in background? My requirement is to create an email attachement with the name 'variant.XLS', where variant = selection screen variant, when the report program is run in background. The system field SY-SLSET holds the variant name only when run online.
Any pointers to this will be highly appreciated.
Thanks and regards,
Nilesh.Hello Nilesh,
Please find the algo:
1. Call the FM: GET_JOB_RUNTIME_INFO to get the background job details.
2. Select data from TBTCP using these details:
DATA:
FP_EVENTID TYPE BTCEVENTID
FP_EVTPARM TYPE BTCEVTPARM
FP_ACTIVE TYPE BTCXPGFLAG
FP_JOBCNT TYPE BTCJOBCNT
FP_JOBNM TYPE BTCJOB
FP_STEPCNT TYPE BTCSTEPCNT.
CALL FUNCTION 'GET_JOB_RUNTIME_INFO'
IMPORTING
EVENTID = FP_EVENTID
EVENTPARM = FP_EVTPARM
EXTERNAL_PROGRAM_ACTIVE = FP_ACTIVE
JOBCOUNT = FP_JOBCNT
JOBNAME = FP_JOBNM
STEPCOUNT = FP_STEPCNT
EXCEPTIONS
NO_RUNTIME_INFO = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
* Error calling FM: GET_JOB_RUNTIME_INFO
ENDIF.
DATA: FP_VARIANT TYPE BTCVARIANT.
SELECT JOBNAME JOBCOUNT STEPCOUNT VARIANT
FROM TBTCP
INTO TABLE L_IT_TBTCP
WHERE JOBNAME = FP_JOBNM
AND JOBCOUNT = FP_JOBCNT
AND STEPCOUNT = FP_STEPCNT.
IF SY-SUBRC = 0.
SORT L_IT_TBTCP BY JOBNM JOBCNT STEPCNT.
READ TABLE L_IT_TBTCP INTO L_WA_TBTCP INDEX 1.
IF SY-SUBRC = 0.
FP_VARIANT = L_WA_TBTCP-VARIANT.
ENDIF.
ENDIF.
Hope this helps.
BR,
Suhas -
Get the variant name of the job shceduled in the Background
Hello All,
I am shcduling printout of the Payment Document from F110 transaction code in background.
My requirement is to get the variant name.
F110 create background job for printing and when i debug it the value of sy-SLSET it is coming some
junk value like &000000012.
I can not schedule this job from SM36. I have to go for F110 only.
Is there any way to get the variant name of the background job.
Kindly help.
Regards
SachinHi,
I am running F110 by maintaning three variant at the same time.
So my program will run three times for these three variant.
Depending upon the variant i have to perform some validations.
So I want to know the variant name for each one run.
I am maitaing the variant but when i checked the system field sy-SLSET it is coming some junk value '&000000013'.
How to get the variant name from this.
Regards
Sachin Yadav -
How to get the current transaction variant ?
dear guru,
could you please tell me how to get the current transaction variant?
i tried the following method:
DATA l_tcvariant TYPE tcvariant.
CALL 'DY_GET_TX_VARIANT'
ID 'VARIANT' FIELD l_tcvariant.
but it failed.
best regards.
zjTry something like this
DATA: VARIANT LIKE SHDTVCIU-TCVARIANT.
CLEAR VARIANT.
CALL FUNCTION 'RS_HDSYS_GET_TC_VARIANT'
IMPORTING
TCVARIANT = VARIANT
* FLAG_CLIENT_INDEPENDENT =
* RC =
* TABLES
* T_SCREEN_VARIANTS =
* T_INACTIVE_FUNCTIONS = -
How to get the /sapapo/bophead-description using tbtcp-variant.
Hi All,
I need to pick the field /sapapo/bophead-description using the tbtcp-variant. The tbtcp-variant is a dynamic value which will be generated during process run. How to relate these tables and fetch the data ?Hi Raja ,
Use the FM RS_VARIANT_VALUES_TECH_DATA and pass the report name and variant name from TBTCP . From the resulting table read the second entry where SELNAME column is VARIANT . You will get the variant . Pass this into table /sapapo/bophead and you can pick the needed records. -
How to get the Purchase order Qty in the object dependency
Hi,
We are using variant pricing in the purchase order. I have condition type say u201CZVBPu201D for Pallet cost. I defined Pallet cost as 5 USD per each (pallet). I have to calculate Number of pallets = Purchase order Qty/ 5. The number of pallets should be rounded to nearest integer.
My question is how to get the Purchase order Qty in the object dependency?
Is there any reference table and field can be used to get Purchase order Qty just like we use MMCOM-VKOND for variant pricing.
Appreciate your help
Thanks,
SriniHi,
1. I do not have system now so I can not conclusively tell about table field .
2. Since I did it long back so I also do not exactly remember it, there are more than one place where PO qty appears for example Item overview and Item details - one of the PO qty when used in the characteristic do pull the PO qty which can be used for variant pricing (so request to please update the forum with the correct table and field once you find it - in the meantime if I get opportunity to get to system I will also try and find out ). -
Need how to get the data from the external file in eCatt
Hi ,
Could any body suggest how to get the values from the external file(Excel,CSV file,Text file) and pass it as varaiable in ecatt Test script.
Problem: Need to execute FK01-Vendor creation Transaction with multiple set of data .As per my understanding we could achive through Variants in Testdata set in eCatt .
But is there any way to store the data in excell file and get the data and pass it to FK01 Test scripts
Appreciate response on thisHi
See the links they may be useful
check these link,
eCATT- An Introduction
/people/sumeet.kaul/blog/2005/07/26/ecatt-an-introduction
Creating Test Scripts
/people/sumeet.kaul/blog/2005/08/10/ecatt-creating-test-scripts
eCATT Logs
/people/sapna.modi/blog/2006/04/18/ecatt-logs-part-vi
eCATT Scripts Creation TCD Mode
/people/sapna.modi/blog/2006/04/10/ecatt-scripts-creation-150-tcd-mode-part-ii
Creation of Test Data Container
/people/sumeet.kaul/blog/2005/08/24/ecatt-creation-of-test-data-container
eCATT Scripts Creation - SAPGUI Mode
/people/sapna.modi/blog/2006/04/10/ecatt-scripts-creation--sapgui-mode-part-iii
Integrating ECATT & MERCURY QTP Part -1
/people/community.user/blog/2007/01/02/integrating-ecatt-mercury-qtp-part-1
Using eCatt to Test Web Dynpro ABAP
/people/thomas.jung/blog/2006/03/21/using-ecatt-to-test-web-dynpro-abap
and
-command reference
http://help.sap.com/saphelp_nw04/helpdata/en/c6/3c333b40389c46e10000000a114084/content.htm
/people/sapna.modi/blog/2006/04/10/ecatt--an-introduction-part-i
http://prasadbabu.blogspot.com
https://www.sdn.sap.com/sdn/developerareas/was.sdn?page=test_tool_integration_for_sap_e-catt.htm
http://help.sap.com/saphelp_nw04/helpdata/en/1b/e81c3b84e65e7be10000000a11402f/frameset.htm
http://www.erpgenie.com/ecatt/index.htm
hope this helps.
Reward points for useful Answers
Regards
Anji -
How to get the output of Standard HR forms in PE51
Hi Experts,
How to get the output of standard HR forms available in PE51 Transaction for coutry grouping 99.
Please advice.
Regards,
IFFHi
Use the t code for country grouping 99....PC00_M99_CEDT - Remuneration Statement. to get the variant in tcode PC00_M99_CALC_SIMU - Simulation.
Like this test for all the standard forms, what all are the available in PE51 for country grouping 99 -
How To Get The Smart Form Into The PDF File
Hello Friends,
Can Any One Tell How To Get Smart Form in PDF.
I used this RSTXPDFT4 Program.
It is asking The Spool Number.
How to get the Spool Number.the steps are
SmartForms Output to PDF
There is a way to download smartform in PDF format.
Please do the following:
1. Print the smartform to the spool.
2. Note the spool number.
3. Download a PDF file (Acrobat Reader) version of the spool by running Program RSTXPDFT4 and entering the
noted spool number.
how to get spool number
The simplest method is to read the spool table directly, table TSP01
example code
REPORT zsuresh_test.
* Variable declarations
DATA:
w_form_name TYPE tdsfname VALUE 'ZSURESH_TEST',
w_fmodule TYPE rs38l_fnam,
w_cparam TYPE ssfctrlop,
w_outoptions TYPE ssfcompop,
W_bin_filesize TYPE i, " Binary File Size
w_FILE_NAME type string,
w_File_path type string,
w_FULL_PATH type string.
* Internal tables declaration
* Internal table to hold the OTF data
DATA:
t_otf TYPE itcoo OCCURS 0 WITH HEADER LINE,
* Internal table to hold OTF data recd from the SMARTFORM
t_otf_from_fm TYPE ssfcrescl,
* Internal table to hold the data from the FM CONVERT_OTF
T_pdf_tab LIKE tline OCCURS 0 WITH HEADER LINE.
* This function module call is used to retrieve the name of the Function
* module generated when the SMARTFORM is activated
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = w_form_name
* VARIANT = ' '
* DIRECT_CALL = ' '
IMPORTING
fm_name = w_fmodule
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
* Calling the SMARTFORM using the function module retrieved above
* GET_OTF parameter in the CONTROL_PARAMETERS is set to get the OTF
* format of the output
w_cparam-no_dialog = 'X'.
w_cparam-preview = space. " Suppressing the dialog box
" for print preview
w_cparam-getotf = 'X'.
* Printer name to be used is provided in the export parameter
* OUTPUT_OPTIONS
w_outoptions-tddest = 'LP01'.
CALL FUNCTION w_fmodule
EXPORTING
* ARCHIVE_INDEX =
* ARCHIVE_INDEX_TAB =
* ARCHIVE_PARAMETERS =
control_parameters = w_cparam
* MAIL_APPL_OBJ =
* MAIL_RECIPIENT =
* MAIL_SENDER =
output_options = w_outoptions
* USER_SETTINGS = 'X'
IMPORTING
* DOCUMENT_OUTPUT_INFO =
job_output_info = t_otf_from_fm
* JOB_OUTPUT_OPTIONS =
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 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.
t_otf[] = t_otf_from_fm-otfdata[].
* Function Module CONVERT_OTF is used to convert the OTF format to PDF
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
FORMAT = 'PDF'
MAX_LINEWIDTH = 132
* ARCHIVE_INDEX = ' '
* COPYNUMBER = 0
* ASCII_BIDI_VIS2LOG = ' '
* PDF_DELETE_OTFTAB = ' '
IMPORTING
BIN_FILESIZE = W_bin_filesize
* BIN_FILE =
TABLES
otf = T_OTF
lines = T_pdf_tab
EXCEPTIONS
ERR_MAX_LINEWIDTH = 1
ERR_FORMAT = 2
ERR_CONV_NOT_POSSIBLE = 3
ERR_BAD_OTF = 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.
* To display File SAVE dialog window
CALL METHOD cl_gui_frontend_services=>file_save_dialog
* EXPORTING
* WINDOW_TITLE =
* DEFAULT_EXTENSION =
* DEFAULT_FILE_NAME =
* FILE_FILTER =
* INITIAL_DIRECTORY =
* WITH_ENCODING =
* PROMPT_ON_OVERWRITE = 'X'
CHANGING
filename = w_FILE_NAME
path = w_FILE_PATH
fullpath = w_FULL_PATH
* USER_ACTION =
* FILE_ENCODING =
EXCEPTIONS
CNTL_ERROR = 1
ERROR_NO_GUI = 2
NOT_SUPPORTED_BY_GUI = 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.
* Use the FM GUI_DOWNLOAD to download the generated PDF file onto the
* presentation server
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
BIN_FILESIZE = W_bin_filesize
filename = w_FULL_PATH
FILETYPE = 'BIN'
* APPEND = ' '
* WRITE_FIELD_SEPARATOR = ' '
* HEADER = '00'
* TRUNC_TRAILING_BLANKS = ' '
* WRITE_LF = 'X'
* COL_SELECT = ' '
* COL_SELECT_MASK = ' '
* DAT_MODE = ' '
* CONFIRM_OVERWRITE = ' '
* NO_AUTH_CHECK = ' '
* CODEPAGE = ' '
* IGNORE_CERR = ABAP_TRUE
* REPLACEMENT = '#'
* WRITE_BOM = ' '
* TRUNC_TRAILING_BLANKS_EOL = 'X'
* WK1_N_FORMAT = ' '
* WK1_N_SIZE = ' '
* WK1_T_FORMAT = ' '
* WK1_T_SIZE = ' '
* IMPORTING
* FILELENGTH =
tables
data_tab = T_pdf_tab
* FIELDNAMES =
* EXCEPTIONS
* FILE_WRITE_ERROR = 1
* NO_BATCH = 2
* GUI_REFUSE_FILETRANSFER = 3
* INVALID_TYPE = 4
* NO_AUTHORITY = 5
* UNKNOWN_ERROR = 6
* HEADER_NOT_ALLOWED = 7
* SEPARATOR_NOT_ALLOWED = 8
* FILESIZE_NOT_ALLOWED = 9
* HEADER_TOO_LONG = 10
* DP_ERROR_CREATE = 11
* DP_ERROR_SEND = 12
* DP_ERROR_WRITE = 13
* UNKNOWN_DP_ERROR = 14
* ACCESS_DENIED = 15
* DP_OUT_OF_MEMORY = 16
* DISK_FULL = 17
* DP_TIMEOUT = 18
* FILE_NOT_FOUND = 19
* DATAPROVIDER_EXCEPTION = 20
* CONTROL_FLUSH_ERROR = 21
* OTHERS = 22
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Do reward if helpful
Edited by: sharad narayan on Apr 4, 2008 2:14 PM
Edited by: sharad narayan on Apr 4, 2008 2:18 PM -
How to get the values from popup window to mainwindow
HI all,
I want to get the details from popup window.
i have three input fields and one search button in my main window. when i click search button it should display popup window.whenever i click on selected row of the popup window table ,values should be visible in my main window input fields.(normal tables)
now i am able to display popup window with values.How to get the values from popup window now.
I can anybody explain me clearly.
Thanks&Regards
kranthiHi Kranthi,
Every webdynpro component has a global controller called the component controller which is visible to all other controllers within the component.So whenever you want to share some data in between 2 different views you can just make it a point to use the component controller's context for the same. For your requirement (within your popups view context) you will have have to copy the component controllers context to your view. You then will have to (programmatically) fill this context with your desired data in this popup view. You can then be able to read this context from whichever view you want. I hope that this would have made it clear for you. Am also giving you an [example|http://****************/Tutorials/WebDynproABAP/Modalbox/page1.htm] which you can go through which would give you a perfect understanding of all this. In this example the user has an input field in the main view. The user enters a customer number & presses on a pushbutton. The corresponding sales orders are then displayed in a popup window for the user. The user can then select any sales order & press on a button in the popup. These values would then get copied to the table in the main view.
Regards,
Uday -
How to get the table of value field? and can we expand the technical limits
Dear
I have created value field in COPA with KEA6. And now, I need the table which the value fields are saved. Yet, I have tried a lot to find it and get failure? Can any guy help me? Please tell me how to get the table of a value field.
And another question is that, can we extend the technical limits for the number of value field for ECC6.0?
We have a note for R.4.x Please see below:
OSS note 160892
You can display the length of a data record using Transaction KEA0 ('Maintain Operating Concern'). After you have navigated to the 'Characteristics Screen' or to the 'Value field Screen' choose menu path 'Extras -> Technical Limits'.
The maximum displayed here under 'Length in bytes on the DB' is the maximum length permitted by the Dictionary. The reserve required for the release upgrade must be subtracted from this value.
To increase the allowed number of the value fields, increase the value that is assigned to field ikcge-bas_max_cnt (FORM init_ikcge_ke USING fm_subrc, approx. line 165) in Include FKCGNF20. It specifies the number of the possible value fields. The corresponding part of the source code is attached to the note as a correction.
David Sun
Regards!how to extend the limit of value numbers? please see the original question.
-
I downloaded and bought a movie from iTunes on my iPad and now want the same movie on my MacBook Pro but its not offering me to download it, it giving me the options of buying it which I already did. How I get the movie onto my MacBook?
You can connect the iPad to your Mac's iTunes and do File > Devices > Transfer Purchases, that should copy it over to the Movies part of your library.
Depending upon what country that you are in, and whether the film studio allows it, you might also be able to re-download it on your Mac via the Purchased link under Quicklinks on the right-hand side of the iTunes store home page.
Maybe you are looking for
-
Bridge will not launch from Illustrator CC
I am having issues with launching Bridge in Illustrator and After Effects. I have to manually launch it with the icon.
-
Replacement TC Power Cable part number
We are moving to the USA and need to get replacement power cables for our Mac equipment. Is there a part number available for the Time Capsule US power cord please? Thanks
-
Mirrored database in Disconnected/In Recovery state
I am running Microsoft SQL 2008 R2 database server I have a mirrored database that shows in the following state 'databasename (Principal, Disconnected/In Recovery)'. When I look at the mirror server is shows in the same state 'databasename (mirror, D
-
Audio from Sony EX1r Camera will not round trip from Audition
With Premier CC15 the audio from my Sony EX1R Video Camera comes back from Audition after the edit just as a loud buzz. It works fine in Premier 6 and also CC. My Panasonic camera Audio, as well as all others work fine. Can someone help?
-
I am new in DART extract and wanted add the new field in Existing Segement
Hi ALL I am new in DART extract and client is request us to add the new field in Existing Segment. What is proceedure i need to follow to add the new field in existing segment. Moderator: Please, post in proper forum