Select-options in smartforms
Hi everybody,
can anybody give me clarification that. . . . can we use select-options in smartforms ?
thanks in advance.
Hai.
check the links.
http://www.****************/Tutorials/Smartforms/SelectOptions/Demo.htm
http://www.****************/Tutorials/Smartforms/SFMain.htm
Re: smart forms
regards.
sowjanya.b
Similar Messages
-
Can we use select options in smartform
can we use select options in smartform if so can any one send me a sample code...
Thanks
bhaskharHi ,
Can u explain why u want to use select options in smartforms . U can try it in program lines .
Its better to use select options in the driver program and fetch data accordingly in the driver program or passing the selected values from select options to the smatfrom and fdetching the data there in smartform .
Regards -
Hi all,
Is't possible to use Select-options in smartforms, If so how to use.
Regards
SuprithHi,
yes it is possible
1 Create a Structure ZSELECTION in SE11 with following fields
SIGN
OPTION
LOW
HIGH
This structure is similar to the selection-option internal table.
2 In smart form u2018ZSELECT_FORMu2019, create an entry in to TABLES in the Form Interface.
3 Define Structures in TYPES tabs in GLOBAL DEFINITIONS
4. Do the global declartation
5 go to mainwindow
create-->Flow logic -
> program lines
The PERNRS given in the select-option in the driver program is captured in T_SELECT. In program lines, T_SELECT is input to SELECT query and the results are captured in internal table T_0002. We have to mention resulted internal table T_0002 in output parameters for further use.
loop the internal table
wite the printporam
Thanks & Regards
Ramakrishna Pathi
then provide the input and output parameters -
Passing Select option to smartform
Hi All,
Can any one please suggest how to pass values selected in select-options to smartform.
I am aware of the iuse of var-low and Var-high,
bt what if user inputs multiple values?
Also,is there any standard table type of table that is created when we use select-options.so that we can pass this table to smartform while using select options.
Regards,
SangvirBuild in smartform in form interface select option table
and pass the select option table from the program to the
smartform.
to build select option table in smartform you can built
type in global definition tab types.
Then, use it in form interface. -
Showing error in passing select option to smartforms
Dear Friends,
I have done program of passing select option to smartforms. But it was showing errorin Types of Global defination that the flat structure is not allowed. So pls guide me.
Thanks in advance,
PradipkumarHi Pradip,
<li>When you want pass select-option from program to Smartform. You need create one structure in SE11 (data dictionary) and Use that under Form interface ->Tables tab
<li>The structure should have the following fields.
low
high
sign
option
<li>The structures should be same in the program and smartform when that is used as interface.
Thanks
Venkat.O -
Hiiiii,
I am new to smartforms and i need to show range of dates in smartforms.
I am trying in driver prog. n i got correct data in final internal table but cant
fetch correct data using fm in driver prog.
Thank You...Hi,
1 Create a Structure ZSELECTION in SE11 with following fields
SIGN
OPTION
LOW
HIGH
This structure is similar to the selection-option internal table.
2 In smart form u2018ZSELECT_FORMu2019, create an entry in to TABLES in the Form Interface.
3 Define Structures in TYPES tabs in GLOBAL DEFINITIONS
4. Do the global declartation
5 go to mainwindow
create-->Flow logic -
> program lines
The PERNRS given in the select-option in the driver program is captured in T_SELECT. In program lines, T_SELECT is input to SELECT query and the results are captured in internal table T_0002. We have to mention resulted internal table T_0002 in output parameters for further use.
loop the internal table
wite the printporam
Regards,
DHina.. -
How to SELECT-OPTIONS in smartforms
Hi Experts,
I am create the smartform using parameter but req. is need to SELECT-OPTIONS instead of parameter how to use in smartform.
Thanks un Advance.
purnaneelu
<MOVED BY MODERATOR TO THE CORRECT FORUM>
Edited by: Alvaro Tejada Galindo on Jun 11, 2009 4:18 PMHi Purnaneelu,
plese try in this way
proior to doing the above thing..in the SMART FORM you have to do the following things first
1)Create a Structure ZSTRUC in SE11 with the required fields.
2)In smart form u2018ZXXXXXu2019, create an entry in to TABLES tab "parametername in the Form Interface.
3)Define Structures in TYPES tabs in GLOBAL DEFINITIONS.
4)Write the logic in the main window "program Lines".
5)Loop the internal table you have used in the smartform. then follow as the below driver program procedure this will solve your problem
tables:<your table from which you are fetching the data>
select-options.
s_<fieldname> for <tablename-fieldname>.
data: fname type rs38L_fname. "this is for the function module name
Start-of-Selection.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = <your form name>
IMPORTING
FM_NAME = fname
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2
OTHERS = 3
*now call the function module which will be generated when you create the smart form, and replace the form name with "fname"
CALL FUNCTION <fname>
EXPORTING
ARCHIVE_INDEX =
ARCHIVE_INDEX_TAB =
ARCHIVE_PARAMETERS =
CONTROL_PARAMETERS =
MAIL_APPL_OBJ =
MAIL_RECIPIENT =
MAIL_SENDER =
OUTPUT_OPTIONS =
USER_SETTINGS = 'X'
IMPORTING
DOCUMENT_OUTPUT_INFO =
JOB_OUTPUT_INFO =
JOB_OUTPUT_OPTIONS =
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
(or)
call function fname
tables
<the table name which you have used in the FORM INTERFACE parameter name> = <the checking value>
Regards,
Abdul Samad. -
Geting select option value on the basis of filtering criteria
Hi
I have a selection parameter field is PRPS-WERKS. when user will go for f4 help, the value should come as filtered on the basis of the condition : select the respective WBS ELEMENT (PRPS- PSPNR) and select the respective PR LINE item. (The relation is PRPS-PSPNR=EBKN-PS_PSP_PNR and EBKN-BANFN = EBAN-BANFN and EBKN-BNFPO = EBAN-BNFPO).now the value iof WERKS is not comming from the database table PRPS itself. how to manage this thing?Hi,
Refer the link select option in smartforms and read what i suggested..
Regards,
Dhina.. -
Passing select-options to the smartforms
Hi,
I working for smartform, I have to print select-options (S_INNUM) value in the one of the window of the smartform
what is the approach for this1. Go to se11
cteate a structure zselect_option.
with the fields: low types kunnr
high types kunnr
sign types char1
options types char2.
than save,check and activate the structure.
2.go to smartforms
Doubl click on form interface.
in table tab declare the parameters as
s_kunnr like zselect_option
it_kna1 like kna1.
3.Double click on global definition
declare a work area in global data like as
wa_kna1 type kna1.
4.Click on Main window
create -> flow logic -> prgmlines.
Give the input paramer as s_kunnr
output parameter as it_kna1.
again..Click on Main window
create -> flow logic -> loop.
in that loop click on data tab
provide it_kna1 into wa_kna1.
than click on loop -> create -> text.
drag and drop our fields from Globel Data.
save and activate our smartform.
5. create a driver prmg as..shown below
tables:kna1.
select-options:s_kunnr for kna1-kunnr.
data:it_kna1 type table of kna1.
DATA:F_NAME TYPE RS38L_FNAM.
start-of-selection.
select *
from kna1
into table it_kna1
where kunnr in s_kunnr.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = 'ZSMARTFORM' "(Give Smartform name)
* VARIANT = ' '
* DIRECT_CALL = ' '
IMPORTING
FM_NAME = F_NAME.
CALL FUNCTION f_name
TABLES
S_KUNNR = s_kunnr
IT_KNA1 = it_kna1.
save ,check and activate and exicute the prgm... -
SMARTFORMS WITH SELECT-OPTIONS
Hi..
Can anyone send me a good document to study or suggest me in printing a smartform having select-options ( i.e for a range of suppose purchase orders )..
Thanx in advanceHi,
Refer the following link.
http://sapbrain.com/ARTICLES/TECHNICAL/SMARTFORMS/smartforms.html
Regards,
Subashini.J -
Problem in Passing the select-options data in smartforms
Dear ABAPers,
I have developed new layout for Delivery Chellan using smartforms.
using parameters i am getting document no, corresponding all details getting print.
but the client wants to use multiple document no.
in function module also i am passing only one import parameter (i.e. doc.no).
my requirement is how to pass multiple data in smartfroms.
Thanks & Regards,
AshokDear ABAPers,
Here i give my code Please check it out and tell me where i am going wrong.
*& Report ZMM_DC_FORM *
REPORT ZMM_DC_FORM .
Data Declaration
tables : mseg,
mkpf,
ekpo,
ekko,
objk,
mbew,
ser03,
twlad,
makt,
adrc.
data : begin of struct_mblnr,
mblnr type mblnr,
end of struct_mblnr.
data : it_mblnr like table of struct_mblnr with header line.
data : begin of i_struct,
mblnr like mseg-mblnr,
mjahr like mseg-mjahr,
matnr like mseg-matnr,
erfmg like mseg-erfmg,
werks like mseg-werks,
lgort like mseg-lgort,
ebeln like mseg-ebeln,
ebelp like mseg-ebelp,
umwrk like mseg-umwrk,
end of i_struct.
data : begin of bednr_struct,
matnr type ekpo-matnr,
bednr type ekpo-bednr,
end of bednr_struct.
data : begin of price_struct,
matnr type mseg-matnr,
verpr type mbew-verpr,
stprs type mbew-stprs,
end of price_struct.
data : begin of serial_struct,
matnr like objk-matnr,
sernr like objk-sernr,
end of serial_struct.
data : begin of fi_struct,
matnr type mseg-matnr,
maktx type makt-maktx,
bednr type ekpo-bednr,
erfmg type mseg-erfmg,
verpr type mbew-verpr,
val_p type mbew-verpr,
end of fi_struct.
data : it_tab like table of i_struct with header line.
data : it_add1 type table of adrc with header line,
it_add2 type table of adrc with header line.
data : it_bednr like table of bednr_struct with header line.
data : it_price like table of price_struct with header line.
data : it_ser type table of ZMM_DC_SERIAL with header line.
data : it_final like table of fi_struct with header line.
data : s_date like mkpf-budat.
data : s_ebeln like ekpo-ebeln.
DATA : FM_NAME TYPE RS38L_FNAM.
Selection Screen Variables
selection-screen : begin of block b1 with frame title text-001.
select-options : s_mblnr for mseg-mblnr.
parameters : s_mjahr type mseg-mjahr.
selection-screen : end of block b1.
Start of Selection
start-of-selection.
select mblnr from mseg into table it_mblnr where mblnr ge s_mblnr-low
and mblnr le s_mblnr-high.
delete adjacent Duplicates from it_mblnr.
*loop at it_mblnr.
*write : it_mblnr-mblnr.
*endloop.
loop at it_mblnr.
select mblnr
mjahr
matnr
erfmg
werks
lgort
ebeln
ebelp
umwrk from mseg into table it_tab where mblnr = it_mblnr-mblnr
and mjahr = s_mjahr
and xauto <> 'X'.
read table it_tab index 1.
*code for PO Number
s_ebeln = it_tab-ebeln.
*code for Supplying plant address
select single adrnr from twlad into twlad-adrnr where werks = it_tab-werks
and lgort = it_tab-lgort.
select single * from adrc into it_add1 where addrnumber = twlad-adrnr.
clear twlad-adrnr.
*code for receiving plant address
select single lgort from ekpo into ekpo-lgort where ebeln = it_tab-ebeln
and ebelp = it_tab-ebelp.
select single adrnr from twlad into twlad-adrnr where werks = it_tab-umwrk
and lgort = ekpo-lgort.
select single * from adrc into it_add2 where addrnumber = twlad-adrnr.
clear : twlad-adrnr,
ekpo-lgort.
*code for the Material Document Date
select single budat from mkpf into s_date where mblnr = it_mblnr-mblnr
and mjahr = s_mjahr.
loop at it_tab.
it_final-matnr = it_tab-matnr.
it_final-erfmg = it_tab-erfmg.
*Code for Material Description
select single maktx from makt into makt-maktx where matnr = it_tab-matnr.
it_final-maktx = makt-maktx.
clear makt-maktx.
*Code for Service order Number
select single matnr
bednr from ekpo into it_bednr where ebeln = it_tab-ebeln
and ebelp = it_tab-ebelp
and matnr = it_tab-matnr.
it_final-bednr = it_bednr-bednr.
*Code for Price for the Material
select single matnr
verpr
stprs from mbew into it_price where matnr = it_tab-matnr
and bwkey = it_tab-werks.
if it_price-verpr <> 0.
it_final-verpr = it_price-verpr.
else.
it_final-verpr = it_price-stprs.
endif.
it_final-val_p = it_final-erfmg * it_price-stprs.
append it_final.
clear it_final.
endloop.
*Code for Serial Number
select single obknr from ser03 into ser03-obknr where mblnr = it_mblnr-mblnr
and vorgang = 'MMSL'.
select matnr
sernr from objk into table it_ser where obknr = ser03-obknr.
clear ser03-obknr.
*Calling Function Module for Smartform
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = 'ZMM_DC_FORM'
VARIANT = ' '
DIRECT_CALL = ' '
IMPORTING
FM_NAME = FM_NAME
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.
CALL FUNCTION FM_NAME
EXPORTING
L_MBLNR = it_mblnr-mblnr
L_DATE = S_DATE
L_EBELN = S_EBELN
IT_ADD1 = IT_ADD1
IT_ADD2 = IT_ADD2
TABLES
IT_FINAL = IT_FINAL
IT_SER = IT_SER.
endloop.
Please help me to solve this problem.It is very urgent.
Thanks & Regards,
Ashok. -
hi everyone,
i m developing a po in smartforms. now i want to give the select-option on selection screen and accordingly i want to print po.s continuesly as given by user in in select-options,.so can u tell em how its is deal in program as well as in smartforms wt i will hav to do.Hi,
Let me know whether my understanding is correct.
You are passing po no. as select-option in selection screen of driver program.
You want to print the po no. entered in selection screen thro' smartform.
If the above is the requirement,develop a ztable in SE11 with fields low,high,sign,option.
Pass the select-option value from driver program as table.
In the smartform,form-Interface->tables
itab like ztable -
Symaltaneous use of select-option and parameters in smartforms .
hello Abaper,
I am design a smartforms . we have given some input. when we use only parameters it works properly. as same when we use select-option only its works .
But when i use both parameter and select option at that time error generate .
Actually call function is not works .
So please give me proper idea how to solve this problem .
Regards
kamal kishoreHi ,
Still problem is not solved.
i want to call following fields but function modules show run time error. IF separately i call only parameter its run properly.
in the same way if i call only select option is runs properly.
please suggest me how can i call both the things.
PARAMETERS: P_BUKRS TYPE BSEG-BUKRS OBLIGATORY,
P_GJAHR TYPE BSEG-GJAHR OBLIGATORY.
parameters: P_SECCO type SECCODE-SECCODE OBLIGATORY.
*SELECT-OPTIONS : P_SECCO FOR SECCODE-SECCODE OBLIGATORY.
PARAMETERS: P_QSCOD TYPE J_1IEWTNUMGR-QSCOD OBLIGATORY.
SELECT-OPTIONS: P_BUDAT FOR BKPF-BUDAT OBLIGATORY,
P_BLART FOR BKPF-BLART,
P_J_HLN FOR J_1IEWTCHLN-J_1IEXTCHLN,
P_J_HDT FOR J_1IEWTCHLN-J_1IEXTCHDT OBLIGATORY,
P_LIFNR FOR LFB1-LIFNR.
regards
kamal
Edited by: kamal_kishore_sah on Apr 12, 2011 7:44 AM -
Smartforms with selection-option
HI Experts,
Well i have done a customer statement with a smartforms.
Currently the print program have a parameter for the customer (kunnr) field.
But my new requirment is i need to change it to select-options.
But i how to configure the smartforms.
Just say i have 2 customers and i need to have a separeted page for both customers and
their address should also in different page.
Please give me the logic.
Thanks a lot.
s.saravannan.....Hi saravannan sithambaram,
Loop at itab, - in which we have 2 customers....
CALL SF
ENDLOOP.
Paste the CALL SF fucntion, to know how they are passing address of them ... for more clarification..
Paste the internal tables and code how didi they do it...
Regards,
Suneel G -
How to use parameter option in smartform program line.
HI all,
how can i give parameter for matnr directly in smartform program line, it wont take gives a dump
i don wanna create a separate driver program for that.
Error in the ABAP Application Program
The current ABAP program "/1BCDWB/SF00000001============FT" had to be
terminated because it has
come across a statement that unfortunately cannot be executed.
The following syntax error occurred in program "/1BCDWB/SAPLSF00000001 " in
include "/1BCDWB/LSF00000001F01 " in
line 539:
"You can only use "PARAMETERS" for programs other than type 1 between B"
"EGIN/END OF SCREEN."
The include has been created and last changed by:
Created by: "SAPUSER "
Last changed by: "SAPUSER "
how can i solved this.
Kavinath B.Hi,
You can not code
SELECTION-SCREEN BEGIN OF BLOCK.
SELECT-OPTIONS selcrit FOR (name).
SELECTION-SCREEN END OF BLOCK.
like this in smartform program line it wont allow
all you have to do is create a driver program
for smartform create a selection screen and call smartform by
n pass variables or internal tables.
call function 'SSF_FUNCTION_MODULE_NAME'
exporting
formname =
* VARIANT = ' '
* DIRECT_CALL = ' '
* IMPORTING
* FM_NAME =
* 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.
I hope it will help u
Ketan.P
Maybe you are looking for
-
Error while using container element _WF_PARFOREACH_INDEX in workflow
Hi All, I am using internal container element WFPARFOREACH_INDEX in internal table so that i can use it as index to read table row one by one..but in binding i am getting error "Container element '_WF_PARFOREACH_INDEX' does not exist" in form of an e
-
Unable to use WPG_DOCLOAD.download_file in Apex 4.2.1
Hi guys, I stumbled on the next problem. We recently migrated from apex 4.0 to 4.2.1 and use a procedure to open an RTF document filled with parameters from a chosen record. It always worked with the a procedure calling the next line: WPG_DOCLOAD.dow
-
Outlook is working on VLAN but not working on other VALNS
First of all thanks in advance. here is the scenario :- (1) 03 VLANS in the network. all VLANS are connected through core L3 switch. No ACLs in L3 switch. VLAN 101-192.168.1.0/24 VLAN 102 - 192.168.2.0/24 VLAN 103- 192.168.3.0/24 (2)
-
Hello, I have a multi-threaded application but the main thread doesnt blocks the application so the application quits just after started. Im using this code to block the main thread: /*BufferedReader r = new BufferedReader(new InputStreamReader(Syste
-
How to change table value set using FND_LOAD
Hi , I need to change my existing " table valueset " tablename . As i know we cont change it from front end if it is created once. but i am trying to create same value set in other instance and uploading it using FND_LOAD . Is it Possible ? IF yes pl