Download/Upload Function group???
Hi,
How to download function group from one system and upload it to another system.
Here transporting the request is not possible. Hence it requires to be downloded first on to one system and uploaded to another system.
How it can be done??
Thanks and Regards
Rahul.
Hi,
GOTO transaction SE80, Choose Function Group in the List Box and Provide your FG and Press Enter. Now goto utilities->more utilities->Upload and DOwnload.
Hope this should have helped you.
Thanks,
Prashanth
Similar Messages
-
Upload / download gui-status/dynpro when function group
Hi All,
I'm coding a program where I can download and upload reports and module pools but I tried to do the same with function groups and I found It is different to upload dynpro and gui staus when the objet to generate is a function group.
Could anyone help me a little in order to complete and finish this issue?
Below is shown the routines I coding in order to achive that:
For gui-status uploading I use:
CALL FUNCTION 'RS_CUA_INTERNAL_WRITE'
EXPORTING
program = prog
language = sy-langu
tr_key = tr_key
adm = adm4
TABLES
sta = sta4
fun = fun4
men = men4
mtx = mtx4
act = act4
but = but4
pfk = pfk4
set = set4
doc = doc4
tit = tit4
biv = biv46c
EXCEPTIONS
not_found = 1
OTHERS = 2.
For screen uploading I use:
GENERATE DYNPRO gs_d020s gt_d021s gt_d022s gt_d023s ID dynp_id
MESSAGE mess LINE line WORD word.
IF sy-subrc = 0.
EXPORT DYNPRO gs_d020s gt_d021s gt_d022s gt_d023s ID dynp_id.
ENDIF.
But both options don't work when uploading function groups
Regards...
Edited by: Rob Burbank on Jun 1, 2011 11:58 AM
Edited by: Kenneth Castañeda on Jun 2, 2011 7:31 PM
Edited by: Kenneth Castañeda on Jun 2, 2011 7:34 PMHi Kenneth,
sorry, it is really not obvious that [there is a link behind zsaplink|http://code.google.com/p/saplink/].
From the link:
"SAPlink is an open source project that aims to make it easier to share ABAP developments between programmers. It provides the ability to easily distribute and package custom objects."
This software allows you to up- and download all kinds of SAP objects. It is distributed under the GNU General Public License.
I think this is exactly what you are looking for - or I did not understand your question.
Regards,
Clemens -
Is there any program to download function group?
Hi
I just want to download whole function group and dictionary object (table type and structure) in specific package.
not need to table contents though.
is there anyway to download these object quick?Hi
You can try this code
[code]tables: trdir, seoclass, tfdir, enlfdir, dd02l.
Types
text element structure
types: tTextTable like textpool.
GUI titles
types: tGUITitle like d347t.
Message classes
types: begin of tMessage,
arbgb like t100-arbgb,
stext like t100a-stext,
msgnr like t100-msgnr,
text like t100-text,
end of tMessage.
Screen flow.
types: begin of tScreenFlow,
screen like d020s-dnum,
code like d022s-line,
end of tScreenFlow.
Holds a table\structure definition
types: begin of tDictTableStructure,
fieldname like dd03l-fieldname,
position like dd03l-position,
keyflag like dd03l-keyflag,
rollname like dd03l-rollname,
domname like dd03l-domname,
datatype like dd03l-datatype,
leng like dd03l-leng,
ddtext like dd04t-ddtext,
end of tdictTableStructure.
Holds a tables attributes + its definition
types: begin of tDictTable,
tablename like dd03l-tabname,
tableTitle like dd02t-ddtext,
iStructure type tDictTableStructure occurs 0,
end of tDictTable.
Include program names
types: begin of tInclude,
includeName like trdir-name,
includeTitle like tftit-stext,
end of tInclude.
Exception class texts
types: begin of tConcept,
constName type string,
concept type sotr_conc,
end of tConcept.
Method
types: begin of tMethod,
cmpName like vseomethod-cmpname,
descript like vseomethod-descript,
exposure like vseomethod-exposure,
methodKey type string,
end of tMethod.
Class
types: begin of tClass,
scanned(1),
clsname like vseoclass-clsname,
descript like vseoclass-descript,
msg_id like vseoclass-msg_id,
exposure like vseoclass-exposure,
state like vseoclass-state,
clsfinal like vseoclass-clsfinal,
r3release like vseoclass-r3release,
iMethods type tMethod occurs 0,
iDictStruct type tDictTable occurs 0,
iTextElements type tTextTable occurs 0,
iMessages type tMessage occurs 0,
iConcepts type tConcept occurs 0,
textElementKey type string,
publicClassKey type string,
privateClassKey type string,
protectedClassKey type string,
typesClassKey type string,
exceptionClass type i,
end of tClass.
function modules
types: begin of tFunction,
functionName like tfdir-funcName,
functionGroup like enlfdir-area,
includeNumber like tfdir-include,
functionMainInclude like tfdir-funcName,
functionTitle like tftit-stext,
topIncludeName like tfdir-funcName,
progname like tfdir-pname,
programLinkName like tfdir-pname,
messageClass like t100-arbgb,
iTextElements type tTextTable occurs 0,
iSelectiontexts type tTextTable occurs 0,
iMessages type tMessage occurs 0,
iIncludes type tInclude occurs 0,
iDictStruct type tDictTable occurs 0,
iGUITitle type tGUITitle occurs 0,
iScreenFlow type tScreenFlow occurs 0,
end of tFunction.
types: begin of tProgram,
progname like trdir-name,
programTitle like tftit-stext,
subc like trdir-subc,
messageClass like t100-arbgb,
iMessages type tMessage occurs 0,
iTextElements type tTextTable occurs 0,
iSelectiontexts type tTextTable occurs 0,
iGUITitle type tGUITitle occurs 0,
iScreenFlow type tScreenFlow occurs 0,
iIncludes type tInclude occurs 0,
iDictStruct type tDictTable occurs 0,
end of tProgram.
Internal tables
Dictionary object
data: iDictionary type standard table of tDictTable with header line.
Function modules.
data: iFunctions type standard table of tFunction with header line.
Tree display structure.
data: iTreeDisplay type standard table of snodetext with header line.
Message class data
data: iMessages type standard table of tMessage with header line.
Holds a single message class an all of its messages
data: iSingleMessageClass type standard table of tMessage with header line.
Holds program related data
data: iPrograms type standard table of tProgram with header line.
Classes
data: iClasses type standard table of tClass with header line.
Table of paths created on the SAP server
data: iServerPaths type standard table of string with header line.
Table prototypes
data: dumiDictStructure type standard table of tDictTableStructure.
data: dumiTextTab type standard table of tTextTable.
data: dumiIncludes type standard table of tInclude.
data: dumiHtml type standard table of string.
data: dumiHeader type standard table of string .
data: dumiScreen type standard table of tScreenFlow .
data: dumIGUITitle type standard table of tGUITitle.
data: dumiMethods type standard table of tMethod.
data: dumiConcepts type standard table of tConcept.
Global objects
data: objFile type ref to cl_gui_frontend_services.
data: objRuntimeError type ref to cx_root.
Constants
constants: VERSIONNO type string value '1.3.1'.
constants: TABLES type string value 'TABLES'.
constants: TABLE type string value 'TABLE'.
constants: LIKE type string value 'LIKE'.
constants: TYPE type string value 'TYPE'.
constants: TYPEREFTO type string value 'TYPE REF TO'.
constants: STRUCTURE type string value 'STRUCTURE'.
constants: LOWSTRUCTURE type string value 'structure'.
constants: OCCURS type string value 'OCCURS'.
constants: FUNCTION type string value 'FUNCTION'.
constants: CALLFUNCTION type string value ' CALL FUNCTION'.
constants: MESSAGE type string value 'MESSAGE'.
constants: INCLUDE type string value 'INCLUDE'.
constants: LOWINCLUDE type string value 'include'.
constants: DESTINATION type string value 'DESTINATION'.
constants: IS_TABLE type string value 'T'.
constants: IS_PROGRAM type string value 'P'.
constants: IS_SCREEN type string value 'S'.
constants: IS_GUITITLE type string value 'G'.
constants: IS_DOCUMENTATION type string value 'D'.
constants: IS_MESSAGECLASS type string value 'MC'.
constants: IS_FUNCTION type string value 'F'.
constants: IS_CLASS type string value 'C'.
constants: IS_METHOD type string value 'M'.
constants: ASTERIX type string value '*'.
constants: COMMA type string value ','.
constants: PERIOD type string value '.'.
constants: DASH type string value '-'.
constants: TRUE type i value 1.
constants: FALSE type i value 0.
constants: LT type string value '<'.
constants: GT type string value '>'.
constants: UNIX type string value 'UNIX'.
constants: NON_UNIX type string value 'not UNIX'.
constants: BACKGROUND_COLOUR type string value '#FFFFE0'.
constants: COLOUR_WHITE type string value '#FFFFFF'.
constants: COLOUR_BLACK type string value '#000000'.
constants: COLOUR_YELLOW type string value '#FFFF00'.
constants: COMMENT_COLOUR type string value '#0000FF'.
constants: HTMLEXTENSION type string value 'html'.
constants: TEXTEXTENSION type string value 'txt'.
Global variables
data: statusBarMessage(100).
data: forcedExit type i value 0.
data: startTime like sy-uzeit.
data: runTime like sy-uzeit.
data: downloadFileExtension type string.
data: downloadFolder type string.
data: serverSlashSeparator type string.
data: frontendSlashSeparator type string.
data: slashSeparatorToUse type string.
data: serverFilesystem type filesys_d.
data: serverFolder type string.
data: frontendOpSystem type string.
data: serverOpSystem type string.
data: customerNameSpace type string.
ranges: soProgramName for trdir-name.
ranges: soAuthor for usr02-bname.
ranges: soTableNames for dd02l-tabname.
ranges: soFunctionName for tfdir-funcName.
ranges: soClassName for vseoclass-clsname.
ranges: soFunctionGroup for enlfdir-area.
field-symbols: <waDictStruct> type tDictTable.
Selection screen declaration
Author
selection-screen: begin of block b1 with frame title tBlock1.
selection-screen begin of line.
selection-screen comment 5(23) tAuth.
parameters: pAuth like usr02-bname memory id MAUTH.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 5(36) tPmod.
parameters: pMod as checkbox.
selection-screen end of line.
Local objects
selection-screen begin of line.
selection-screen comment 5(36) t$tmp.
parameters: p$tmp as checkbox default ''.
selection-screen end of line.
selection-screen: end of block b1.
selection-screen begin of block b2 with frame title tBlock2.
Tables
selection-screen begin of line.
parameters: rTable radiobutton group r1.
selection-screen comment 5(15) tRtable.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(15) tPtable.
select-options: soTable for dd02l-tabname.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(79) tTnote.
selection-screen end of line.
Message classes
selection-screen begin of line.
parameters: rMess radiobutton group r1.
selection-screen comment 5(18) tPMes.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(18) tMname.
parameters: pMname like t100-arbgb memory id MMNAME.
selection-screen end of line.
Function modules
selection-screen begin of line.
parameters: rFunc radiobutton group r1.
selection-screen comment 5(30) tRfunc.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(15) tPfname.
select-options: soFname for tfdir-funcName.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(15) tFgroup.
select-options: soFgroup for enlfdir-area.
selection-screen end of line.
Classes
selection-screen begin of line.
parameters: rClass radiobutton group r1.
selection-screen comment 5(30) tRClass.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(15) tPcName.
select-options: soClass for seoclass-clsname.
selection-screen end of line.
Programs / includes
selection-screen begin of line.
parameters: rProg radiobutton group r1 default 'X'.
selection-screen comment 5(18) tProg.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 10(15) tRpname.
select-options: soProg for trdir-name.
selection-screen end of line.
selection-screen skip.
Language
selection-screen begin of line.
selection-screen comment 1(18) tMLang.
parameters: pMLang like t100-sprsl default 'EN'.
selection-screen end of line.
Package
selection-screen begin of line.
selection-screen comment 1(18) tPack.
parameters: pPack like tadiv-devclass memory id MPACK.
selection-screen end of line.
Customer objects
selection-screen begin of line.
selection-screen comment 1(27) tCust.
parameters: pCust as checkbox default 'X'.
selection-screen comment 32(25) tNRange.
parameters: pCName type namespace memory id MNAMESPACE.
selection-screen end of line.
selection-screen: end of block b2.
Additional things to download.
selection-screen: begin of block b3 with frame title tBlock3.
selection-screen begin of line.
selection-screen comment 1(33) tPtext.
parameters: pText as checkbox default 'X' memory id MTEXT.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tMess.
parameters: pMess as checkbox default 'X' memory id MMESS.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tPinc.
parameters: pInc as checkbox default 'X' memory id MINC.
selection-screen comment 40(20) tRecc.
parameters: pReci as checkbox default 'X' memory id MRECI.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tPfunc.
parameters: pFunc as checkbox default 'X' memory id MFUNC.
selection-screen comment 40(20) tRecf.
parameters: pRecf as checkbox default 'X' memory id MRECF.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tDoc.
parameters: pDoc as checkbox default 'X' memory id MDOC.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tPscr.
parameters: pScr as checkbox default 'X' memory id MSCR.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tPdict.
parameters: pDict as checkbox default 'X' memory id MDICT.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(33) tSortT.
parameters: pSortT as checkbox default ' ' memory id MSORTT.
selection-screen end of line.
selection-screen: end of block b3.
File details
selection-screen: begin of block b4 with frame title tBlock4.
selection-screen begin of line.
selection-screen comment 1(20) tPhtml.
parameters: pHtml radiobutton group g1 default 'X'.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 5(29) tComm.
parameters: pComm as checkbox default 'X'.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 5(29) tBack.
parameters: pBack as checkbox default 'X'.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 1(20) tPtxt.
parameters: pTxt radiobutton group g1.
selection-screen end of line.
selection-screen skip.
Download to SAP server
selection-screen begin of line.
selection-screen comment 1(25) tServ.
parameters: pServ radiobutton group g2.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 8(20) tSPath.
parameters: pLogical like filename-fileintern memory id MLOGICAL.
selection-screen end of line.
selection-screen comment /28(60) tSDPath.
Download to PC
selection-screen begin of line.
selection-screen comment 1(25) tPc.
parameters: pPc radiobutton group g2 default 'X'.
selection-screen end of line.
selection-screen begin of line.
selection-screen comment 8(20) tPpath.
parameters: pFolder like rlgrap-filename memory id MFOLDER.
selection-screen end of line.
selection-screen: end of block b4.
Display options
selection-screen: begin of block b5 with frame title tBlock5.
Display final report
selection-screen begin of line.
selection-screen comment 1(33) tRep.
parameters: pRep as checkbox default 'X'.
selection-screen end of line.
Display progress messages
selection-screen begin of line.
selection-screen comment 1(33) tProMess.
parameters: pProMess as checkbox default 'X'.
selection-screen end of line.
selection-screen: end of block b5.
Display a directory picker window
at selection-screen on value-request for pFolder.
data: objFile type ref to cl_gui_frontend_services.
data: pickedFolder type string.
data: initialFolder type string.
if sy-batch is initial.
create object objFile.
if not pFolder is initial.
initialFolder = pFolder.
else.
objFile->get_temp_directory( changing temp_dir = initialFolder
exceptions cntl_error = 1
error_no_gui = 2
not_supported_by_gui = 3 ).
endif.
objFile->directory_browse( exporting initial_folder = initialFolder
changing selected_folder = pickedFolder
exceptions cntl_error = 1
error_no_gui = 2
not_supported_by_gui = 3 ).
if sy-subrc = 0.
pFolder = pickedFolder.
else.
write: / 'An error has occured picking a folder'.
endif.
endif.
at selection-screen.
case 'X'.
when pPc.
if pFolder is initial.
User must enter a path to save to
message e000(oo) with 'You must enter a file path'.
endif.
when pServ.
if pLogical is initial.
User must enter a logical path to save to
message e000(oo) with 'You must enter a logical file name'.
endif.
endcase.
at selection-screen on pLogical.
if not pServ is initial.
call function 'FILE_GET_NAME' exporting logical_filename = pLogical
importing file_name = serverFolder
exceptions file_not_found = 1
others = 2.
if sy-subrc = 0.
if serverFolder is initial.
message e000(oo) with 'No file path returned from logical filename'.
else.
Path to display on the selection screen
tSDPath = serverFolder.
Remove the trailing slash off the path as the subroutine buildFilename will add an extra one
shift serverFolder right deleting trailing serverSlashSeparator.
shift serverFolder left deleting leading space.
endif.
else.
message e000(oo) with 'Logical filename does not exist'.
endif.
endif.
at selection-screen on value-request for soProg-low.
call function 'REPOSITORY_INFO_SYSTEM_F4' exporting object_type = 'PROG'
object_name = soProg-low
suppress_selection = 'X'
use_alv_grid = ''
without_personal_list = ''
importing object_name_selected = soProg-low
exceptions cancel = 1.
at selection-screen on value-request for soProg-high.
call function 'REPOSITORY_INFO_SYSTEM_F4' exporting object_type = 'PROG'
object_name = soProg-high
suppress_selection = 'X'
use_alv_grid = ''
without_personal_list = ''
importing object_name_selected = soProg-high
exceptions cancel = 1.
at selection-screen on value-request for soClass-low.
call function 'F4_DD_ALLTYPES' exporting object = soClass-low
suppress_selection = 'X'
display_only = ''
only_types_for_clifs = 'X'
importing result = soClass-low.
at selection-screen on value-request for soClass-high.
call function 'F4_DD_ALLTYPES' exporting object = soClass-high
suppress_selection = 'X'
display_only = ''
only_types_for_clifs = 'X'
importing result = soClass-high.
at selection-screen on value-request for soFName-low.
call function 'REPOSITORY_INFO_SYSTEM_F4' exporting object_type = 'FUNC'
object_name = soFname-low
suppress_selection = 'X'
use_alv_grid = ''
without_personal_list = ''
importing object_name_selected = soFName-low
exceptions cancel = 1.
at selection-screen on value-request for soFName-high.
call function 'REPOSITORY_INFO_SYSTEM_F4' exporting object_type = 'FUNC'
object_name = soFname-high
suppress_selection = 'X'
use_alv_grid = ''
without_personal_list = ''
importing object_name_selected = soFName-high
exceptions cancel = 1.
at selection-screen on value-request for soFGroup-low.
call function 'REPOSITORY_INFO_SYSTEM_F4' exporting object_type = 'FUGR'
object_name = soFGroup-low
suppress_selection = 'X'
use_alv_grid = ''
without_personal_list = ''
importing object_name_selected = soFGroup-low
exceptions cancel = 1.
at selection-screen on value-request for soFGroup-high.
call function 'REPOSITORY_INFO_SYSTEM_F4' exporting object_type = 'FUGR'
object_name = soFGroup-high
suppress_selection = 'X'
use_alv_grid = ''
without_personal_list = ''
importing object_name_selected = soFGroup-high
exceptions cancel = 1.
initialisation
initialization.
Parameter screen texts.
tBlock1 = 'Author (Optional)'.
t$tmp = 'Programs only: include local objects'.
tBlock2 = 'Objects to download'.
tBlock3 = 'Additional downloads for programs, function modules and classes'.
tBlock4 = 'Download parameters'.
tBlock5 = 'Display options'.
tAuth = 'Author name'.
tPmod = 'Include programs modified by author'.
tCust = 'Only customer objects'.
tNRange = 'Alt customer name range'.
tRtable = 'Tables / Structures'.
tPtable = 'Table name'.
tTnote = 'Note: tables are stored under the username of the last person who modified them'.
tRfunc = 'Function modules'.
tPfname = 'Function name'.
tFgroup = 'Function group'.
tRClass = 'Classes'.
tPcname = 'Class name'.
tMess = 'Message class'.
tMName = 'Class name'.
tMLang = 'Language'.
tProg = 'Programs'.
tRpname = 'Program name'.
tPack = 'Package'.
tPtxt = 'Text document'.
tPhtml = 'HTML document'.
tComm = 'Highlight comments'.
tBack = 'Include background colour'.
tPtext = 'Text elements'.
tPinc = 'Include programs'.
tRecc = 'Recursive search'.
tPpath = 'File path'.
tSPath = 'Logical file name'.
tPmes = 'Message classes'.
tPfunc = 'Function modules'.
tDoc = 'Function module documentation'.
tRecf = 'Recursive search'.
tPscr = 'Screens'.
tPdict = 'Dictionary structures'.
tSortT = 'Sort table fields alphabetically'.
tServ = 'Download to server'.
tPc = 'Download to PC'.
tRep = 'Display download report'.
tProMess = 'Display progress messages'.
Determine the frontend operating system type.
if sy-batch is initial.
perform determineFrontendOPSystem using frontendSlashSeparator frontendOpSystem.
endif.
perform determineServerOpsystem using serverSlashSeparator serverFileSystem serverOpsystem.
Determine if the external command exists. If it doesn't then disable the server input field
perform findExternalCommand.
start-of-selection.
start-of-selection.
perform checkComboBoxes.
perform fillSelectionRanges.
startTime = sy-uzeit.
Don't display status messages if we are running in the background
if not sy-batch is initial.
pProMess = ''.
endif.
Fool the HTML routines to stop them hyperlinking anything with a space in them
if pCName is initial.
customerNameSpace = '^'.
else.
customerNameSpace = pCName.
endif.
Determine which operating slash and download directory to use
case 'X'.
when pPc.
slashSeparatorToUse = frontendSlashSeparator.
downloadFolder = pFolder.
when pServ.
slashSeparatorToUse = serverSlashSeparator.
downloadFolder = serverFolder.
endcase.
Main program flow.
case 'X'.
Select tables
when rTable.
perform retrieveTables using iDictionary[]
soTableNames[]
soAuthor[].
Select message classes tables
when rMess.
perform retrieveMessageClass using iMessages[]
soAuthor[] "Author
pMname "Message class name
pMLang "Message class language
pMod. "Modified by author
Select function modules
when rFunc.
perform retrieveFunctions using soFunctionName[] "Function name
soFunctionGroup[] "Function group
iFunctions[] "Found functions
soAuthor[] "Author
pText "Get text elements
pScr "Get screens
pCust "Customer data only
customerNameSpace. "Customer name range
loop at iFunctions.
Find Dict structures, messages, functions, includes etc.
perform scanForAdditionalFuncStuff using iFunctions[]
pRecI "Search for includes recursively
pRecF "Search for functions recursively
pInc "Search for includes
pFunc "Search for functions
pDict "search for dictionary objects
pMess "Search for messages
pCust "Customer data only
customerNameSpace. "Customer name range
endloop.
Select Classes
when rClass.
perform retrieveClasses using iClasses[]
iFunctions[]
soClassName[] "Class name
soAuthor[] "Author
customerNameSpace "Customer name range
pMod "Also modified by author
pCust "Customer object only
pMess "Find messages
pText "Text Elements
pDict "Dictionary structures
pFunc "Get functions
pInc "Get includes
pRecF "Search recursively for functions
pRecI "Search recursively for includes
'X' "Search recursively for classes
pMLang. "Language
loop at iFunctions.
Find Dict structures, messages, functions, includes etc.
perform scanForAdditionalFuncStuff using iFunctions[]
pRecI "Search for includes recursively
pRecF "Search for functions recursively
pInc "Search for includes
pFunc "Search for functions
pDict "search for dictionary objects
pMess "Search for messages
pCust "Customer data only
customerNameSpace. "Customer name range
endloop.
Select programs
when rProg.
perform retrievePrograms using iPrograms[]
iFunctions[]
soProgramName[] "Program name
soAuthor[] "Author
customerNamespace "Customer name range
pMod "Also modified by author
pCust "Customer object only
pMess "Find messages
pText "Text Elements
pDict "Dictionay structures
pFunc "Get functions
pInc "Get includes
pScr "Get screens
pRecF "Search recursively for functions
pRecI "Search recursively for includes
p$Tmp "local objects
pPack. "Package
endcase.
end-of-selection
end-of-selection.
if forcedExit = 0.
Set the file extension and output type of the file
if pTxt is initial.
downloadFileExtension = HTMLEXTENSION.
else.
downloadFileExtension = TEXTEXTENSION.
endif.
Decide what to download
case 'X'.
Download tables
when rTable.
if not ( iDictionary[] is initial ).
perform downloadDDStructures using iDictionary[]
downloadFolder
HTMLEXtension
space
pSortT
slashSeparatorToUse
pServ
pProMess.
Free up any memory used for caching HTML versions of tables
loop at iDictionary.
free memory id iDictionary-tablename.
endloop.
Display donwload report
if not pRep is initial.
get time.
runTime = sy-uzeit - startTime.
perform fillTreeNodeTables using iDictionary[]
iTreeDisplay[]
runTime.
endif.
clear iDictionary[].
endif.
Download message class
when rMess.
if not ( iMessages[] is initial ).
sort iMessages ascending by arbgb msgnr.
loop at iMessages.
append iMessages to iSingleMessageClass.
at end of arbgb.
perform downloadMessageClass using iSingleMessageClass[]
iMessages-arbgb
downloadFolder
downloadFileExtension
pHtml
space
pComm
customerNameSpace
pInc
pDict
pMess
slashSeparatorToUse
pServ
pProMess.
clear iSingleMessageClass[].
endat.
endloop.
Display download report
if not pRep is initial.
get time.
runTime = sy-uzeit - startTime.
perform fillTreeNodeMessages using iMessages[]
iTreeDisplay[]
runTime.
endif.
clear iMessages[].
endif.
Download functions
when rFunc.
if not ( iFunctions[] is initial ).
perform downloadFunctions using iFunctions[]
downloadFolder
downloadFileExtension
space
pDoc
pHtml
pComm
customerNameSpace
pInc
pDict
TEXTEXTENSION
HTMLEXTENSION
pSortT
slashSeparatorToUse
pServ
pProMess.
Free up any memory used for caching HTML versions of tables
loop at iFunctions.
loop at iFunctions-iDictStruct assigning <waDictStruct>.
free memory id <waDictStruct>-tablename.
endloop.
endloop.
Display donwload report
if not pRep is initial.
get time.
runTime = sy-uzeit - startTime.
perform fillTreeNodeFunctions using iFunctions[]
iTreeDisplay[]
runTime.
endif.
clear iFunctions[].
endif.
Download Classes
when rClass.
if not ( iClasses[] is initial ).
perform downloadClasses using iClasses[]
iFunctions[]
downloadFolder
downloadFileExtension
HTMLEXTENSION
TEXTEXTENSION
pHtml
pComm
custo -
Hi,
I would like to know if it's possible to export a function group to a file and then restore it again from this file.
What I need is a way to store in hard disk the function groups.
thanks in advanceHi Javier,
It is not possible to Export/Download whole Function Group to a file and restore it again from that file.
However, in general we download all the Includes and Screens individually by following:
Go to Include/Screen -> Utilities -> More Utilities -> Upload/Download -> Download
To upload the same Include/Screen:
First create Include/Screen with the same name. Then follow these steps
Go to Include/Screen -> Utilities -> More Utilities -> Upload/Download -> Upload
By this way, you can again get the whole Function Group in the system. Hope it helps.
Regards,
Neeraj Gupta -
SRM 4.0 - Upload function of Bid Invitations (Bidding Engine)
Hello,
I am currently working on the Bidding Engine in SRM 4.0
I would very much like to use the Download/Upload function in Bid Invitations, but for now I have the feeling it doesnt work.
I tested it by downloading a Bid Invitation and changing just one info like an item quantity or description. I put U (for Update) in the corresponding cell of the Change column. I also held the bid invitation in SRM before returning to it to upload the modified Excel-file.
When I upload the Excel file, I dont have any error messages, but no changes are done either.
Does anyone of you have an idea how I could make it work?
Thanks!
AndreaHi,
Please do the following things.
Excel updown/download is very flexible functionality.
(BADI : BBP_PD_DOWNLOAD)
1. You can change the format (how the document should be downloaded, which fields : Control variants in BBPC_UP_DOWNLOAD table)
2. You can also upload file (your own format : implement parsing method)
3. You can add your own fields. (APPEND_UPLOAD_DATA)
We are working on one such scenario for Contract Upload.
You can also check the following notes.
There is a SAP Note on downloading BID file.
Note 734060 - SRM: Upload and download of documents using MS Excel
They have given one example in this note.This is a consulting note,you will find it
Two more notes which can help you
734060
734946
I hope it will help.
BR,
Vijay Mittal
Plz award the points for help. -
Appraisal template download upload in excel
Hi All
We have the download upload functionality of appraisal template in PDF by offline layout setting in phap_catalog_pa. My query is can the upload and download of the template can be done in excel also. Our requirement is to download the appraisal template as configured in phap_catalog_pa in excel and then uploading back the same through portal. Please suggest if this can be done and how to proceed further.
ThanksI have found a solution. FM HRHAP_DOC_BODY_ENHANCE
In this example the program add two dynamic elements for qualification.
REPORT ZYS_APR_UPLOAD_DYN.
DATA: wa_prepare TYPE zys_upload,
g_template_id TYPE hap_template_id,
g_header_defaulting TYPE flag,
gs_return TYPE bal_s_msg,
gs_menu TYPE hap_s_menu, "for status
gs_appraisal_id TYPE hap_s_appraisal_id,
gs_doc_processing TYPE hap_s_doc_processing,
gs_header_texts TYPE hap_s_header_texts,
gs_header_status TYPE hap_s_header_status,
gs_header_dates TYPE hap_s_header_dates,
gt_header_add_data TYPE hap_t_header_add_data,
gs_header_display TYPE hap_s_header_display,
gt_header_appraiser TYPE hap_t_header_appraiser ,
gt_header_appraisee TYPE hap_t_header_appraisee ,
gt_header_p_appraiser TYPE hap_t_header_part_appraisers ,
gt_header_others TYPE hap_t_header_others,
gt_buttons TYPE hap_t_buttons,
gt_body_columns TYPE hap_t_body_columns,
gs_body_columns LIKE LINE of gt_body_columns,
gt_body_elements TYPE hap_t_body_elements,
gs_body_elements LIKE LINE of gt_body_elements,
gt_body_element_descr TYPE hap_t_body_element_descr,
gt_body_element_buttons TYPE hap_t_body_element_buttons,
gt_body_cells TYPE hap_t_body_cells,
gs_body_cells like line of gt_body_cells,
gt_body_cell_val_values TYPE hap_t_body_cell_val_values,
gt_body_cell_val_ranges TYPE hap_t_body_cell_val_ranges,
gt_body_cell_val_c_like TYPE hap_t_body_cell_val_c_like,
gt_body_cell_val_descr TYPE hap_t_body_cell_val_descr,
gt_body_cell_notes TYPE hap_t_body_cell_notes,
ls_header_appraiser TYPE hap_s_header_appraiser,
ls_header_appraisee TYPE hap_s_header_appraisee.
DATA: COUNTER(5) type n VALUE '00003',
lv_template_id TYPE objektid,
date type sy-datum,
lv_pernr TYPE pernr_d,
s_return TYPE bal_s_msg,
lt_status_notes TYPE hap_t_status_note,
lv_error TYPE flag,
ls_wd_return TYPE bal_s_msg,
ET_BODY_ELEMENTS_ADD type HAP_T_BODY_ELEMENTS_ADD,
wa_BODY_ELEMENTS_ADD like line of ET_BODY_ELEMENTS_ADD.
START-OF-SELECTION.
gs_header_dates-ap_start_date = '01.01.2014'.
"endda
gs_header_dates-ap_end_date = '31.12.2014'.
gs_header_dates-ap_date_set = '31.12.2014'.
"APPRAISER
FREE gt_header_appraiser.
ls_header_appraiser-plan_version = '01'.
ls_header_appraiser-type = 'P'.
lv_pernr = '1000800'."wa_prepare-value.
ls_header_appraiser-id = lv_pernr.
APPEND ls_header_appraiser TO gt_header_appraiser .
"APPRAISEE
FREE gt_header_appraisee.
ls_header_appraisee-plan_version = '01'.
ls_header_appraisee-type = 'P'.
lv_pernr = '1000800'."wa_prepare-value.
ls_header_appraisee-id = lv_pernr.
APPEND ls_header_appraisee TO gt_header_appraisee .
wa_BODY_ELEMENTS_ADD-NEW_ELEMENT_TYPE = 'Q'.
wa_BODY_ELEMENTS_ADD-NEW_ELEMENT_ID = '50000392'.
APPEND wa_BODY_ELEMENTS_ADD to et_BODY_ELEMENTS_ADD.
wa_BODY_ELEMENTS_ADD-NEW_ELEMENT_ID = '50000399'.
APPEND wa_BODY_ELEMENTS_ADD to et_BODY_ELEMENTS_ADD.
CALL FUNCTION 'HRHAP_DOC_BODY_ENHANCE'
EXPORTING
row_iid = '0001'"wd_comp_controller->enhance_row_iid
plan_version = '01'
s_appraisal_id = gs_appraisal_id
t_header_appraiser = gt_header_appraiser
t_header_appraisee = gt_header_appraisee
t_header_part_appraisers = gt_header_p_appraiser
t_header_others = gt_header_others
s_header_dates = gs_header_dates
s_header_status = gs_header_status
t_body_columns = gt_body_columns
* FREE_ENHANCEMENT = ' '
trusted_call = 'X'
enhancement_type = ' '
t_body_elements_add = et_body_elements_add
* T_BODY_ELEMENTS_STRUC_ADD =
IMPORTING
s_return = ls_wd_return
CHANGING
s_doc_processing = gs_doc_processing
t_body_elements = gt_body_elements
t_body_element_descr = gt_body_element_descr
t_body_element_buttons = gt_body_element_buttons
t_body_cells = gt_body_cells
t_body_cell_notes = gt_body_cell_notes
t_body_cell_val_values = gt_body_cell_val_values
t_body_cell_val_ranges = gt_body_cell_val_ranges
t_body_cell_val_c_like = gt_body_cell_val_c_like
t_body_cell_val_descr = gt_body_cell_val_descr.
"Saving document
CALL FUNCTION 'HRHAP_DOC_UPDATE_BODY_AND_SAVE'
EXPORTING
plan_version = '01'
IMPORTING
s_return = s_return
CHANGING
s_appraisal_id = gs_appraisal_id
s_doc_processing = gs_doc_processing
t_header_appraiser = gt_header_appraiser[]
t_header_appraisee = gt_header_appraisee[]
t_header_part_appraisers = gt_header_p_appraiser[]
t_header_others = gt_header_others
s_header_texts = gs_header_texts
s_header_dates = gs_header_dates
s_header_status = gs_header_status
s_header_display = gs_header_display
t_body_columns = gt_body_columns
t_body_elements = gt_body_elements
t_body_cells = gt_body_cells[]
t_body_cell_notes = gt_body_cell_notes
t_status_notes = lt_status_notes.
IF s_return IS NOT INITIAL .
WRITE: / s_return-msgid , s_return-msgty ,s_return-msgno ,s_return-msgv1, s_return-msgv2, s_return-msgv3 .
ENDIF.
counter = counter + 1. -
Function Group : Upload/ download
Hi Experts,
is there any Function group which will help me upload/download excel file?Kindly advise.
thanks & regards,
M.SYes you can but you must save data in text mode (tabulation or delimited) .
It's not possible to upload directly a excel file with GUI_UPLOAD
But it's possible with ALSM_EXCEL_TO_INTERNAL_TABLE.
Rgds -
Regarding uploading the function group
Hi All,
I have a requirement like this....
I have a selection screen which consists of function group name...and two options upload and download...
If i click on download option and supply the function group name..then it will download all the function group related stuff like function modules, includes,etc..
this download option is working fine...
Now my problem is in upload option...
how can i upload all the files and it forms a function group...
I created a function group zfgroup and downloaded all the files related to this like function modules and include files...and deleted that function group...
now using these files i have to create the function group when i click on the upload option.
hope you guys got this question...
thanks and regards
raghuHi,
Check the solution you are look in for inthis link.
<a href="/people/alvaro.tejadagalindo/blog/2006/03/18/taking-good-care-of-z-function-modules utility</a>
Hope this helps.
Cheers
VJ
Message was edited by: Vijayendra Rao -
How to Down load & upload Fuction Group as a whole including all Function ?
Hi,
Is there any way for downloading Function Group along withh all its Function Modules from one system & upload into another.
There is no Remote Connection & Transport is not possible.
Thanks
SwathiHi,
Thanks for your reply.
But I cannot create this proogram in one of my systems as this is Quality system.
Any other clue?
Thanks
Swathi -
HR Renewal: Client infotype with upload/download file functionality
Hi Gurus,
I am writing to you today cuz a client of mine asked me to adapt one of their client-specific infotype for HR Renewal. Now the old-legacy infotype was developed by someone else so I am just to adapt the functionality for decoupled infotype framework and front-end.
The infotype has no subtype and record from 01.01.1800 to 31.12.9999 with a table-control listing all the pdf (or other format) file for a particular employee (such has income tax statement; SEPA bank account sheet; ID card etc... any kind of personal document relevant to employees). (that data is listed from a client Z table when opening the infotype; e.g. there is not sub-strucutrue in the pnnnn to represent that information).
upload, download and open file functionality is done via the infotype old-framework screen 2000 by some custom code merely replicated what is available by cl_gui_services.
File are stored directly on the SAP system not using the GOS option;
back-end stuff is more or less done and working at least I can do pretty much what I want in puit_ui tcode; read;modify... off course no file upload there
front-end is another story; I have managed the FPM views for the infotype (dataset; biz card, etc) and also I have managed to list the existing file in the ATS list.
However What I need still to do is to be able to upload from NWBC files to the back end system; and also download or open them. this seems to be a little harder than expected.
I am now doubting if I should rather do a P&F FPM form based or if I can achieve what it is suppose to do? or maybe I should go back to the client and talk him through changing that infotype architecture? using subtype instead of a connection to a Z table and GOS services to store employee files seems way easier for me; but still I am facing the upload/download functional which I dont really no how to wrap around the FPM either it is ATS or GL2. I have checked indian-specific infotype 3743 has this uploading functionality (GOS) but no corresponding FPM I could inspire myself on!
Also, not sure if I am missing something but when I try to change the value of one the field on the infotype pnnnn structure (that infty actually has one checkbox field) and save I end up with a dump because to BOL model does not find my entity (lo_entity). it s not the first infotype I am enabling for HR Renewal and I never had this error before.. I wonder what I am missing....
Would you gurus oriente me a lil on how I should best proceed? should I rather use P&F? Your help and advise would greatly be appreciated!
Thanks.Hello:
So after some thinking through:
- upload and download are handler by the FPM ATS feeder (client copy with enhanced options into to manage event method).
- lo_entity without pointer causing dump occurred because I had inconsistently used the set automatic tag option into the FPM configuration floorplan editor.
- PAOC_ASR_PERSONAL_FILE would be my recommendation but client want to follow on its own mini-dev for personal file hosting.
Thank you gurus! -
FTR_SUBSCR Function Group Download in a EHP4 version
Hi Guys
Im facing an upgrade from 4.6C to an Ecc 6.0 and unfortunally my client had the brilliant idea to install the EHP4 in your QAS system but ddnt installed in the DEV system...
I dont need to mention that transporting the requests from DEV to QAS some of them gave errors..
What i need now it's the FTR_SUBSCR function group EHP4 version in order to compare in the DEV system version but im not getting to the original version thru SE95..
Can anyone donwload this function group in and version with the EHP4 instaled and send it to me? i'll be appreciated.
johnny_martinsAThotmail.com
thanks in advance
Best Regards
João Martins
Edited by: joao martins on Nov 3, 2009 11:26 PMZ program to download all Z programs,
refer the post by " Arun Sambargi"
check this link,will be useful for you.
Regards
Srikanth
Message was edited by: Srikanth Kidambi -
Any Program/Function module to Download/Upload Smartform?
Hi All,
I had forgotten in my previous thread to mention that I dont have option Utilities->Download/Upload Form in t-code SMARTFORMS. so I am looking for alternative method to download or upload the smartform..pls help me out.
Regards
Shaik.Not that I'm aware of. But here some code for ya.
report zrich_0001.
Parameters: d2 type localfile default '/usr/sap/TST/SYS/Data1.txt'.
data: begin of itab occurs 0,
rec(20) type c,
end of itab.
data: wa like line of itab.
start-of-selection.
wa-rec = 'Test'.
append wa to itab.
open dataset d2 for output in text mode.
loop at itab.
transfer itab to d2.
endloop.
close dataset d2.
Regards,
Rich Heilman -
GUI_DOWNLOAD and UPLOAD Function Modules?
Hi All,
What exactly done by GUI_DOWNLOAD and UPLOAD Function Modules?
Akshitha.What you exactly want know?
Here is the Sap documentation for both FM:
FU GUI_UPLOAD
Short Text
Upload for Data Provider
Functionality
The module loads a file from the PC to the server. Data can be transferred binarily or as text. Numbers and date fields can be interpreted according to the user settings.
Example
Binary upload: No conversion or interpretation
begin of itab,
raw(255) type x,
end of itab occurs 0.
CALL FUNCTION 'GUI_UPLOAD'
exporting
filetype = 'BIN'
filename = 'C:\DOWNLOAD.BIN'
tables
data_tab = itab.
Text upload
begin of itab,
text(255) type c,
end of itab occurs 0.
CALL FUNCTION 'GUI_UPLOAD'
exporting
filetype = 'ASC'
filename = 'C:\DOWNLOAD.TXT'
tables
data_tab = itab.
Parameters
FILENAME
FILETYPE
HAS_FIELD_SEPARATOR
HEADER_LENGTH
READ_BY_LINE
DAT_MODE
CODEPAGE
IGNORE_CERR
REPLACEMENT
CHECK_BOM
VIRUS_SCAN_PROFILE
NO_AUTH_CHECK
FILELENGTH
HEADER
DATA_TAB
Exceptions
FILE_OPEN_ERROR
FILE_READ_ERROR
NO_BATCH
GUI_REFUSE_FILETRANSFER
INVALID_TYPE
NO_AUTHORITY
UNKNOWN_ERROR
BAD_DATA_FORMAT
HEADER_NOT_ALLOWED
SEPARATOR_NOT_ALLOWED
HEADER_TOO_LONG
UNKNOWN_DP_ERROR
ACCESS_DENIED
DP_OUT_OF_MEMORY
DISK_FULL
DP_TIMEOUT
Function Group
SFES
FU GUI_DOWNLOAD
Short Text
Download an Internal Table to the PC
Functionality
Data transfer of an internal table form the server to a file on the PC. The Gui_Download module replaces the obsolete modules Ws_Download and Download. The file dialog of the download module is available in the class Cl_Gui_Frontend_Services.
Further information
TYPE-POOLS: ABAP.
Binary download table
DATA: BEGIN OF line_bin,
data(1024) TYPE X,
END OF line_bin.
DATA: data_tab_bin LIKE STANDARD TABLE OF line_bin.
Ascii download table
DATA: BEGIN OF line_asc,
text(1024) TYPE C,
END OF line_asc.
DATA: data_tab_asc LIKE STANDARD TABLE OF line_asc.
DAT download table
DATA: BEGIN OF line_dat,
Packed TYPE P,
Text(10) TYPE C,
Number TYPE I,
Date TYPE D,
Time TYPE T,
Float TYPE F,
Hex(3) TYPE X,
String TYPE String,
END OF line_dat.
DATA: data_tab_dat LIKE STANDARD TABLE OF line_dat.
Get filename
DATA: fullpath TYPE String,
filename TYPE String,
path TYPE String,
user_action TYPE I,
encoding TYPE ABAP_ENCODING.
CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_SAVE_DIALOG
EXPORTING
WINDOW_TITLE = 'Gui_Download Demo'
WITH_ENCODING = 'X'
INITIAL_DIRECTORY = 'C:\'
CHANGING
FILENAME = filename
PATH = path
FULLPATH = fullpath
USER_ACTION = user_action
FILE_ENCODING = encoding
EXCEPTIONS
CNTL_ERROR = 1
ERROR_NO_GUI = 2
NOT_SUPPORTED_BY_GUI = 3
others = 4.
IF SY-SUBRC <> 0.
EXIT.
ENDIF.
IF user_action <> CL_GUI_FRONTEND_SERVICES=>ACTION_OK.
EXIT.
ENDIF.
Download variables
DATA: length TYPE I.
Binary download
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
FILENAME = fullpath
FILETYPE = 'BIN'
IMPORTING
FILELENGTH = length
TABLES
DATA_TAB = data_tab_bin
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.
Ascii download
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
FILENAME = fullpath
FILETYPE = 'ASC'
IMPORTING
FILELENGTH = length
TABLES
DATA_TAB = data_tab_asc
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.
DAT download
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
FILENAME = fullpath
FILETYPE = 'DAT'
IMPORTING
FILELENGTH = length
TABLES
DATA_TAB = data_tab_dat
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.
Parameters
BIN_FILESIZE
FILENAME
FILETYPE
APPEND
WRITE_FIELD_SEPARATOR
HEADER
TRUNC_TRAILING_BLANKS
WRITE_LF
COL_SELECT
COL_SELECT_MASK
DAT_MODE
CONFIRM_OVERWRITE
NO_AUTH_CHECK
CODEPAGE
IGNORE_CERR
REPLACEMENT
WRITE_BOM
TRUNC_TRAILING_BLANKS_EOL
WK1_N_FORMAT
WK1_N_SIZE
WK1_T_FORMAT
WK1_T_SIZE
WRITE_EOL
FILELENGTH
DATA_TAB
FIELDNAMES
Exceptions
FILE_WRITE_ERROR
NO_BATCH
GUI_REFUSE_FILETRANSFER
INVALID_TYPE
NO_AUTHORITY
UNKNOWN_ERROR
HEADER_NOT_ALLOWED
SEPARATOR_NOT_ALLOWED
FILESIZE_NOT_ALLOWED
HEADER_TOO_LONG
DP_ERROR_CREATE
DP_ERROR_SEND
DP_ERROR_WRITE
UNKNOWN_DP_ERROR
ACCESS_DENIED
DP_OUT_OF_MEMORY
DISK_FULL
DP_TIMEOUT
FILE_NOT_FOUND
DATAPROVIDER_EXCEPTION
CONTROL_FLUSH_ERROR
Function Group
SFES -
Hi all,
I tried to upload the Data from flat file into internal table but it is displaying some thing wrong please go through the program, flatfile and output and please suggest me.
Program:
data : begin of itab occurs 0,
kunnr type kna1-kunnr,
Name1 type kna1-name1,
ort01 type kna1-ort01,
land1 type kna1-land1,
end of itab.
CALL FUNCTION 'UPLOAD'
EXPORTING
CODEPAGE = ' '
FILENAME = 'c:/test.txt'
FILETYPE = 'asc'
ITEM = ' '
FILEMASK_MASK = ' '
FILEMASK_TEXT = ' '
FILETYPE_NO_CHANGE = ' '
FILEMASK_ALL = ' '
FILETYPE_NO_SHOW = ' '
LINE_EXIT = ' '
USER_FORM = ' '
USER_PROG = ' '
SILENT = 'S'
IMPORTING
FILESIZE =
CANCEL =
ACT_FILENAME =
ACT_FILETYPE =
TABLES
data_tab = itab
EXCEPTIONS
CONVERSION_ERROR = 1
INVALID_TABLE_WIDTH = 2
INVALID_TYPE = 3
NO_BATCH = 4
UNKNOWN_ERROR = 5
GUI_REFUSE_FILETRANSFER = 6
OTHERS = 7
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
loop at itab.
write : / itab-kunnr, itab-name1, itab-ort01, itab-land1.
endloop.
test file have the following data sapetated by tab spaces:
0001 Ranjith nrml in
0002 mahesh nzb us
and the Output is some thing errotic as below
0001#Ranji th#nrml#in
0002#mahes h#nzb#us
Please suggest me
Thanks in advance.flie save as tab deilmeter.
Download/Upload SAP Users Favorites
This program allows you to transfer the user Favorites from one PC to another.
Written by : SAP Basis, ABAP Programming and Other IMG Stuff
http://www.sap-img.com
REPORT ZFAVORITES.
DATA : G_FILE(128) TYPE C.
DATA : G_PATH(80) TYPE C.
DATA : G_END(8) TYPE C.
DATA : G_SUBRC LIKE SY-SUBRC.
PARAMETERS: P_UNAME LIKE SY-UNAME DEFAULT SY-UNAME.
PARAMETERS: P_LANGU LIKE SY-LANGU DEFAULT SY-LANGU.
SELECTION-SCREEN SKIP.
PARAMETERS: P_IMP RADIOBUTTON GROUP ACT .
PARAMETERS: P_EXP RADIOBUTTON GROUP ACT DEFAULT 'X'.
SELECTION-SCREEN ULINE.
SELECTION-SCREEN BEGIN OF BLOCK FIL.
PARAMETERS: P_TYPE LIKE RLGRAP-FILETYPE DEFAULT 'ASC'.
PARAMETERS: P_PATH LIKE G_PATH DEFAULT 'C:TEMPXXX.MEN'.
SELECTION-SCREEN END OF BLOCK FIL.
DATA: IT_USER_NODES TYPE TABLE OF BXMNODES1 WITH HEADER LINE.
DATA: IT_FAV_NODES TYPE TABLE OF BXMNODES WITH HEADER LINE.
DATA: BEGIN OF IT_PCF OCCURS 0,
LINE(4096) TYPE C.
DATA: END OF IT_PCF.
INITIALIZATION.
REPLACE 'XXX' WITH SY-UNAME INTO P_PATH.
CONDENSE P_PATH NO-GAPS.
SY-TITLE = 'UPLOAD/DOWNLOAD FAVORITE'.
START-OF-SELECTION.
CLEAR IT_USER_NODES[].
CLEAR IT_FAV_NODES[].
G_FILE = P_UNAME.
IF P_UNAME <> SY-UNAME.
MESSAGE W398(00) WITH 'CURRENT USER <> USER TO BE MODIFIED!'.
ENDIF.
IF P_IMP = 'X'.
PERFORM IMPORT_FAV TABLES IT_FAV_NODES.
PERFORM WRITE_FAV_DB TABLES IT_FAV_NODES.
ELSEIF P_EXP = 'X'.
PERFORM EXPORT_FAV TABLES IT_FAV_NODES.
ENDIF.
FORM DATA_EXPORT TABLES PIT_PCF
USING P_FILE.
CALL FUNCTION 'DOWNLOAD'
EXPORTING
FILENAME = P_FILE
FILETYPE = P_TYPE
TABLES
DATA_TAB = PIT_PCF
EXCEPTIONS
FILE_OPEN_ERROR = 1
FILE_WRITE_ERROR = 2
INVALID_FILESIZE = 3
INVALID_TABLE_WIDTH = 4
INVALID_TYPE = 5
NO_BATCH = 6
UNKNOWN_ERROR = 7
GUI_REFUSE_FILETRANSFER = 8
OTHERS = 9.
IF SY-SUBRC NE 0.
WRITE: / 'FAILURE IN DOWNLOAD' , P_FILE.
ENDIF.
ENDFORM.
FORM DATA_IMPORT TABLES PIT_PCF
USING P_FILE P_SUBRC.
CALL FUNCTION 'UPLOAD'
EXPORTING
FILENAME = P_FILE
FILETYPE = P_TYPE
TABLES
DATA_TAB = PIT_PCF
EXCEPTIONS
CONVERSION_ERROR = 1
FILE_OPEN_ERROR = 2
FILE_READ_ERROR = 3
INVALID_TABLE_WIDTH = 4
INVALID_TYPE = 5
NO_BATCH = 6
UNKNOWN_ERROR = 7
GUI_REFUSE_FILETRANSFER = 8
OTHERS = 9.
IF SY-SUBRC NE 0.
WRITE: / 'UPLOAD FAILED' , P_FILE.
P_SUBRC = SY-SUBRC .
ENDIF.
ENDFORM.
FORM IMPORT_FAV TABLES PIT_FAV_NODES STRUCTURE IT_FAV_NODES.
G_FILE = P_PATH.
PERFORM DATA_IMPORT TABLES IT_FAV_NODES USING G_FILE G_SUBRC .
ENDFORM.
FORM EXPORT_FAV TABLES PIT_FAV_NODES STRUCTURE IT_FAV_NODES.
CALL FUNCTION 'BX_FAVOS_READ_ALL_NODES'
EXPORTING
USER_NAME = P_UNAME
LANGUAGE = P_LANGU
TABLES
OUTPUT_NODES_AND_TEXTS = IT_FAV_NODES.
G_FILE = P_PATH.
PERFORM DATA_EXPORT TABLES IT_FAV_NODES USING G_FILE .
ENDFORM.
FORM WRITE_FAV_DB TABLES PIT_FAV_NODES STRUCTURE IT_FAV_NODES.
CALL FUNCTION 'BX_FAVOS_WRITE_ALL_NODES'
EXPORTING
USER_NAME = P_UNAME
TARGET_CLIENT = SY-MANDT
TABLES
INPUT_NODES_AND_TEXTS = PIT_FAV_NODES.
ENDFORM.
Fast Links:
Sample Download Programs:
Download in Background in Excel Format
Download/Upload ABAP program from Local Harddisk
Get help for your ABAP problems
Do you have a ABAP Question?
SAP Books
SAP Certification, Functional, Basis Administration and ABAP Programming Reference Books
ABAP Programming Tips
ABAP Forum for Discussion and Samples Program Codes for Abapers
Best regards,
SAP Basis, ABAP Programming and Other IMG Stuff
http://www.sap-img.com
All the site contents are Copyright © www.sap-img.com and the content authors. All rights reserved.
All product names are trademarks of their respective companies. The site www.sap-img.com is in no way affiliated with SAP AG.
Every effort is made to ensure the content integrity. Information used on this site is at your own risk.
The content on this site may not be reproduced or redistributed without the express written permission of
www.sap-img.com or the content authors. -
QM-IDI : User QMIDI has no RFC authorization for function group QIRF
Hi,
I am in the process of trying to connect from Labware LIMS to SAP ECC 6, specifically the quality module. The aim is to use Labware to connect to SAP via the QM-IDI interface to
1) Download inspection lots from SAP
2) Upload usage decisions and inspection lot results to SAP.
Initially I specified an account on SAP of the type 'Communications Data', however any time I tried to connect to SAP from LIMS via the interface with this account it gives an <i>'Incorrect Username/Password'</i> error in the trace logs. I then changed the account to a dialog user, which seems to be partially more successful, however the trace logs captures the following error 'User QMIDI has no RFC authorization for function group QIRF' when I try to connect from LIMS to SAP via the QM-IDI interface after changing the user to type dialog.
I would appreciate any guidance on how to resolve this issue.
Regards.i got stuck on configuring idi. plz guide me. bond_chaitu at yahoo dot com
Maybe you are looking for
-
Auto clearence in 2 g/l account
HI, Every boy, pls find help to solve the problem stated below SAR Report is sent on a weekly basis to Businesses and on a monthly basis to the Risk Committee; Steps involved collating this report; 1. We process the Customer Outstanding open item
-
W8.1/W7-64 dual boot, dual drive (SSD & SATA) GPT/MBR problems
I'm posting in both the W8 and W7 forums because I'm not sure which is more appropriate. Setup: New Dell XPS8700 with Windows 8.1 installed on a 256GB SSD drive. I upgraded to W8.1 Pro. 2nd drive is a 2TB SATA. Goal: Keep W8.1 Pro on SSD. Install W7
-
Thin white halo around objects
After I outline strokes or text I get a white halo, kind of looks like a thin stroke, around the object after I place it over a colored background. It's not a stroke though. Is there any way to fix this problem?
-
Why directed to download flash player when I already have it?
this is my first problem encountered while downloading Adove Flash Player. I was trying to watch video on you tube. after i clicked the start button to begin, it asked to download "Adove flash player" to watch this video. I was never asked to do this
-
I'm trying to install itunes on my new computer and I keep getting the error message about Windows Installer. I've seen the other posts regarding this issue, however, I am unable to even get it to load for it to show up under "Programs".