gr33nhat Posted November 28, 2012 Share Posted November 28, 2012 Hey everybody,right now I'm trying to use the webservice functions from jasperserver (ce).but if I try to use this http string :http://localhost:8082/jasperserver/rest/login?j_username=jasperadmin&j_password=jasperadminI get this failure message:The XML page cannot be displayed Cannot view XML input using style sheet. Please correct the error and then click the Refresh button, or try again later. -------------------------------------------------------------------------------- XML document must have a top level element. Error processing resource 'http://localhost:8082/jasperserver/rest/login?j_user... and if I wanna usehttp://localhost:8082/jasperserver/rest_v2/reports/samples/AllAccounts/inputControls/I get this one. <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> - resource.not.found Resource URI:/samples/AllAccounts Type:com.jaspersoft.jasperserver.api.metadata.common.domain.InputControlsContainer not found - URI:/samples/AllAccounts Type:com.jaspersoft.jasperserver.api.metadata.common.domain.InputControlsContainer could anyone hel me, please?greetings benedikt Link to comment Share on other sites More sharing options...
Solution marianol Posted November 28, 2012 Solution Share Posted November 28, 2012 1) The fist one is not an error is just your browser telling you that it cannot display the XML response for the REST web service.2) the second one is also not an error is just the response from the web servie, you are actually asking for an Input Controls (IC) of a report that does not have any ICs , try requesting for the Employee Accounts report that one has ICs to show. Also if you ask for the report resource descriptor it will actually tell you if the report does indeed have ICsREST web services are ment to be use from another application which can handle the requests and act acordingly, there are really good browser plugins that help you doing this tests, try this one for Firefox or this one for Chrome. Link to comment Share on other sites More sharing options...
gr33nhat Posted November 29, 2012 Author Share Posted November 29, 2012 Thank u so much it works :-) Link to comment Share on other sites More sharing options...
oguz.turkan Posted January 7, 2014 Share Posted January 7, 2014 I'm using Jasperreport server 5.5.0 community edition. I'm sending thi data <resourceDescriptor name="Employees" wsType="reportUnit" uriString="/reports/Samples/Employees" isNew="false"><label>Employees</label><description>Employees Report</description><creationDate>1302268918000</creationDate><resourceproperty name="PROP_PARENT_FOLDER"><value>/reports/samples</value></resourceproperty><resourceproperty name="PROP_VERSION"><value>2</value></resourceproperty><resourceproperty name="PROP_RESOURCE_TYPE"><value>com.jaspersoft.jasperserver.api.metadata.jasperreports.domain.ReportUnit</value></resourceproperty><resourceproperty name="PROP_RU_ALWAYS_PROPMT_CONTROLS"><value>false</value></resourceproperty><resourceproperty name="PROP_RU_CONTROLS_LAYOUT"><value>0</value></resourceproperty></resourceDescriptor>[/code]to server with rest api. I'm gettin error Resource /reports/Samples/Employees of type com.jaspersoft.jasperserver.api.metadata.common.domain.InputControlsContainer not found.what can i docode : c#string requestAllResult = httpclient.UploadString("http://localhost.:8080/jasperserver/rest/report/reports/samples/Employees?RUN_OUTPUT_FORMAT=PDF", "PUT", requestXml.ToString()); Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now