How to display XML file as is it is in my browser using servlets???
I have a question like my servlet receives an XML file in its request object. I just need display the same XML file as it is in my browser. How to do that? Please help me out. I have searched so many blogs, but i did not get right solution.
My XML file file will be like this:
<ns0:Http_Message_Type_Demo xmlns:ns0="http://abcdemo.com">
<Name>A</Name>
<RollNo>123</RollNo>
<Address>a2</Address>
</ns0:Http_Message_Type_Demo>
Thnks
You mean you want to see the XML source?
You need to replace the characters '<' and '&' with corresponding entities '<' and '&'. You can use replaceAll, but do the ampersands first.
Then I suggest you probably want to put them in a <PRE> block.
Similar Messages
-
How to display XML file in java swing
hi all
now i do my M.Sc., project on data maining.this time i have one problem,thats i can't display XML file in swing frame.so any one know this plz give me that idea or code.
Thanks to all.
RSKOne way of doing that is to use JDOM...
u create an xml tree, and then output using XMLOutputter class...it will be displayed in text...im not sure if thats what u want...however, if u do want to represent it visually then u may need to draw a tree...u may use the Graphics2D for that...there are alot of ways to do such thing, and the 2 possibilities arent the best...depends on what u want...elaborate more pls. -
how to edit xml file particular value. and how to send xml file over ip address 192.168.2.10 device using ftp through Ethernet
Hello
For using FTP function in LabVIEW, I recommend you to check this document: FTP Basics
Also, take a look at FTP Browser.vi, which is available at the Example Finder.
To edit a XML file, try to use VIs in XML palette. Maybe Write to XML.vi helps you.
Post your current VI if possible.
Regards
Mondoni -
How to display XML file(as markup) in jsp page..?
Hi All,
* I have to display the XML file(as markup) in jsp page (Tree Format)....
* My XML file is an java.io.file object , and how to view this XML file on my JSP page...........
Thanks in Advance,
JavaImranYou mean you want to see the XML source?
You need to replace the characters '<' and '&' with corresponding entities '<' and '&'. You can use replaceAll, but do the ampersands first.
Then I suggest you probably want to put them in a <PRE> block. -
How to display XML file that XI sent to my j2ee appl?
Hi,
In my scenario File->XI->J2EE appl.
I got XML page cannot be displayed.
XML document must have a top level element. Error processing resource 'http://localhost:7001/Invoke/DisplayRes'.
I deployed my .ear file on BEA Weblogic application server9.0
I found no error when i tested in SXI_MONI and RWB->Message monitor as well.
This is my servlet code:
public class DisplayRes extends HttpServlet {
public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
doPost(request,response);
public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
BufferedReader brin =new BufferedReader(new InputStreamReader(request.getInputStream()));
String inputLine;
StringBuffer sBuf = new StringBuffer();
PrintWriter out = response.getWriter();
response.setContentType("text/xml");
while ((inputLine = brin.readLine()) != null)
sBuf.append(inputLine);
//out.setContentType("text/xml");
//out.println(sBuf.toString());
out.write(sBuf.toString());
brin.close();
out.flush();
What went wrong.All helpful answers are highly rewarded.
ThanksHi
Can anyone tell me how XI sends messages to applications like J2EE. In REceiver comm channel, I think we specify about the target system like J2EE appl.
Aadapter Type: HTTP
Receiver
Transport Protocol: HTTP1.0
Message Protocol: XI payload in HTTP body
Adapter Engine: Integration Server
Addressing Type: URL address
Target host: localhost
Service Number: 7001(Port number of Weblogic appl server--where my J2EE appl is deployed).
Path : /Invoke/DisplayRes/
Authentication Type:Use Logon Data for SAP System
Content Type: text/xml
Username: xiappluser
password: xx
XML code: UTF-8
I suppose XI sends msgs to http://localhost:7001/Invoke/DisplayRes/........
in this example if am correct?
Then I have given all tyhe necessary setting but my servlet is not able to display XML msg in browser?
This is my servlet code:
public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
PrintWriter out = response.getWriter();
BufferedReader brin =new BufferedReader(new InputStreamReader(request.getInputStream()));
String inputLine;
StringBuffer sBuf = new StringBuffer();
response.setContentType("text/xml");
while ((inputLine = brin.readLine()) != null)
sBuf.append(inputLine);
out.println("hi");
out.println(sBuf.toString());
brin.close();
out.flush();
What went wrong?
Help me, all helpful answers are highly rewarded.
Thanks -
How to display XML file in browser using Servlets?
Hi My XML file is like this:
<?xml version="1.0" encoding="UTF-8"?>
<ns0:purchase_order_MT xmlns:ns0="http://filetohttp.com">
<ORDER_HEADER_IN>
<purchase_date/>
<purchase_group/>
<purchase_org/>
</ORDER_HEADER_IN>
<vendor/>
<ORDER_ITEMS_IN>
<item>
<storage_location/>
<plant/>
<quantity/>
<material/>
</item>
</ORDER_ITEMS_IN>
<ORDER_SCHEDULES_IN>
<item>
<delivery_date/>
</item>
</ORDER_SCHEDULES_IN>
</ns0:purchase_order_MT>
My Servlet receives this XML file and it should display the above XML as it is, How to do that?
Please help me I have posted same question in many forums but i got no proper reply.
Thanks a lotIf you only need to display it, consider your HttpServletRequest just as byte stream. :) Just read from ServletInputStream and write it back into ServletOutputStream of HttpServletResponse.
If you want to process incoming XML, please give some details first, what exactly you want to do. :) -
How to Display XML in a UIWebView?
Hi everybody. I like how Safari displays XML files and I would like to emulate that functionality in an iPhone UIWebView. However, I just can't get it to look the same when passing a URL to the UIWebView.
For example, take a simple XML file like http://molottery.com/rss-num.xml. Viewing that in Safari looks okay, but passing that same URL into a UIWebView just shows a blank page.
I changed the web protocol from http to feed (feed://molottery.com/rss-num.xml) and it launches the page in Safari instead of my UIWebView. Looks good, but it quit my app... :- (
I noticed that XML files on the iPhone get re-routed through reader.mac.com so I tried appending that to my URL (http://reader.mac.com/mobile/v1/http://molottery.com/rss-num.xml) but that did not work either.
When I tried URLEncoding the string like Safari does (http://reader.mac.com/mobile/v1/http%3A%2F%2Fmolottery.com%2Frss-num.xml) I get a UIWebView saying that "This Application Is Viewable Only On iPhone".
So how can I emulate the regular Safari XML functionality inside my UIWebView? I will post my code upon request, if that will help. Any assistance from the Developer Community would be greatly appreciated.
Thanks!You may have better luck in the iPhone dev forums...
https://devforums.apple.com/community/iphone/web -
I'm running Safari 6.0.2. And previous to a recent update I was able to drag a XML file into the browser and it would display the contents. Now it does nothing. I'm guessing with the last update it removed an extension that used to allow this to happen. Can anyone suggest a good XML display extention they've had good luck with.
Thanks!The only browser I am aware of that currently knows how to
display XML is IE5. Otherwise, you will need to convert the XML
into well-formed HTML or xHTML through and XSLT stylesheet.
Oracle XML Team
http://technet.oracle.com
Oracle Technology Network
Ravinder Kamal (guest) wrote:
: I not able to display the XML file in my browser even after
using
: using an XSL Stylesheet. I am not using IE5 browser.
: The output of command :
: C\>java XSLSample iden.xsl empl.xml
: <root>
: <ROWSET>
: <ROW num="1">
: <EMP_ID>PMA42628M</EMP_ID>
: <FNAME>Paolo</FNAME>
: <MINIT>M</MINIT>
: <LNAME>Accorti</LNAME>
: <JOB_ID>13</JOB_ID>
: <JOB_LVL>35</JOB_LVL>
: <PUB_ID>0877</PUB_ID>
: <HIRE_DATE>1992-08-27 00:00:00.0</HIRE_DATE>
: </ROW>
: </root>
: where iden.xsl is :-
: <?xml version="1.0"?>
: <!-- Identity transformation -->
: <xsl:stylesheet
xmlns:xsl="http://www.w3.org/XSL/Transform/1.0">
: <xsl:template match="*|@*|comment()|pi()|text()">
: <xsl:copy>
: <xsl:apply-templates
: select="*|@*|comment()|pi()|text()"/>
: </xsl:copy>
: </xsl:template>
: </xsl:stylesheet>
: -R.S.Kamal
null -
How to Download XML File to internal table
Hi Friends,
This is my urgent requirement. How to download XML File to Internal table.
regards
pauldharmaHai,
Please check this Link
http://www.sap-img.com/abap/upload-direct-excel.htm
PARAMETERS: filename LIKE rlgrap-filename MEMORY ID M01,
begcol TYPE i DEFAULT 1 NO-DISPLAY,
begrow TYPE i DEFAULT 1 NO-DISPLAY,
endcol TYPE i DEFAULT 100 NO-DISPLAY,
endrow TYPE i DEFAULT 32000 NO-DISPLAY.
* Tick don't append header
PARAMETERS: kzheader AS CHECKBOX.
DATA: BEGIN OF intern OCCURS 0.
INCLUDE STRUCTURE alsmex_tabline.
DATA: END OF intern.
DATA: BEGIN OF intern1 OCCURS 0.
INCLUDE STRUCTURE alsmex_tabline.
DATA: END OF intern1.
DATA: BEGIN OF t_col OCCURS 0,
col LIKE alsmex_tabline-col,
size TYPE i.
DATA: END OF t_col.
DATA: zwlen TYPE i,
zwlines TYPE i.
DATA: BEGIN OF fieldnames OCCURS 3,
title(60),
table(6),
field(10),
kz(1),
END OF fieldnames.
* No of columns
DATA: BEGIN OF data_tab OCCURS 0,
value_0001(50),
value_0002(50),
value_0003(50),
value_0004(50),
value_0005(50),
value_0006(50),
value_0007(50),
value_0008(50),
value_0009(50),
value_0010(50),
value_0011(50),
value_0012(50),
value_0013(50),
value_0014(50),
value_0015(50),
value_0016(50),
value_0017(50),
value_0018(50),
value_0019(50),
value_0020(50),
value_0021(50),
value_0022(50),
value_0023(50),
value_0024(50),
value_0025(50),
value_0026(50),
value_0027(50),
value_0028(50),
value_0029(50),
value_0030(50),
value_0031(50),
value_0032(50),
value_0033(50),
value_0034(50),
value_0035(50),
value_0036(50),
value_0037(50),
value_0038(50),
value_0039(50),
value_0040(50),
value_0041(50),
value_0042(50),
value_0043(50),
value_0044(50),
value_0045(50),
value_0046(50),
value_0047(50),
value_0048(50),
value_0049(50),
value_0050(50),
value_0051(50),
value_0052(50),
value_0053(50),
value_0054(50),
value_0055(50),
value_0056(50),
value_0057(50),
value_0058(50),
value_0059(50),
value_0060(50),
value_0061(50),
value_0062(50),
value_0063(50),
value_0064(50),
value_0065(50),
value_0066(50),
value_0067(50),
value_0068(50),
value_0069(50),
value_0070(50),
value_0071(50),
value_0072(50),
value_0073(50),
value_0074(50),
value_0075(50),
value_0076(50),
value_0077(50),
value_0078(50),
value_0079(50),
value_0080(50),
value_0081(50),
value_0082(50),
value_0083(50),
value_0084(50),
value_0085(50),
value_0086(50),
value_0087(50),
value_0088(50),
value_0089(50),
value_0090(50),
value_0091(50),
value_0092(50),
value_0093(50),
value_0094(50),
value_0095(50),
value_0096(50),
value_0097(50),
value_0098(50),
value_0099(50),
value_0100(50).
DATA: END OF data_tab.
DATA: tind(4) TYPE n.
DATA: zwfeld(19).
FIELD-SYMBOLS: <fs1>.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR filename.
CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
EXPORTING
mask = '*.xls'
static = 'X'
CHANGING
file_name = filename.
START-OF-SELECTION.
CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
EXPORTING
filename = filename
i_begin_col = begcol
i_begin_row = begrow
i_end_col = endcol
i_end_row = endrow
TABLES
intern = intern
EXCEPTIONS
inconsistent_parameters = 1
upload_ole = 2
OTHERS = 3.
IF sy-subrc <> 0.
WRITE:/ 'Upload Error ', SY-SUBRC.
ENDIF.
END-OF-SELECTION.
LOOP AT intern.
intern1 = intern.
CLEAR intern1-row.
APPEND intern1.
ENDLOOP.
SORT intern1 BY col.
LOOP AT intern1.
AT NEW col.
t_col-col = intern1-col.
APPEND t_col.
ENDAT.
zwlen = strlen( intern1-value ).
READ TABLE t_col WITH KEY col = intern1-col.
IF sy-subrc EQ 0.
IF zwlen > t_col-size.
t_col-size = zwlen.
* Internal Table, Current Row Index
MODIFY t_col INDEX sy-tabix.
ENDIF.
ENDIF.
ENDLOOP.
DESCRIBE TABLE t_col LINES zwlines.
SORT intern BY row col.
IF kzheader = 'X'.
LOOP AT intern.
fieldnames-title = intern-value.
APPEND fieldnames.
AT END OF row.
EXIT.
ENDAT.
ENDLOOP.
ELSE.
DO zwlines TIMES.
WRITE sy-index TO fieldnames-title.
APPEND fieldnames.
ENDDO.
ENDIF.
SORT intern BY row col.
LOOP AT intern.
IF kzheader = 'X'
AND intern-row = 1.
CONTINUE.
ENDIF.
tind = intern-col.
CONCATENATE 'DATA_TAB-VALUE_' tind INTO zwfeld.
ASSIGN (zwfeld) TO <fs1>.
<fs1> = intern-value.
AT END OF row.
APPEND data_tab.
CLEAR data_tab.
ENDAT.
ENDLOOP.
CALL FUNCTION 'DISPLAY_BASIC_LIST'
EXPORTING
file_name = filename
TABLES
data_tab = data_tab
fieldname_tab = fieldnames.
*-- End of Program
http://sap.ittoolbox.com/groups/technical-functional/sap-dev/excel-file-download-to-an-internal-table-in-sap-crm-1719453#
tables: zinv_release,
zpo_release.
** decleration of data
DATA: BEGIN OF my_tab OCCURS 0.
INCLUDE STRUCTURE zinv_release.
DATA: END OF my_tab.
*DATA: hex_tab TYPE x VALUE '09'.
DATA: rec(200)."'/usr/test.dat'.
DATA:
zhours(20) TYPE c,
MINS(20) type c. "decimals.
data: coma.
coma = ','.
SELECTION-SCREEN BEGIN OF BLOCK txt
WITH FRAME TITLE text-001.
PARAMETERS: dsn(60) DEFAULT '\\sapdev01\prod\'.
SELECTION-SCREEN END
OF BLOCK txt.
*using a dataset to get text
OPEN DATASET dsn FOR INPUT IN TEXT MODE.
IF sy-subrc = 0.
DO.
READ DATASET dsn INTO rec.
IF sy-subrc <> 0.
EXIT.
ENDIF.
split rec at coma into
zpo_release-REL_GRP
zpo_release-REL_CODE
zpo_release-RESPREL
zpo_release-ALTREL
zpo_release-MANAGER
ZHOURS
MINS
zpo_release-FROMTIME
zpo_release-TOTIME
zpo_release-EXCLWKENDS.
move zpo_release-REL_GRP to my_tab-REL_GRP.
move zpo_release-REL_CODE to my_tab-REL_CODE.
move zpo_release-RESPREL to my_tab-RESPREL.
move zpo_release-ALTREL to my_tab-ALTREL.
move zpo_release-MANAGER to my_tab-MANAGER.
move ZHOURS to my_tab-ZHOURS.
move MINS to my_tab-mins.
move zpo_release-FROMTIME to my_tab-fromtime.
move zpo_release-TOTIME to my_tab-totime.
move zpo_release-EXCLWKENDS to my_tab-exclwkends.
APPEND my_tab.
ENDDO.
INSERT zpo_release FROM TABLE my_tab ACCEPTING DUPLICATE KEYS.
** DELETE zmm_ppa_cc FROM TABLE tab.
** INSERT zzzak_emp FROM TABLE my_tab ACCEPTING DUPLICATE KEYS.
IF sy-subrc = 0.
MESSAGE i000(zv) WITH 'File Successful stored in DB.' '' '' ''.
** ELSE.
MESSAGE i000(zv) WITH 'File already stored in DB.' '' '' ''.
endif.
ENDIF.
reward if helpful
raam -
How to download XML file to ITAB
hi friends
this is my urgent req. how to download XML file to Local itab
any other function or sample program available.
with luv.
pauldharmaHi,
please check this code.
Uploading Excel file to SAP Using Function Module ALSM_EXCEL_TO_INTERNAL_TABLE
REPORT ZEXCELUPLOAD.
PARAMETERS: filename LIKE rlgrap-filename MEMORY ID M01,
begcol TYPE i DEFAULT 1 NO-DISPLAY,
begrow TYPE i DEFAULT 1 NO-DISPLAY,
endcol TYPE i DEFAULT 100 NO-DISPLAY,
endrow TYPE i DEFAULT 32000 NO-DISPLAY.
* Tick don't append header
PARAMETERS: kzheader AS CHECKBOX.
DATA: BEGIN OF intern OCCURS 0.
INCLUDE STRUCTURE alsmex_tabline.
DATA: END OF intern.
DATA: BEGIN OF intern1 OCCURS 0.
INCLUDE STRUCTURE alsmex_tabline.
DATA: END OF intern1.
DATA: BEGIN OF t_col OCCURS 0,
col LIKE alsmex_tabline-col,
size TYPE i.
DATA: END OF t_col.
DATA: zwlen TYPE i,
zwlines TYPE i.
DATA: BEGIN OF fieldnames OCCURS 3,
title(60),
table(6),
field(10),
kz(1),
END OF fieldnames.
* No of columns
DATA: BEGIN OF data_tab OCCURS 0,
value_0001(50),
value_0002(50),
value_0003(50),
value_0004(50),
value_0005(50),
value_0006(50),
value_0007(50),
value_0008(50),
value_0009(50),
value_0010(50),
value_0011(50),
value_0012(50),
value_0013(50),
value_0014(50),
value_0015(50),
value_0016(50),
value_0017(50),
value_0018(50),
value_0019(50),
value_0020(50),
value_0021(50),
value_0022(50),
value_0023(50),
value_0024(50),
value_0025(50),
value_0026(50),
value_0027(50),
value_0028(50),
value_0029(50),
value_0030(50),
value_0031(50),
value_0032(50),
value_0033(50),
value_0034(50),
value_0035(50),
value_0036(50),
value_0037(50),
value_0038(50),
value_0039(50),
value_0040(50),
value_0041(50),
value_0042(50),
value_0043(50),
value_0044(50),
value_0045(50),
value_0046(50),
value_0047(50),
value_0048(50),
value_0049(50),
value_0050(50),
value_0051(50),
value_0052(50),
value_0053(50),
value_0054(50),
value_0055(50),
value_0056(50),
value_0057(50),
value_0058(50),
value_0059(50),
value_0060(50),
value_0061(50),
value_0062(50),
value_0063(50),
value_0064(50),
value_0065(50),
value_0066(50),
value_0067(50),
value_0068(50),
value_0069(50),
value_0070(50),
value_0071(50),
value_0072(50),
value_0073(50),
value_0074(50),
value_0075(50),
value_0076(50),
value_0077(50),
value_0078(50),
value_0079(50),
value_0080(50),
value_0081(50),
value_0082(50),
value_0083(50),
value_0084(50),
value_0085(50),
value_0086(50),
value_0087(50),
value_0088(50),
value_0089(50),
value_0090(50),
value_0091(50),
value_0092(50),
value_0093(50),
value_0094(50),
value_0095(50),
value_0096(50),
value_0097(50),
value_0098(50),
value_0099(50),
value_0100(50).
DATA: END OF data_tab.
DATA: tind(4) TYPE n.
DATA: zwfeld(19).
FIELD-SYMBOLS: <fs1>.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR filename.
CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
EXPORTING
mask = '*.xls'
static = 'X'
CHANGING
file_name = filename.
START-OF-SELECTION.
CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
EXPORTING
filename = filename
i_begin_col = begcol
i_begin_row = begrow
i_end_col = endcol
i_end_row = endrow
TABLES
intern = intern
EXCEPTIONS
inconsistent_parameters = 1
upload_ole = 2
OTHERS = 3.
IF sy-subrc <> 0.
WRITE:/ 'Upload Error ', SY-SUBRC.
ENDIF.
END-OF-SELECTION.
LOOP AT intern.
intern1 = intern.
CLEAR intern1-row.
APPEND intern1.
ENDLOOP.
SORT intern1 BY col.
LOOP AT intern1.
AT NEW col.
t_col-col = intern1-col.
APPEND t_col.
ENDAT.
zwlen = strlen( intern1-value ).
READ TABLE t_col WITH KEY col = intern1-col.
IF sy-subrc EQ 0.
IF zwlen > t_col-size.
t_col-size = zwlen.
* Internal Table, Current Row Index
MODIFY t_col INDEX sy-tabix.
ENDIF.
ENDIF.
ENDLOOP.
DESCRIBE TABLE t_col LINES zwlines.
SORT intern BY row col.
IF kzheader = 'X'.
LOOP AT intern.
fieldnames-title = intern-value.
APPEND fieldnames.
AT END OF row.
EXIT.
ENDAT.
ENDLOOP.
ELSE.
DO zwlines TIMES.
WRITE sy-index TO fieldnames-title.
APPEND fieldnames.
ENDDO.
ENDIF.
SORT intern BY row col.
LOOP AT intern.
IF kzheader = 'X'
AND intern-row = 1.
CONTINUE.
ENDIF.
tind = intern-col.
CONCATENATE 'DATA_TAB-VALUE_' tind INTO zwfeld.
ASSIGN (zwfeld) TO <fs1>.
<fs1> = intern-value.
AT END OF row.
APPEND data_tab.
CLEAR data_tab.
ENDAT.
ENDLOOP.
CALL FUNCTION 'DISPLAY_BASIC_LIST'
EXPORTING
file_name = filename
TABLES
data_tab = data_tab
fieldname_tab = fieldnames.
*-- End of Program
Uploading Excel file to SAP Using Function Module TEXT_CONVERT_XLS_TO_SAP
REPORT zupload_excel_to_itab.
TYPE-POOLS: truxs.
PARAMETERS: p_file TYPE rlgrap-filename.
TYPES: BEGIN OF t_datatab,
col1(30) TYPE c,
col2(30) TYPE c,
col3(30) TYPE c,
END OF t_datatab.
DATA: it_datatab type standard table of t_datatab,
wa_datatab type t_datatab.
DATA: it_raw TYPE truxs_t_text_data.
* At selection screen
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
CALL FUNCTION 'F4_FILENAME'
EXPORTING
field_name = 'P_FILE'
IMPORTING
file_name = p_file.
*START-OF-SELECTION.
START-OF-SELECTION.
CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'
EXPORTING
* I_FIELD_SEPERATOR =
i_line_header = 'X'
i_tab_raw_data = it_raw " WORK TABLE
i_filename = p_file
TABLES
i_tab_converted_data = it_datatab[] "ACTUAL DATA
EXCEPTIONS
conversion_failed = 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.
* END-OF-SELECTION.
END-OF-SELECTION.
LOOP AT it_datatab INTO wa_datatab.
WRITE:/ wa_datatab-col1,
wa_datatab-col2,
wa_datatab-col3.
ENDLOOP.
here are the links for further details
http://www.sapdevelopment.co.uk/file/file_upexcel.htm
http://www.sap-img.com/abap/upload-direct-excel.htm
reward if helpful
raam -
How to read XML file and update the data in MS CRM 2011?
Hi Folks,
Can anyone please help me finding some references to read XML files and push the data to MS CRM 2011 preferably by using a console application.
Please let me know if any ways of handling it in simple ways.
Thanks,
SriHI,
How to read XML file:
https://social.msdn.microsoft.com/Forums/en-US/5dd7261b-86c4-4ca8-ba87-95196ef3ba50/need-to-display-xml-file-in-textboxes-edit-the-data-and-save-the-new-xml-file?forum=csharpgeneral
How to work with CRM:
ClientCredentials credentials = new ClientCredentials();
credentials.Windows.ClientCredential = new System.Net.NetworkCredential("USER", "Password", "Domain");
Uri uri = new Uri("http://server/Organization/XRMServices/2011/Organization.svc");
OrganizationServiceProxy proxy = new OrganizationServiceProxy(uri, null, credentials, null);
proxy.ServiceConfiguration.CurrentServiceEndpoint.Behaviors.Add(new ProxyTypesBehavior());
IOrganizationService service = (IOrganizationService)proxy;
//using "service" you can create, update and retrieve entities.
More information here about service functions:
https://msdn.microsoft.com/en-us/library/gg328198.aspx -
How to display xml to html using xsl?
hi all...may i know how to display xml to html page?
i ve included <xsl:output method="html" indent="yes" /> inside my xsl file. i clicked on output.xml file and everything is displayed correctly but the format is xml instead of html. is there anyway to transform it to html?
below are my xsl and xml codes:
// xsl file
<?xml version='1.0'?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" indent="yes" />
<xsl:template match="/">
<html>
<body>
<h2>Document Contents</h2>
<table border="1">
<tr bgcolor="#9acd32">
<th align="center">Document Name</th>
<th align="center">Document ID</th>
<th align="center">Owner</th>
</tr>
<xsl:for-each select="Document/Contents">
<tr>
<td><xsl:value-of select="DocumentName"/></td>
<td><xsl:value-of select="DocumentID"/></td>
<td><xsl:value-of select="Originator"/></td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
// xml file
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="xsltStyleSheet.xsl"?>
<Document>
<Contents>
<DocumentName>register</DocumentName>
<DocumentID>1</DocumentID>
<Originator>hhh</Originator>
</Contents>
</Document>
</xsl:template></xsl:stylesheet>your XSL transforms to HTML (in fact XHTML): what more do you expect? did you expected anything different from the following output? if yes: what and why?
<html>
<body>
<h2>Document Contents</h2>
<table border="1">
<tr bgcolor="#9acd32">
<th align="center">Document Name</th>
<th align="center">Document ID</th>
<th align="center">Owner</th>
</tr>
<tr>
<td>register</td>
<td>1</td>
<td>hhh</td>
</tr>
</table>
</body>
</html> -
How to display XSL file to ASPX in dreamweaver
Hi,
Just wondering how to display XSL file in ASPX page?
I normally do it in ASP page by using server behaviour XSLT transformation and bind it to ASP page and this works very well.
Now I am trying to use the same method and using ASPX page this time but this time there is no option from server behaviour where I can bind it to my ASPX.
Can someone help or perhaps let me know where I can find the information how to do it?
Thanks,
Rush OYou mean you want to see the XML source?
You need to replace the characters '<' and '&' with corresponding entities '<' and '&'. You can use replaceAll, but do the ampersands first.
Then I suggest you probably want to put them in a <PRE> block. -
How to refresh XML file from my client machine
Hai All
I have temp.XML and temp.XSL template in our server machine.
when i give a print from client machine first time it gives the record,and next time it did not get refresh.Always it shows the previous records in the browser.But when i go into the server machine and click on temp.xml,it shows the current record(correct records)
How to refresh XML file from my client machine?
Regards
DhinaYou never delete a Time Machine backup by dragging it to the Trash. You are supposed to use the TM application to manage the backups. What you will need to do now is to simply erase the drive using Disk Utility.
-
How can i copy files from one external hard disk to another using macbook pro with retina display
How can i copy files from one external hard drive to another using macbook pro with retina display?
That's odd - if you open Disk Utility (Applications->Utilities) and select the disk(s), how are they formatted? If you're only going to be used with your Mac, they should be formatted as "Mac OS Extended (Journaled)".
Clinton
Maybe you are looking for
-
BAPI/Function module to release request.
Hi All, I want to release the request from my ABAP program. Can anybody suggest me Function Module or BAPI for that. I tried BDC for the same but release get canlled.
-
I am suddenly seing weird "symbol" or "dingbat" characters on web pages instead of letters, and this is happening on all browsers I try (firefox, safari, explorer). How do I fix this?
-
Error installing.. now getting an AppleMobileDeviceHelper has encoutered a
Error installing 1.1.2... now getting an AppleMobileDeviceHelper has encoutered a problem error every time I run itunes with the iphone plugged in. I reinstalled itunes... no help.. PLEASE HELP!
-
Cursor freezes completely each time with mac os x 10.6.8
Hello, mac friends, I have a Macbook Pro with 8Gb and upgraded from 10.6.3 to 10.6.8 recently. All was well for some but since one week, the cursor freezes when I use either Safari or Mozilla, and and basically the whole system jams. I cannot do forc
-
How to upgrade 6.0SP1 to 6.0SP2
I already have 6.0SP1 installed and configured. I now want to upgrade to SP2. But from the website only download that is available is for 6.0 including SP2. There is nothing available to upgrade from SP1 to SP2. How to do that? in the worst case, can