How to open word document form html container url iam getting internal_error while opening file
Hi all,
By using below code i am able to download word document file from html container. But before downloading i need edit these document to add Macro.
I am unable to open word document.
CREATE OBJECT G_HTML_CONTAINER
EXPORTING
CONTAINER_NAME = 'PDF'.
CREATE OBJECT G_HTML_CONTROL
EXPORTING
PARENT = G_HTML_CONTAINER.
* Convert xstring to binary table to pass to the LOAD_DATA method
CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
EXPORTING
BUFFER = LV_CONTENT
TABLES
BINARY_TAB = LT_DATA.
data_tab = LT_DATA ).
* Load the HTML
CALL METHOD G_HTML_CONTROL->LOAD_DATA(
EXPORTING
TYPE = 'application'
SUBTYPE = 'DOC'
IMPORTING
ASSIGNED_URL = LV_URL
CHANGING
DATA_TABLE = LT_DATA
EXCEPTIONS
DP_INVALID_PARAMETER = 1
DP_ERROR_GENERAL = 2
CNTL_ERROR = 3
OTHERS = 4 ).
* Show it
CALL METHOD G_HTML_CONTROL->SHOW_URL( URL = LV_URL
IN_PLACE = 'X' ).
Before file download i want edit the file for that i am using below class.
PROXY TYPE REF TO I_OI_DOCUMENT_PROXY.
by using (get_document_proxy) method getting proxy .
call method control->get_document_proxy
exporting
document_format = 'x'
document_type = 'Word.Document'
register_container = 'x'
importing
document_proxy = proxy
after these.
call method proxy->open_document
exporting
document_url = lv_url
open_inplace = 'x'
hear i m getting retcode as INTERNAL ERROR
can any one suggest me how to open document from html container.
Thanks and reagards
jogu yadav
I got resolution
Thanks and regards,
Jogu yadav
Similar Messages
-
How to convert word documents to html page in sharepoint online 2013
Hi,
I am new SharePoint and still learning it.
I have been tasked to do the following on office 365 E3 SharePoint 2013 Online edition.
1) I have to create a Web page in asp.net
2) This page needs to show document from a given SharePoint folder and bind them in a grid or dropdown on the asp .net web page
3) On selecting the document from the drop down or gird (on asp .net webpage), I need to show the SharePoint word document as HTML on the webpage (something like word to html) Note: These SharePoint word document may contain Images, bullets, tables etc.
What I have been able to do till now
1) I have been able to connect to SharePoint from ASP .net application.
2) I have been able to retrieve document from a specific SharePoint folder.
3) Read the document from SharePoint folder and bind them to a drop down on the asp .net page.
What is missing?
I am not aware about any API that SharePoint Online provides to convert Word document to HTML. Any code sample or reference on how to will be much appreciated.
I am not also not sure what is the best way of achieving the functionality this?
Thanks
KrishnaIf this was SharePoint server then it would be easy however in O365 You need to create a app which will use the word automation service and below is powershell which you can use for the conversion:-
# This script will convert Docx to PDF using word automation and similarly it can be used to convert to HTML
$wordFile="http://contoso/kick.docx"
$pdfFile="http://contoso/kick.pdf"
$wasp = Get-SPServiceApplicationProxy | where { $_.TypeName -eq "Word Automation Services Proxy" }
$site = Get-SPSite "http://contoso"
$ConvertJob = New-Object Microsoft.Office.Word.Server.Conversions.SyncConverter($wasp)
$ConvertJob.UserToken = $site.UserToken
$ConvertJob.Settings.UpdateFields = $false
$ConvertJob.Settings.OutputFormat = "PDF"
$ConvertJob.Convert($wordFile, $pdfFile) -
Cannot open Word document files in a Portfolio
I have set up a portfolio with multiple file types. I can open Excel and Power Point files within the portfolio without a problem. When I try to open Word documents it tells me that "Acrobat cannot open this file attachment because your pdf file attachment settings do not allow for this file type to be opened. I went into preferances and checked to see if the box was checked in "trust manager" to allow files other than pdf to opened. It is checked but I am still unable to open word documents in the portfolio for some reason.
Acrobat cannot open Word files. Have you tried opening the files from within Word? If so, most probably you have a file association problem.
-
Open word document in forms version 6
Does anyone have a code snippet to open an existing word document through forms. I have a user document which I would like to open from my forms menu.
hello,
Try use HOST command to open Words and your document. It works fine for me on Excel.
sample :
declare
Path varchar2(100);
file varchar2(50);
begin
path:='c:\program files\microsoft office\office\excel.exe ';
file := 'o:\ssd\tools\albook.xls';
path:= path | | file;
host(path);
END;
null -
How to open word document directly using ole2 and ole containers
Hello
i am using ole conatiners....in forms 6i. i want o open word document directly when i click a button....
i have tried host....ole but word opens .....i want the document to open at once.....
what should i use /set
plz tell by host command and ole2 as well
its urgent.....
thanksTry this code, Hope this will work.
declare
item_name varchar2(80) := 'letter';
item_id item;
verb_index_str VARCHAR(20);
verb_index PLS_INTEGER;
verb_cnt_str VARCHAR(20);
verb_cnt NUMBER;
verb_name VARCHAR(20);
loop_cntr NUMBER;
begin
item_id := Find_Item(item_name);
IF Id_Null(item_id)THEN
message('No such item: '||item_name);
ELSE
verb_cnt_str := Forms_OLE.Get_Verb_Count(item_id);
verb_cnt := TO_NUMBER(verb_cnt_str);
FOR loop_cntr in 1..verb_cnt LOOP
verb_name := Forms_OLE.Get_Verb_Name(item_id,loop_cntr);
-- message(verb_name);
-- message(loop_cntr|| ' '||verb_name);
IF verb_name = 'Open' or Verb_name = '?E?'THEN
EXEC_VERB(item_id,verb_name);
END IF;
end loop;
end if;
EXCEPTION
WHEN OTHERS THEN
MESSAGE('Error: '||TO_CHAR(SQLCODE)||' '||SQLERRM);
RAISE FORM_TRIGGER_FAILURE;
end; -
How to open word document in labview
Hi,
I want to open word document in labview,well i have done that.
I want to display only the page part,don't want any editions,formatting to be done.
please suggest me solution if any.How are you displaying your Word document, have you achieved that already?
As far as I know, there is only one way to display Word documents and that's through the browser ActiveX interface:
Using the Microsoft Web Browser control to embed a Word Document in LabVIEW
Thoric (CLA, CLED, CTD and LabVIEW Champion) -
How to restrict Firefox to open word document in browser window with href
How to restrict firefox to open word document from a website link to open in the browser window, instead it should open in native program.
1.I have tried other website, and have clicked on similar links they are opening word document correctly in native program
2. MS word document from one specific site is opening in browser causing junk character in place of word document.
Could you please help on this.Thanks for your response...
But As i said, I have tried with other website on the same browser, there it is opening word document in native program. Also the above mentioned options have been tried earlier.
I have some questions related to this?
How is this href link is behaving differently opening in browser for mozilla only. Technically, Can we make it open it native program only? If so, then how? -
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 OPEN WORD DOCUMENT FROM JAVA???
hi everyone! Can you please help me to come with this problem? Let me to set my main target I want to achieve:
1) In my program user should first press a button;
2) Then already created Word Document should be opened (I DO NOT NEED to open that Word Document in Java or something like JField). Just simply it should be opened as a Microsoft Word Document.
I DO NEED YOUR HELP! PLEASE HELP ME....!Running cmd using the exec is also a windows only solution, there is no "more" or "less" it that solution compared to the rundll.
Since word is a windows format its pretty obvious that the application is ran under windows platform.
If you are running on a different platform (maybe using open office you can open word documents, i'm not sure) you might want to use the JDIC library (https://jdic.dev.java.net/) which enables you to open/edit/browse such files using the default viewer/editor/browser of the system you are working on.
Look at the org.jdesktop.jdic.desktop.Desktop object for these methods.
You can also find the Desktop object in J2SE6 but its still in beta. -
I have a jsp file and i open a new page(word document) with a link in this jsp page. Text messages are viewed correctly in WS-Word but there is a problem for images...
1 _ How can i solve this problem?
2 _ After opening word document, if opened word document is saved to anywhere of computer, how can i know address location of it in jsp?
First File (a part of code):
<a style="cursor: hand;"
onClick="window.open('.../word.jsp','','height=400,width=600,scrollbars=yes,resizable=yes')">
test link14 - open word file
</a>
Second File : (word.jsp) All of the code...
<%@ page contentType="text/html;charset=windows-1254"%>
<%
response.setContentType("application/msword");
response.setHeader("Content-disposition","attachment;filename=firat_WordDoc.doc");
%>
<%@ page language = "java" %>
<html>
<head></head>
<body>
<img src="car.jpg" width="100" height="100" border="0" alt="car"/>
<br>
test text...
</body>
</html>
In second jsp file (word.jsp), "test text..." are written coorectly to word document named firat_WordDoc.doc but car.jpg is not viewedYou wont be able to see it as becoz all you are doing is asking teh browser to paint a JSP [HTML] Page and asking it to open in the format msword.
Save the word document and open it in textpad or notepad, you will see that the HTML is embedded within the Word Document rather than binary data. And you can see that the Image will aso be a IMG tag with refeence to the car.jpg.
In order for you to do this either consider
1. Using full URL in the Image tag.
2. Using COM Bridge [JIntegra] License Software to build a new Word Document at runtime and then paint it.
3. I think POI is free ware to do this. -
My mac is becoming too slow. It takes long to open word documents, pdf files or excel documents or even safari. Can anybody suggest something? I have tried to reduce the number of open applications, but does not seem to work.
Hi ...
Checked to see how much free space there is on the startup disk lately?
Right or control click the MacintoshHD icon. Click Get Info. In the Get Info window you will see Capacity and Available. Make sure there's a minimum of 15% free disk space.
Freeing Up Hard Disk Space - Mac GuidesFreeing Up Hard Disk Space - Mac Guides
If disk space is not the issue, booting in Safe Mode deletes system caches that may help.
A Safe Mode boot takes longer then a normal boot so be patient.
Once you see the Desktop, click the Apple menu icon top left corner of the screen.
From the drop down menu click Restart.
See if that makes a difference ... -
Opening Word documents with Appleworks
I often receive Word documents as email attachments (though my hotmail account). I can download these Word documents to my desktop but when I click on them to open them I get an offer to purchase MS Word (which I do not have). I would like to be able to simply open the Word documents with Apple works--and I am hoping I can just click on them and have that happen automatically. But it doesn't. I have tried opening Appleworks and going into the wordprocessing program and then opening the Word document through that, but it only is successful part of the time. What can I do? I would like to have these Word douments open automatically in Appleworks but every time I click on them (i.e., their icon on my desktop) I get that advertisement from Microsoft asking me to buy Word. Is this ad blocking a normal function of Appleworks that would otherwise allow me to open Word documents with a click? And in any case, how can I proceed?
The ad for Word is almost certainly being tacked on through or at Hotmail (taglines or adware from Hotmail? Hoodathunk .....) ; it sure isn't coming from AppleWorks or from anything on your own system, unless you have that demo copy of Office still lurking somewhere. I suppose it could come from that, somehow.
Assuming you can get a clean attachment downloaded to your Desktop from Hotmail, the procedure for having what you want to happen automatically is fairly straightforward and, really, has nothing at all to do with Appleworks. Try the following:
--> Select (highlight) one of those downloaded .doc files from Word, then
--> use the Finder's Get Info command (⌘-I). In the window which appears,
--> see the "Open with" section, and set it to AppleWorks. -
Saving MS Word document in HTML and importing
The Word doc is over 4MB with linked TOC, text, and text
boxes filled with text from mainframe applications. The text boxes
are difficult to control - non-symetrical and, in some instances,
overlapping. The text boxes are Fireworks gifs housed in a separate
folder (Assets, if you will) and there's about 390 of these gifs.
Would it be better to replace the Word text boxes with
Fireworks gifs? The problem I encountered with that is, on the Word
document in the web site, the gifs are not as clear as the text
boxes-kind of fuzzy.
Is there a better way to place such a large document into the
site rather than using MS Word and saving it as HTML?
I appreciate any helpful suggestions on better control of the
gifs and the Word document or any other suggestions?
InlitenYou can kill off all history and save a "final" copy in Word.
That is
recommended practice before you publish to the web anyway.
Though given the
description of the Word doc in question I'd second Darrel's
suggestion to
use a PDF.
Cheryl D Wise
"Malcolm N_" <[email protected]> wrote in message
news:[email protected]..
> On Mon, 31 Dec 2007 21:27:36 +0000 (UTC), "inliten"
> <[email protected]> wrote:
>
>>The Word doc is over 4MB with linked TOC, text, and
text boxes filled with
>>text
>>from mainframe applications. The text boxes are
difficult to control -
>>non-symetrical and, in some instances, overlapping.
The text boxes are
>>Fireworks gifs housed in a separate folder (Assets,
if you will) and
>>there's
>>about 390 of these gifs.
>> Would it be better to replace the Word text boxes
with Fireworks gifs?
>> The
>>problem I encountered with that is, on the Word
document in the web site,
>>the
>>gifs are not as clear as the text boxes-kind of
fuzzy.
>> Is there a better way to place such a large document
into the site rather
>> than
>>using MS Word and saving it as HTML?
>> I appreciate any helpful suggestions on better
control of the gifs and
>> the
>>Word document or any other suggestions?
>>
>> Inliten
>>
>>
>
> AS Darrel said - use PDF. There are a lot of utilities
that can
> produce a pdf from a Word document.
>
> But my favoured appoach is to first import the Word
document into
> OpenOffice
http://www.openoffice.org/ -
the free Open source
> programme.
>
> This often reduced the "Word" document to a
significantly smaller size
> - as it does not ( like Word does ) save edits,
deletions etc .
>
> Then OpenOffice has a built in pdf generator.
>
> HTH
> Malcolm
> --
>
> ~Malcolm N....
> ~ -
I was told when I purchased iWork last week that I would be able to open word documents that were sent to me via email. How can I do that?
maralyala,
Note that Dennis' solution will result in ALL Word files opening in Pages, as he says.
If you only want to open the occasional Word files in Pages, right-click or command-click on the file and choose "Open With" from the contextual menu that pops up next to the document. Select Pages.app from the list. If Pages.app is not on the list, click on 'Other' and scroll to Pages.app in your Applications folder.
You can do this on the icon of the Word file that appears in your email or after saving the Word file to your Mac.
Good luck,
Terry -
How to upload word documents in iphone?
Hello, I need to give a talk and I dont have printer... I should use the iphone, but I dont know how to read Word documents in the iphone... Someone can help me?
Apple has a paid app called Pages. I have never used it but I guess it will open Word documents and might even allow you to store them on your phone maybe in ibooks or somewhere
Maybe you are looking for
-
Click on an Image to see the .flv in popup.
Hi, I have done 90% of this project. All I want now is to swap image with .flv. In the project I have 9 pictures. When I click on either of them, the big picture opens in the pop up window and closes up when I click on it. What I want it to click on
-
Cursor changes to X shape at certain sizes
I currently am running Photoshop CS6 on Windows 7. When I am using the Brush or Pencil tools, sometimes the Cursor will change to a curved X shape. This appears to happen at certain sizes (between 65px to250px) and then goes back to the normal circle
-
GRC-AC 5.3sp14, ERM, Role Generation
We updated our GRC-AC 5.3 from sp12 to sp14 and now we cannot generate roles anymore. When we try to do it, we get the following error: "Failure : Field AGR_1252 not a member of TABLES". Does any one know how can we solve it? The backends were also u
-
Since i upgraded to ios 6, I am having trouble stayong connected to wifi networks I connected to on my iPhone 4S .. anyone else have this issue ?
-
Imessage can not delivered after i success to setting up
after i success to setup the Imessage from the general]setting , i try to send imessage ,msg appers in red "NOT DELIVERED" even it is seems all setting is ok. please i need help.