Display a MS Word Document
Hello Everyone,
I have been asked to display a MS Word Document via one of me APEX applications. I realise this may be a complicated process, but can some one point me in the rite direction.
Thanks,
-N.S.N.O.
Hey Guys,
Thanks for all your replies. I am aware of the security issue here. This application will never be on the internet, as in anyone can connect to it from any where in the world, it will only be accessible from the network of the company form where i work.
Roel please could you expand on what you suggested, how could i make the :J drive accessible and how would i go about making an alias for it?
I have also thought about having the users upload the document to APEX and then select it from within APEX. Sort of like what Paul suggested. Would this be a better approach?
Thanks,
-N.S.N.O.
Similar Messages
-
Non-Display of attached word document in Project builder
Hi,
I am not able display / view the word document attached to the WBSE in the Project builder. We are not using DMS for keeping documents. Please suggest to fix the issue.
Thanks & Regards,
RanjanHi,
Thanks for your reply. I am assigning the document to the WBSE and that time it is asking for path of document to be attached. I am assigning the document from my local machines.
While opening the document or displaying, system is showing 46.080 bytes tranfered & no document. However if i will attach excel file there is no issue on that.
Could you please sugegst on this.
Thanks & Regards,
Ranjan -
Can I display a MS Word Document as part of a page
Hi,
Is it possible to display a MS Word document as part of a page (i.e. in a panelForm, panelBox) with ADF Faces? Any help is appreciated.
Best Regards,
SalimHi,
No, its impossible. I have never had that requirement, but if you want to review Word document as JSF page fragment, you can try to create helper servlet that gets MS Word and converts it to HTML (e.g using Apache POI - library to access Microsoft format files http://poi.apache.org/ ). Then you can try display this HTML using iframe or <jsp:include> and <f:verbatim> tag in your jsf page. I'ts my fast and free think - I have never tried this.
Kuba -
Displaying PDF and Word Document
Hi,
I have used the methods to display HTML :
1. Link to Action and the IFrame -> The Result was the html file I was able to display in the same window.
2. Link to URL -> The Result was html file opened in different window.
3.IFrame and attaching the file in project -> it was resulted in html file getting dispalyed in IFrame.
Now if I want to extend the functionality for PDF or word document, is the procedure same or different
Can anyone enlighten me on this
Any thoughts on this.
Thanks in Advance
SrikantHi srikant,
You can also display word documents and pdf by uploading it in the server.
For this you'll have to create aliases in the server for the corressponding documents that you want to uploaad.
Go to visual admin ->services->httpprovider.
Then click the tab 'aliases'. Here you can give the name of your alias and also the document to which the alias should point(first upload the document to the server machine and then give the path here ) .
Now when you type http://server:port/aliasname your document will open in the browser. You can display it either through your iFrame or linktourl as you prefer.
Hope my effort will help you.
Regards,
Rahul. -
Urgent-- Display a MS Word document in a JEditorPane
Hi All, When i try to display the contents of MS word document using a JEditorPane, certain junk value gets displayed before and after the actual text... can i get any help...
Thanx in advance...Desktop.open(File)
And as an aside, you are lucky I am so bored. Usually I would close a post offering just one Duke, without any reply. -
Hot to display PDF and Word documents as an attachment in OBIEE Reports
Hi,
From few of Oracle threads I learnt that we can store the files in a server locaiton and read it thro a URL. What I am trying to do is, PDF or Word document will be stored in database as BLOB fields. This BLOB field needs to be come as an attachment in OBIEE Reports and by clicking that icon, it uses the local applicaiton PDF reader or a word applicaiton and open the attachment, just like how we open an attachment from a E-mail. Can you please help me with the possible methods of that. I can provide you more information incase if you need.
Thanks
AugesthiAs long as you used the paper-clip Attach icon, that should be fine.
The entire document appears to you because your Mac recognizes the document type, and displays it for you, saving you from having to mouse around and find a Reader for it. You can still use the Save icon to save a copy of only the attachment.
To avoid problems with other email readers, be sure the checkbox [√] send windows-friendly attachments is checked.
I addition, some email readers cannot cope with any attachments positioned at any place in the document other than at the very end. So make sure you move the cursor to the absolute end of the document before clicking "Attach".
If all else fails, send an email that says, "attachment to follow", then send the attachment right away in a separate email, with nothing else in the body of the message. Some use the Subject abbreviation (nt) to indicate "no text", that is, no words typed in the message portion. -
Display Word Document as read only in VI pannel
In a VI pannel I put an Active X container with the IE browser to display Word documents.
The document are displayed properly but I want not give the user the possibility to make changes while viewing.
Is there a solution to do so?
(The documents are read-only and can not be saved.)Why use an IE container to display Word documents? You can place a word document directly in the ActiveX container. This seems a better choice.
If you wish to totally block user-input, you can place a transparent picture control over the display of the Word document.
Another alternative would be to convert the word document to a PDF and show this in an AcviteX container.
Shane.
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2) -
Generated Word document from Robohelp HTML
Hi Everyone,
I have two questions regarding the word document i have
generated from RH HTML.
First, in my Word document which i have generated from RH
HTML my footer is not displaying the one i have used in online
help.
Second, the hyperlinks i have in my online help, they are
also not displaying in the Word document.
I would appreciate if anybody who knows the answer to it and
can please let me know.
ThanksHeaders and footers are not transferred across.
Hyperlinks are only available in RH6 or better.
Take a look at the topic on Printed Documentation on my site. -
How can I display the date a word document was last modified on my web page?
I have lists of links to word documents on my web pages. I
want to be able to show the date the word document was last
modified next to each link. My pages are straight html.
Thanks.>but I would have to go to each individual file (I have
hundreds) and put this code on each link.
No, you can use the FileSystemObject to get a list of the
files in the directory. See if you can adapt this for your site:
<link href="/CSS/dirlist.css" rel="stylesheet"
type="text/css">
<%
Function FormatSize(SizeInBytes)
if SizeInBytes > 1024^2 then
FormatSize = formatnumber(SizeInBytes / 1024^2,2) & "
MB"
elseif SizeInBytes > 1024 then
FormatSize = formatnumber(SizeInBytes / 1024,2) & " KB"
else
FormatSize = SizeInBytes & " Bytes"
end if
end function
%>
<%
dim parts
dim part
dim BrowseLine
dim RelLink
dim i
url = Request.ServerVariables("URL")
Parts = split(URL,"/")
for part = 1 to ubound(Parts)-1
' calc link
RelLink = ""
for i = 1 to ubound(Parts) - part - 1
RelLink = RelLink & "..\"
next
If trim(BrowseLine) <> "" then
BrowseLine = BrowseLine & "/"
end if
BrowseLine = BrowseLine & "<A href=" & RelLink
& ">" & parts(part) & "</A>"
next
' add "back" link
BrowseLine = Browseline & " " &
"<A href='javascript:history.back();'><img
src='/images/return.gif' border=0></A>"
Response.Write "<P class = 'NavTop'>" & BrowseLine
& "</P>"
Dim fso
set fso = server.CreateObject("Scripting.fileSystemObject")
dim fldr
dim fle
%>
<a href="../index.asp"><img
src="../images/leftbanner.jpg" width="343" height="70"
border="0"></a>
<link href="/CSS/dirlist.css" rel="stylesheet"
type="text/css">
</p>
<p></p>
<table width="85%" border="0" cellspacing="0"
cellpadding="0">
<tr>
<th width="63%"><div
align="left"> Document
Name</div></th>
<th width="14%">Size</th>
<th width="23%"><div
align="left"> Date</div></th>
</tr>
<%
' display folders
for each fldr in
fso.GetFolder(server.MapPath(".")).SubFolders
%>
<tr>
<td class="FileName"> <a href='<%=
fldr.Name %>'><img src="/images/folder.gif" border=0>
<%= fldr.Name %></a></td>
<td class="FileSize"> <%=
FormatSize(fldr.Size) %></td>
<td class="FileDate"><div
align="left"> <%=
FormatDateTime(fldr.DateLastModified,2)
%></div></td>
</tr>
<%
next
%>
<%
' display files
for each fle in fso.GetFolder(server.MapPath(".")).Files
dim ext
ext = fso.GetExtensionName(fle.path)
if (ext <> "asp") and (ext <> "scc") then
%>
<tr>
<td class="FileName"> <a href='<%=
escape(fle.Name) %>'><img src="/images/file.gif"
width="14" height="16" border=0>
<%= fle.Name %></a></td>
<td class="FileSize"> <%=
FormatSize(fle.Size) %></td>
<td class="FileDate"><div
align="left"> <%=
FormatDateTime(fle.DateLastModified,2) %></div></td>
</tr>
<%
end if
next
Set fso = Nothing
Set fle = Nothing
Set fldr = Nothing
%>
</table>
<p><a href="/index.asp">Return to Home
Page</a></p> -
Displaying Word Document from a Database
Let me try to explain this.
I can upload and store a Word Document in an Oracle database
(BLOB column) but now I need to extract that Word document and
place a pointer to it on the Web. Can someone explain to me how
this is done?
I'm trying to do something like have an image displayed on
the Web and when you click on it the Word Document is opened.
Follow me on that? So, if there are 15 Word documents in the
database, then the web page would have 15 images all pointing to
each separate Word document.
Has anyone done this?Don't take my word on this, but I think this should work;
I've done this in the past to send dynamically-generated CSV files
to the user, which is in a way (at least at the perspective of
what's being outputted to the user) the same thing.
First, obviously, you need to retrieve the Word document data
from the database. We'll say you put that in a variable called
'wordDoc'.
<cfset wordDoc = someQuery.wordDataObj />
Next, we need to set the 'Content-disposition' HTTP header,
to tell the client's browser that we're sending a file, and that we
want you to call it somefile.doc by default. We'll do this with the
<cfheader> tag (note that if you use <cfflush> in the
application, this tag (and thus, this approach)
will not work.
<cfheader name="Content-disposition" value="attachment;
filename=somefile.doc" />
Almost there. Now we need to set the Content-type HTTP
header, to tell the browser what kind of data is coming, and then
give it the actual file data. We'll use the <cfcontent> tag
to do both of these things.
<cfcontent type="application/msword"
reset="yes">#wordDoc#</cfcontent><cfabort>
If memory serves, this should be all you need. Note the
<cfabort> after the closing <cfcontent> tag, I've had
problems in the past with additional output on the page after these
tags being appended to what gets sent to the browser, so I use a
<cfabort> afterwards to make sure nothing more gets sent
after the data we want. Also, at least with CFMX7, I've noticed
that debugging output tends to get added in too regardless, so I
typically put a <cfsetting showdebugoutput="false" /> at the
top of the file, too.
I can't guarantee this will work, I haven't tested this
particular situation, but if it doesn't, it ought to be close. Let
me know if I'm wrong.
Attached is what should be the code without my commentary /
rambling interspersed. -
Upload and display Word Document in WD application
Hello,
I have a WD ABAP appl. where the user wants to upload an Word / Excel file (from its own local drive).
The document shall be saved in SAP and it shall also be possible to display the document later in the WD application.
I implemented the UI element upload in the view, to determine the path of the document.
For the display implemented the UI element Office control.
1. When i browse the document, the properties data, filename and mime type are filled into the bound context elements of the upload UI.
2. The property datasource of the UI office control I bound to the same context element, that is also bound to the property data of the upload UI.
The office control opens a word document, but the document is empty.
Is it possible that the document is not uploaded correct?
In another application I did an upload for a PDF doc.. There I implemented the following coding as action of the button 'Upload'.
data lo_nd_pdf type ref to if_wd_context_node.
data lo_el_pdf type ref to if_wd_context_element.
data ls_pdf type wd_this->element_pdf.
data lv_pdf like ls_pdf-pdf.
navigate from <CONTEXT> to <PDF> via lead selection
lo_nd_pdf = wd_context->get_child_node( name = wd_this->wdctx_pdf ).
get element via lead selection
lo_el_pdf = lo_nd_pdf->get_element( ).
get single attribute
lo_el_pdf->get_attribute(
exporting
name = `PDF`
importing
value = lv_pdf ).
Get a reference to the from processing class.
data: l_fp type ref to if_fp.
l_fp = cl_fp=>get_reference( ).
Get a reference to the PDF Object class.
data: l_pdfobj type ref to if_fp_pdf_object.
l_pdfobj = l_fp->create_pdf_object( ).
set the pdf in the PDF Object
l_pdfobj->set_document( pdfdata = lv_pdf ).
set the PDF Object to extract data the Form data.
l_pdfobj->set_extractdata( ).
execute call to ADS
l_pdfobj->execute( ).
get the PDF Form data
data: pdf_form_data type xstring.
l_pdfobj->get_data(
importing
formdata = pdf_form_data ).
convert the xstring from data to string so it can be processed using the iXML classes
data: converter type ref to cl_abap_conv_in_ce,
formxml type string.
converter = cl_abap_conv_in_ce=>create( input = pdf_form_data ).
converter->read(
importing
data = formxml ).
pull in the iXML type group.
type-pools: ixml.
get a reference to iXML object
data:l_ixml type ref to if_ixml.
l_ixml = cl_ixml=>create( ).
get iStream object from StreamFactory
data: streamfactory type ref to if_ixml_stream_factory,
istream type ref to if_ixml_istream.
streamfactory = l_ixml->create_stream_factory( ).
istream = streamfactory->create_istream_string( formxml ).
create an XML document class that will be used to process the XML
data: document type ref to if_ixml_document.
document = l_ixml->create_document( ).
create the parser class
data: parser type ref to if_ixml_parser.
parser = l_ixml->create_parser( stream_factory = streamfactory
istream = istream
document = document ).
parse the XML
parser->parse( ).
define XML Node type object
data: node type ref to if_ixml_node,
attributes type ref to if_ixml_named_node_map.
get the psi sales data Node and value.
data ls_psi_sales type wd_this->element_psi_sales.
data: lt_dfies type table of dfies,
ls_defies type dfies.
call function 'DDIF_NAMETAB_GET'
exporting
tabname = 'ZCM_PSI_SALES'
ALL_TYPES = ' '
LFIELDNAME = ' '
GROUP_NAMES = ' '
UCLEN =
IMPORTING
X030L_WA =
DTELINFO_WA =
TTYPINFO_WA =
DDOBJTYPE =
DFIES_WA =
LINES_DESCR =
tables
X031L_TAB =
dfies_tab = lt_dfies
exceptions
not_found = 1
others = 2
if sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
data: lv_fieldname type string.
field-symbols <fs_field> type any.
loop at lt_dfies into ls_defies.
lv_fieldname = ls_defies-fieldname.
node = document->find_from_name( name = lv_fieldname ).
assign component lv_fieldname
of structure ls_psi_sales
to <fs_field>.
if <fs_field> is assigned.
<fs_field> = node->get_value( ).
endif.
endloop.
WRITE DATA INTO CONTEXT
data lo_nd_psi_sales type ref to if_wd_context_node.
data lo_el_psi_sales type ref to if_wd_context_element.
navigate from <CONTEXT> to <PSI_SALES> via lead selection
lo_nd_psi_sales = wd_context->get_child_node( name = wd_this->wdctx_psi_sales ).
get element via lead selection
lo_el_psi_sales = lo_nd_psi_sales->get_element( ).
set all declared attributes
lo_el_psi_sales->set_static_attributes(
exporting
static_attributes = ls_psi_sales ).
Do I need such a code also to upload a word doc?
Which interface / class exists for word documents? (for PDF upload there is the interface IF_FP)
How can I save a document in SAP? (as MIME Object? with which method?)
I hope someone can help me!?
BRYou can use the fileupload and filedownload uielements.
Check these links:
[File Upload|http://help.sap.com/saphelp_nw70ehp1/helpdata/en/b3/be7941601b1d09e10000000a155106/content.htm]
[File Download|http://help.sap.com/saphelp_nw70ehp1/helpdata/en/09/a5884121a41c09e10000000a155106/content.htm]
When you upload a file and save in SAP, are you saving it as xstring.
If yes follow these steps for filedownload.
Follow these steps for file download:
1 Create FileDownload uielement in your View
2.Create an Attribute of type xstring.
3.Bind this attribute to the data property of your Filedownload uielement.
4. during fileuplaod as you are saving the document in xstring format, fetch the same from your database table and pass the value to filedownload i.e set the attribute bound to data property of filedownload uielement with the xstring content. -
What do I need to do to display a MS Word, Excel or PDF document in browser
Hi, Right now I have photos loaded and displayed in my HTML document in the browser next to a report...
What do I need to do to display a MS Word, Excel or PDF document in a browser?
I use the following procedure to load the content to the region of my HTML .
This gives an EDIT link to the photo...
select
'[img src="#OWNER#.display_thumb?p_file_id=' || nvl(file_catalog_id,0) || '" /]' "File"
from "FILE_CATALOG"
where "FILE_CATALOG_ID" = :P9_FILE_CATALOG_ID
This is the procedure to load the content to the region of my HTML .
create or replace PROCEDURE "DISPLAY_THUMB" (p_photo_id in number)
as
l_mime varchar2(255);
l_length number;
l_file_name varchar2(2000);
lob_loc BLOB;
begin
select mime_type, thumbnail, photo_name, dbms_lob.getlength(thumbnail)
into l_mime, lob_loc, l_file_name, l_length
from photo_catalog where photo_catalog_id = p_photo_id;
-- Set up HTTP header
-- Use an NVL around the mime type and if it is a null, set it to
-- application/octect - which may launch a download window from windows
owa_util.mime_header(nvl(l_mime,'application/octet'), FALSE );
-- Set the size so the browser knows how much to download
htp.p('Content-length: ' || l_length);
-- The filename will be used by the browser if the users does a "Save as"
htp.p('Content-Disposition: filename="' || l_file_name || '"');
-- Close the headers
owa_util.http_header_close;
-- Download the BLOB
wpg_docload.download_file( Lob_loc );
end;These were supplied from Justin in Experts Exchange..
For PDF, see here:
http://www.adobe.com/support/techdocs/328233.html
http://www.adobe.com/support/techdocs/331025.html
For Word docs, see here:
http://www.shaunakelly.com/word/sharing/OpenDocInIE.html
Any other input... any AJAX? -
How to display word document as a HTML document in portal
Hi
I developed a portal application in that i am displaying word document using IFrames, from my application i am uploading word document and saving those document in KM
Requirement is that i need to provide an option to show this word document in html.
Thanks
Rudradev.Hi Glenn Mendonca
I thing it is possible
Even in SDN search results page, we have option called "HTML version" link
to see the search document in HTML
see the below url
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.highlightedcontent?documenturi=%2fforums%2fsdn_forums%2fthread%7b74687265616449443d39313633%7d.jspa
i hope passing doucment as a query parameter to com.sap.km.cm.highlightedcontent?DocumentUri=
might solve this
pls give your inputs
Thanks -
How to display a word document in KM as html format
Hi
I developed a portal application in that i am displaying word document using IFrames, from my application i am uploading word document and saving those document in KM
Requirement is that i need to provide an option called "HTML Version" to show this word document in html.
Thanks
Rudradev.Hi E. van der Palen ,
I did it using TREX API
Thanks & Regards
Rudra -
Display word documents in portal content
Hi,
I have some word documents, which i want to display directly in the portal page. To display the documents I have generated a URL for each document and put this URL into an URL iView.
But the problem now is, that it always opens a separate window for the word documents, although I have set the property "Open in portal content" in the iview and "Isolation Method - Embedded" in the portal page.
Does somebody know, which additional settings are needed, to show the documents embedded in the portal page?
Thanks in advance!
Regards,
LydiaHi Lydia,
The "Isolation Method - Embedded" will NOT help at all in your case, the "Open in the portal content area" means that
the iView itself will be opened in the portal content area, instead of a new windows.
In your case, I agree with Raghu that you should use KM Document iView instead of URL iview, so please consider:
1. createa separate KM document iViews for every DOC, make sure "Open in the portal content area" is set.
2. craete a workset and assign the KM Document iViews to this workset
3. assign this workset to a certain role and assign the role to your user.
4. login with this user and try to launch the iview, then the DOC file should be opened in the same browser window
Thanks and best regards,
Thunder
Edited by: Thunder Feng on Nov 19, 2010 2:07 AM
Maybe you are looking for
-
Hi, I can't seem to easily find this info. What is the actual HDMI standard used on a very late 2012 MacMini 6,2 with i7 and 4000 graphics? I understand it can support up to 1920x1200 ... What standard is that? ... And will an HDMI to Display Port c
-
Dear SAP GURUS We have develped a billing report - z reprt - but the std profit center report -( S_PL0_8600030) NOT matching with it in output? kindly advise me to check and see the logic on the z report so that we can confirm the reason for diff
-
I bought an old macbook pro 17 inch a1297 and later found that it did not have hard drive. So I installed a new blank hdd n installed mountain lion. Laptop works fine but with a boot problem. I always have to disconnect the battery connector from the
-
Only 0 NOS of material JPLTP2511230 available
Dear all while creating delivery, vl01n, system is giving error message like only 0 nos of material available despite material available please suggest the way
-
I install web start on workstation under administrator. Web start is working properly. When i log to same machine as user (on NT with Power user rights) the web start show the splash screen but doesnt start. Perhapse the user doesnt have enough right