You are viewing this site as a guest. You can still ask questions and help others! Join our Dev2Dev IT Community to receive your own blog, share your knowledge, and much more.

Add attachment On a page

4 replies [Last post]
PARITOSH's picture
User offline. Last seen 9 years 17 weeks ago. Offline
Joined: 06/16/2010
Posts: 19

How to create add attachment on a peoplesoft page by clicking which it will directed to a brows button and one can upload files from their....

csnrkrishna's picture
User offline. Last seen 6 years 36 weeks ago. Offline
Joined: 10/29/2010
Posts: 7
Re: Add attachment On a page

hi ,
the below function may helpfull for u.
................................................................
AddAttachment({FilePath | FileURL}, FilePathType, FileName, FileDescr, OverrideContentType, OverrideCharset)
..................................................................
FilePath | FileURL
You can either specify the file path to the file, or a URL to the file.

Depending on the FilePathType parameter, you may specify either a relative or absolute file path to the file.

This parameter should include the file name and extension of the file.

If you specify a URL address where the file is located, it must be an absolute URL. This URL should include the actual name of the file. If you specify a URL address, you must specify the FilePathType parameter as %FilePath_Absolute.

FilePathType
Specify the path type for the file, whether it is an absolute or relative path. The values are:

%FilePath_Absolute — the file path is an absolute path.

%FilePath_Relative — the file path is a relative path.

FileName
Specify the name of the file that you want to attach, as a string. You must include the file extension as well.

Description
Specify a description of the file.

OverrideContentType
The system detects the content type of the attachment using the file location and name. Specifying OverrideContentType overrides the system detected content type.

The character set can also be included in the ContentType. For example, “text/plain; charset=US-ASCII”

OverrideCharset
Specify a character set to be used to override the existing character set.

PARITOSH's picture
User offline. Last seen 9 years 17 weeks ago. Offline
Joined: 06/16/2010
Posts: 19
Re: Add attachment On a page

Thanks Krishna................

Lepa's picture
User offline. Last seen 1 year 24 weeks ago. Offline
Joined: 06/23/2008
Posts: 591
Re: Add attachment On a page

Take a look at this post I've made a while back. You can dig around in this component to see how PeopleSoft did it. http://www.compshack.com/peoplesoft/peoplecode/upload-files-peoplesoft-file-attachment

Give back to the community and help it grow!
* Help with unanswered forum questions and issues
* Register or login to share your knowledge at your own blog

Guest's picture
Guest (not verified)
Re: Add attachment On a page

Thanks a lot for ur concer Lepa...I had alredy read that and with refference to that post I am able to uplod the attachment...

I have use delivered code for add,detach and delet attachments from peoplebook.

Now the isssue is that though i am able to upload but attachments are not getting saved in database.

As per peoplebook i had tried to use delivered subrecord FILE_ATTDET_SBR,But its not working...

Any suggetions..

Setup:
1.FILE_ATCH_WRK
ADD,DELET AND DETACH pushbutton with delivered peoplecode from PeopleBook.
2.FILE_TEMP
with only a delivered subrecord
FILE_ATTACH_SBR
3.FILE_SAVE
with only a delivered subrecord
FILE_ATTDET_SBR .

Please help