How to execute a URL ?
Dear All,
I would like to execute a URL, that should happen only in the back end.
Please help me for the possible work arounds.
Thanks in advance,
Balaji
I will be passing parameters through an html or jsp page. The html/jsp will points to a different application and will do its own operation on a different server.
All i need to do is, i have to pass parameters through an html.
Essentially, i have to make a call / invoke an URL from the database.
Thanks
Balaji
Similar Messages
-
How to execute a url throu java iwthout using any browser?
hi all
i want execute one url in my application
is it possible to execute a url with out using any browser and jeditor pane
pls help i need this help ...
micehaljalls
[email protected]above coding error
it shows Exception in thread "main" javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unknown Source)
at URLConnectionReader.main(URLConnectionReader.java:17)
Caused by: java.io.EOFException: SSL peer shut down incorrectly
at com.sun.net.ssl.internal.ssl.InputRecord.read(Unknown Source)
... 9 more -
How to execute a url using a Link
Hai,
I am working on some code and got struck up with the following issue.
There is an input field which allows the user to enter any URL,and by default this filed is populated with a default url,
below this input field there is a link, when the user clicks on this link,
the URl that is entered by the user should get executed, and i am using PageProcessor component for this.
code Sample :
InputField input = new InputField("applicationURL/Path");
form.addComponent(input);
String TestUrl=input.getString().getValueAsString();
Link testApplicationLink = new Link("testApplicationLink");
testApplicationLink.setReference(TestUrl);
form.addComponent(testApplicationLink);
Thanks in advance
regards
jagdeshHi jagdesh,
Are you using Web Dynpro or Portal components? For portal related questions use Enterprise Portal forum section /community [original link is broken]
Best regards, Maksim Rashchynski. -
How to execute link without showing it on browser
Hi,
In my site iam implementing sms functionality through 3rd party tool.
In that, they gave me an url which will send the sms through their website.
For that, i have to execute the url.
Is it possible to execute the url without showing on the browser.
please suggest how to do that.
Thanks in advance.
Mohan
Edited by: mohanPaladi on Mar 18, 2008 11:03 AMFrom your description, it appears you want to do an AJAX call where a request is sent to a url without updating the browser window. There are many libraries that make it simple to do this type of thing. http://ajaxian.com/ is a good place to start to look at AJAX if you are unfamiliar with it. Some popular libraries include dojo and jmaki.
-
Error while executing Form URL
Dear Experts,
Install and configure weblogic server 10.3.3.4.0 and then Oracle Portal, Forms, Report, Discoverer are successfully.
But I have problem when executing Form URL such as HTTP://localhost:8090/forms/frmservlet.
Failure of server APACHE bridge:
No backend server available for connection: timed out after 10 seconds or idempotent set to OFF.
Build date/time: Oct 27 2009 13:34:24
Change Number: 1013
Would you give me some advices how to solve this error.
Greetings,
-RanubayaURL such as HTTP://localhost:8090/forms/frmservlet
Is the port 8090? WebLogic server default HTTP port is 7001 -
How do you harness URL external application in a JSP?
I have successfully deployed the Yahoo Finance sample URL External Application. However, I do not understand how to utilize the URL classes (in the pdkjava.jar) to harness the external application information once a user has authenticated. I am building a JSP portlet that displays and applet, however the applet requires a username and password. I need to get the Username and Password from external application, which it gets from the user via External Application. How do I get these values in my JSP (that is defined in my provider.xml)? I keep seeing documentation regarding the ExternalPrincipal object however I don't understand how to utilize this object in my JSP. I beleive the ExternalPrincipal object is what I need in my JSP, seeing that it has the methods for getting the user and password. Unless is there a better way of achieving this, can anyone shed some light on getting the ExternalPrincipal object for an External Application session?
Thanks,
Laith E.H.Thanks for the example. I have a better understanding now, however I'm still having trying to comprehend the flow of executing in this portal model.
I have a problem with:
PortletRenderRequest pr = (PortletRenderRequest) request.getAttribute("oracle.portal.PortletRenderRequest");
ProviderUser prUser = pr.getUser();
ProviderSession pSession = prUser.getSession(true);
I get a NullPointerException on the second line when trying to getUser(). I'm not sure where the problem could be. In the provider.xml, my ExternalProviderInstance, or the JSP itself? I have another JSP portlet on the same page that calls the same method with success.
Thanks,
Laith E.H.
provider.xml:
<?xml version="1.0" encoding="UTF-8"?>
<?providerDefinition version="3.1"?>
<provider class="oracle.portal.provider.v2.http.URLProviderDefinition">
<providerInstanceClass>com.cox.portal.provider.ExternalProviderInstance</providerInstanceClass>
<session>true</session>
<authentication class="oracle.portal.provider.v2.security.Authentication">
<authType>ExternalApp</authType>
<userFieldName>Username</userFieldName>
<userPwdName>Password</userPwdName>
<errorPageMessages>Invalid ID,Invalid Password</errorPageMessages>
</authentication>
<portlet class="oracle.portal.provider.v2.http.URLPortletDefinition">
<id>1</id>
<name>ExternalAnalyzer</name>
<title>Main Analyzer</title>
<description>This portlet logs into analyzer</description>
<timeout>100</timeout>
<timeoutMessage>analyzer timed out</timeoutMessage>
<showEdit>false</showEdit>
<showEditDefault>false</showEditDefault>
<showPreview>false</showPreview>
<showDetails>false</showDetails>
<hasHelp>false</hasHelp>
<hasAbout>false</hasAbout>
<acceptContentType>text/html</acceptContentType>
<registrationPortlet>false</registrationPortlet>
<accessControl>registered</accessControl>
<renderer class="oracle.portal.provider.v2.render.RenderManager">
<showPage class="oracle.portal.provider.v2.render.http.URLRenderer">
<pageUrl>http://catl0dv31.corp.cox.com/bic/analyzerIFrame.jsp?ap_doc=analyzer&ap_id=105</pageUrl>
<contentType>text/html</contentType>
</showPage>
</renderer>
<securityManager class="oracle.portal.provider.v2.security.URLSecurityManager">
<authorizType>registered</authorizType>
</securityManager>
</portlet>
</provider>
ExternalProviderInstance:
package com.cox.portal.provider;
import oracle.portal.provider.v2.*;
import oracle.portal.provider.v2.http.*;
import oracle.portal.provider.v2.externalApp.*;
public class ExternalProviderInstance extends URLProviderInstance
public static final String EXTERNAL_APP = "externalapp.object.key";
ProviderSession pSession = null;
public Object[] initSession(ProviderUser user, ExternalPrincipal externalApp)
throws ProviderException {
//UrlServicesUtils.logMessage("BasicURLProvider : Entering initSession.", getDebugLevel());
//Create/Retrieve provider user session.
if (mProviderDefinition.getHasSession()) {
// Create the session if it doesn't already exist.
pSession = user.getSession(true);
// Store external app in provider session so that other modules
// can extract it later.
if (pSession != null) {
pSession.setAttribute(EXTERNAL_APP, externalApp);
// Get javax.servlet.http.Cookie[] from user
javax.servlet.http.Cookie[] cookies = ((ServletProviderUser)user).getCookies();
if(cookies != null)
return cookies;
else
return null; -
How to execute CGI Programs in Tomcat Server
Hi,
I am working on executing Perl Scrtipts(or CGI programs) in Tomcat Server.
I have downloaded ActivePerl 5.8.0 6.0.3 build.I have modified some .jar files in tomcat\server\lib.
I have changed conf\web.xml to access the CGIServlet.class that is in servlets-cgi.jar.
My example.cgi is
#!c:\Perl\bin\perl.exe
print
"Content-type: text/plain\n\n";
foreach $var (
sort keys %ENV) {
print
"$var=\"$ENV{$var}\"\n";
@values = split(
/&/,$ENV{'QUERY_STRING'});
foreach $i (@values) {
($varname, $mydata) = split(
/=/,$i);
print "$varname = $mydata\n";
and my test.html is
<HTML>
<HEAD>
<TITLE>Environment Variables using GET</TITLE>
</HEAD>
<BODY>
<FORM ACTION="cgi-bin/example.cgi" METHOD="POST">
Press submit for a list of environment variables. <BR>
First Name: <input type="text" name="fname" size=30><p>
Last Name: <input type="text" name="lname" size=30><p>
<input type="submit">
</FORM>
</BODY>
</HTML>
here I have changed url mapping in web.xml to cgi-bin.
The test.html produces two text fields first and last name on submit:
it accesses:http://localhost:8080/smalltownpapers/cgi-bin/example.cgi?fname=Tim&lname=Eden
this should print some environmental variables but it is producing an empty page.
Tomcat is not showing any errors or Tomcat is not at all listening.
Can any one help me to solve this and how to execute Perl scripts in Tomcat server
Thanks,
Regards
MurthySorry, I've never done this. I went to the Tomcat site and pulled down the CGI docs, which you might have seen:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/cgi-howto.html
No other help available from me. Sorry. -
How to execute a servlet on jakarta-tomcat-4.0.3
Please let me know how to execute a servlet on jakarta-tomcat-4.0.3 .I am able to compile it .
Regards,
Saurabh SinghalHi
You must provide a mapping in your web.xml configuration file. This mapping will allow you to access servlet via url in form: "http://[domain]:[port]/[context]/servlet/[servlet full qualified name]"
This file should be located at $TOMCAT_HOME/conf.
Sample web.xml contains:
<web-app>
<display-name>Sample Database App</display-name>
<description>
This is a simple application.
</description>
<servlet>
<servlet-name>MyServlet</servlet-name>
<servlet-class>MyServletImpl</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>MyServlet</servlet-name>
<url-pattern>/myservletaddr</url-pattern>
</servlet-mapping>
</web-app>
You can find more info at:
http://scitec.uwichill.edu.bb/cmp/online/CS36L/tutorials/TomcatIntroduction/TomcatIntroSampleApp.html
or
http://www.moreservlets.com/Using-Tomcat-4.html -
Please help how to execute jfree......
please help how to execute[b] jfree programs
step by step procedure.....
package org.jfree.chart.demo;
import org.jfree.chart.ChartFactory;
import org.jfree.chart.ChartPanel;
import org.jfree.chart.JFreeChart;
import org.jfree.chart.axis.CategoryAxis;
import org.jfree.chart.axis.CategoryLabelPosition;
import org.jfree.chart.axis.CategoryLabelPositions;
import org.jfree.chart.axis.CategoryLabelWidthType;
import org.jfree.chart.plot.CategoryPlot;
import org.jfree.chart.plot.PlotOrientation;
import org.jfree.data.category.CategoryDataset;
import org.jfree.data.category.DefaultCategoryDataset;
import org.jfree.text.TextBlockAnchor;
import org.jfree.ui.ApplicationFrame;
import org.jfree.ui.RectangleAnchor;
import org.jfree.ui.RefineryUtilities;
import org.jfree.ui.TextAnchor;
import org.jfree.util.Log;
import org.jfree.util.PrintStreamLogTarget;
* A simple demonstration application showing how to create a horizontal 3D bar chart using data
* from a {@link CategoryDataset}.
public class BarChart3DDemo2 extends ApplicationFrame {
// * JFREECHART DEVELOPER GUIDE *
// * The JFreeChart Developer Guide, written by David Gilbert, is available *
// * to purchase from Object Refinery Limited: *
// * http://www.object-refinery.com/jfreechart/guide.html *
// * Sales are used to provide funding for the JFreeChart project - please *
// * support us so that we can continue developing free software. *
* Creates a new demo.
* @param title the frame title.
public BarChart3DDemo2(final String title) {
super(title);
// create the chart...
final DefaultCategoryDataset dataset = new DefaultCategoryDataset();
dataset.addValue(23.0, "Series 1", "London");
dataset.addValue(14.0, "Series 1", "New York");
dataset.addValue(14.0, "Series 1", "Istanbul");
dataset.addValue(14.0, "Series 1", "Cairo");
dataset.addValue(13.0, "Series 2", "London");
dataset.addValue(19.0, "Series 2", "New York");
dataset.addValue(19.0, "Series 2", "Istanbul");
dataset.addValue(19.0, "Series 2", "Cairo");
dataset.addValue(7.0, "Series 3", "London");
dataset.addValue(9.0, "Series 3", "New York");
dataset.addValue(9.0, "Series 3", "Istanbul");
dataset.addValue(9.0, "Series 3", "Cairo");
final JFreeChart chart = createChart(dataset);
// add the chart to a panel...
final ChartPanel chartPanel = new ChartPanel(chart);
chartPanel.setPreferredSize(new java.awt.Dimension(500, 270));
setContentPane(chartPanel);
* Creates a chart.
* @param dataset the dataset.
* @return The chart.
private JFreeChart createChart(final CategoryDataset dataset) {
final JFreeChart chart = ChartFactory.createBarChart3D(
"3D Bar Chart Demo 2", // chart title
"Category", // domain axis label
"Value", // range axis label
dataset, // data
PlotOrientation.HORIZONTAL, // orientation
true, // include legend
true, // tooltips
false // urls
final CategoryPlot plot = chart.getCategoryPlot();
plot.setForegroundAlpha(1.0f);
// left align the category labels...
final CategoryAxis axis = plot.getDomainAxis();
final CategoryLabelPositions p = axis.getCategoryLabelPositions();
final CategoryLabelPosition left = new CategoryLabelPosition(
RectangleAnchor.LEFT, TextBlockAnchor.CENTER_LEFT,
TextAnchor.CENTER_LEFT, 0.0,
CategoryLabelWidthType.RANGE, 0.30f
axis.setCategoryLabelPositions(CategoryLabelPositions.replaceLeftPosition(p, left));
return chart;
* Starting point for the demonstration application.
* @param args ignored.
public static void main(final String[] args) {
Log.getInstance().addTarget(new PrintStreamLogTarget());
final BarChart3DDemo2 demo = new BarChart3DDemo2("3D Bar Chart Demo 2");
demo.pack();
RefineryUtilities.centerFrameOnScreen(demo);
demo.setVisible(true);
}this is the first time i'm trying to execute jfree programs...
regards,
R.Raghavanhere's error message
E:\raghav>javac BarChart3DDemo2.java
BarChart3DDemo2.java:3: cannot find symbol
symbol : class ChartFactory
location: package org.jfree.chart
import org.jfree.chart.ChartFactory;
^
BarChart3DDemo2.java:4: cannot find symbol
symbol : class ChartPanel
location: package org.jfree.chart
import org.jfree.chart.ChartPanel;
^
BarChart3DDemo2.java:5: cannot find symbol
symbol : class JFreeChart
location: package org.jfree.chart
import org.jfree.chart.JFreeChart;
^
BarChart3DDemo2.java:6: package org.jfree.chart.axis does not exist
import org.jfree.chart.axis.CategoryAxis;
^
BarChart3DDemo2.java:7: package org.jfree.chart.axis does not exist
import org.jfree.chart.axis.CategoryLabelPosition;
^
BarChart3DDemo2.java:8: package org.jfree.chart.axis does not exist
import org.jfree.chart.axis.CategoryLabelPositions;
^
BarChart3DDemo2.java:9: package org.jfree.chart.axis does not exist
import org.jfree.chart.axis.CategoryLabelWidthType;
^
BarChart3DDemo2.java:10: package org.jfree.chart.plot does not exist
import org.jfree.chart.plot.CategoryPlot;
^
BarChart3DDemo2.java:11: package org.jfree.chart.plot does not exist
import org.jfree.chart.plot.PlotOrientation;
^
BarChart3DDemo2.java:12: package org.jfree.data.category does not exist
import org.jfree.data.category.CategoryDataset;
^
BarChart3DDemo2.java:13: package org.jfree.data.category does not exist
import org.jfree.data.category.DefaultCategoryDataset;
^
BarChart3DDemo2.java:14: package org.jfree.text does not exist
import org.jfree.text.TextBlockAnchor;
^
BarChart3DDemo2.java:15: package org.jfree.ui does not exist
import org.jfree.ui.ApplicationFrame;
^
BarChart3DDemo2.java:16: package org.jfree.ui does not exist
import org.jfree.ui.RectangleAnchor;
^
BarChart3DDemo2.java:17: package org.jfree.ui does not exist
import org.jfree.ui.RefineryUtilities;
^
BarChart3DDemo2.java:18: package org.jfree.ui does not exist
import org.jfree.ui.TextAnchor;
^
BarChart3DDemo2.java:19: package org.jfree.util does not exist
import org.jfree.util.Log;
^
BarChart3DDemo2.java:20: package org.jfree.util does not exist
import org.jfree.util.PrintStreamLogTarget;
^
BarChart3DDemo2.java:27: cannot find symbol
symbol: class ApplicationFrame
public class BarChart3DDemo2 extends ApplicationFrame {
^
BarChart3DDemo2.java:80: cannot find symbol
symbol : class CategoryDataset
location: class org.jfree.chart.demo.BarChart3DDemo2
private JFreeChart createChart(final CategoryDataset dataset) {
^
BarChart3DDemo2.java:80: cannot find symbol
symbol : class JFreeChart
location: class org.jfree.chart.demo.BarChart3DDemo2
private JFreeChart createChart(final CategoryDataset dataset) {
^
BarChart3DDemo2.java:50: cannot find symbol
symbol : class DefaultCategoryDataset
location: class org.jfree.chart.demo.BarChart3DDemo2
final DefaultCategoryDataset dataset = new DefaultCategoryDataset();
^
BarChart3DDemo2.java:50: cannot find symbol
symbol : class DefaultCategoryDataset
location: class org.jfree.chart.demo.BarChart3DDemo2
final DefaultCategoryDataset dataset = new DefaultCategoryDataset();
^
BarChart3DDemo2.java:64: cannot find symbol
symbol : class JFreeChart
location: class org.jfree.chart.demo.BarChart3DDemo2
final JFreeChart chart = createChart(dataset);
^
BarChart3DDemo2.java:67: cannot find symbol
symbol : class ChartPanel
location: class org.jfree.chart.demo.BarChart3DDemo2
final ChartPanel chartPanel = new ChartPanel(chart);
^
BarChart3DDemo2.java:67: cannot find symbol
symbol : class ChartPanel
location: class org.jfree.chart.demo.BarChart3DDemo2
final ChartPanel chartPanel = new ChartPanel(chart);
^
BarChart3DDemo2.java:82: cannot find symbol
symbol : class JFreeChart
location: class org.jfree.chart.demo.BarChart3DDemo2
final JFreeChart chart = ChartFactory.createBarChart3D(
^
BarChart3DDemo2.java:87: cannot find symbol
symbol : variable PlotOrientation
location: class org.jfree.chart.demo.BarChart3DDemo2
PlotOrientation.HORIZONTAL, // orientation
^
BarChart3DDemo2.java:82: cannot find symbol
symbol : variable ChartFactory
location: class org.jfree.chart.demo.BarChart3DDemo2
final JFreeChart chart = ChartFactory.createBarChart3D(
^
BarChart3DDemo2.java:93: cannot find symbol
symbol : class CategoryPlot
location: class org.jfree.chart.demo.BarChart3DDemo2
final CategoryPlot plot = chart.getCategoryPlot();
^
BarChart3DDemo2.java:97: cannot find symbol
symbol : class CategoryAxis
location: class org.jfree.chart.demo.BarChart3DDemo2
final CategoryAxis axis = plot.getDomainAxis();
^
BarChart3DDemo2.java:98: cannot find symbol
symbol : class CategoryLabelPositions
location: class org.jfree.chart.demo.BarChart3DDemo2
final CategoryLabelPositions p = axis.getCategoryLabelPositions();
^
BarChart3DDemo2.java:100: cannot find symbol
symbol : class CategoryLabelPosition
location: class org.jfree.chart.demo.BarChart3DDemo2
final CategoryLabelPosition left = new CategoryLabelPosition(
^
BarChart3DDemo2.java:100: cannot find symbol
symbol : class CategoryLabelPosition
location: class org.jfree.chart.demo.BarChart3DDemo2
final CategoryLabelPosition left = new CategoryLabelPosition(
^
BarChart3DDemo2.java:101: cannot find symbol
symbol : variable RectangleAnchor
location: class org.jfree.chart.demo.BarChart3DDemo2
RectangleAnchor.LEFT, TextBlockAnchor.CENTER_LEFT,
^
BarChart3DDemo2.java:101: cannot find symbol
symbol : variable TextBlockAnchor
location: class org.jfree.chart.demo.BarChart3DDemo2
RectangleAnchor.LEFT, TextBlockAnchor.CENTER_LEFT,
^
BarChart3DDemo2.java:102: cannot find symbol
symbol : variable TextAnchor
location: class org.jfree.chart.demo.BarChart3DDemo2
TextAnchor.CENTER_LEFT, 0.0,
^
BarChart3DDemo2.java:103: cannot find symbol
symbol : variable CategoryLabelWidthType
location: class org.jfree.chart.demo.BarChart3DDemo2
CategoryLabelWidthType.RANGE, 0.30f
^
BarChart3DDemo2.java:105: cannot find symbol
symbol : variable CategoryLabelPositions
location: class org.jfree.chart.demo.BarChart3DDemo2
axis.setCategoryLabelPositions(CategoryLabelPositions.replaceLeftPosition(p, left));
^
BarChart3DDemo2.java:118: cannot find symbol
symbol : class PrintStreamLogTarget
location: class org.jfree.chart.demo.BarChart3DDemo2
Log.getInstance().addTarget(new PrintStreamLogTarget());
^
BarChart3DDemo2.java:118: cannot find symbol
symbol : variable Log
location: class org.jfree.chart.demo.BarChart3DDemo2
Log.getInstance().addTarget(new PrintStreamLogTarget());
^
BarChart3DDemo2.java:120: cannot find symbol
symbol : method pack()
location: class org.jfree.chart.demo.BarChart3DDemo2
demo.pack();
^
BarChart3DDemo2.java:121: cannot find symbol
symbol : variable RefineryUtilities
location: class org.jfree.chart.demo.BarChart3DDemo2
RefineryUtilities.centerFrameOnScreen(demo);
^
BarChart3DDemo2.java:122: cannot find symbol
symbol : method setVisible(boolean)
location: class org.jfree.chart.demo.BarChart3DDemo2
demo.setVisible(true);
^
44 errors -
How to execute workflow through javascript in CRM 2013
Hi,
I have created a business process and I want to execute workflow on custom button through javascript. I tried this script but this script does not run after message box show. Please tell me how to execute my workflow through javascript
function RunWorkflow() {
var _return = window.confirm('Are you want to execute workflow.');
if (_return) {
var url = Xrm.Page.context.getServerUrl();
var entityId = Xrm.Page.data.entity.getId();
var workflowId = '541B45C9-3F88-4448-9690-2D4A365C3172';
var OrgServicePath = "/XRMServices/2011/Organization.svc/web";
url = url + OrgServicePath;
var request;
request = "<s:Envelope xmlns:s=\"http://schemas.xmlsoap.org/soap/envelope/\">" +
"<s:Body>" +
"<Execute xmlns=\"http://schemas.microsoft.com/xrm/2011/Contracts/Services\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">"
+
"<request i:type=\"b:ExecuteWorkflowRequest\" xmlns:a=\"http://schemas.microsoft.com/xrm/2011/Contracts\"
xmlns:b=\"http://schemas.microsoft.com/crm/2011/Contracts\">" +
"<a:Parameters xmlns:c=\"http://schemas.datacontract.org/2004/07/System.Collections.Generic\">"
+
"<a:KeyValuePairOfstringanyType>" +
"<c:key>EntityId</c:key>" +
"<c:value i:type=\"d:guid\" xmlns:d=\"http://schemas.microsoft.com/2003/10/Serialization/\">"
+ entityId + "</c:value>" +
"</a:KeyValuePairOfstringanyType>" +
"<a:KeyValuePairOfstringanyType>" +
"<c:key>WorkflowId</c:key>" +
"<c:value i:type=\"d:guid\" xmlns:d=\"http://schemas.microsoft.com/2003/10/Serialization/\">"
+ workflowId + "</c:value>" +
"</a:KeyValuePairOfstringanyType>" +
"</a:Parameters>" +
"<a:RequestId i:nil=\"true\" />" +
"<a:RequestName>ExecuteWorkflow</a:RequestName>" +
"</request>" +
"</Execute>" +
"</s:Body>" +
"</s:Envelope>";
var req = new XMLHttpRequest();
req.open("POST", url, true)
// Responses will return XML. It isn't possible to return JSON.
req.setRequestHeader("Accept", "application/xml, text/xml, */*");
req.setRequestHeader("Content-Type", "text/xml; charset=utf-8");
req.setRequestHeader("SOAPAction", "http://schemas.microsoft.com/xrm/2011/Contracts/Services/IOrganizationService/Execute");
req.onreadystatechange = function () { assignResponse(req); };
req.send(request);
function assignResponse(req) {
if (req.readyState == 4) {
if (req.status == 200) {
alert('successfully executed the workflow');Hi,
I used this script for execute the workflow but its not working. When I used alert(req.status); then 500 show. Please tell me what did I mistake in my script.
function RunWorkflow() {
var _return = window.confirm('Are you want to execute workflow.');
if (_return) {
var url = Xrm.Page.context.getClientUrl();
var entityId = Xrm.Page.data.entity.getId();
var workflowId = '541B45C9-3F88-4448-9690-2D4A365C3172';
var OrgServicePath = "/XRMServices/2011/Organization.svc/web";
url = url + OrgServicePath;
var request;
request = "<s:Envelope xmlns:s=\"http://schemas.xmlsoap.org/soap/envelope/\">" +
"<s:Body>" +
"<Execute xmlns=\"http://schemas.microsoft.com/xrm/2011/Contracts/Services\" xmlns:i=\"http://www.w3.org/2001/XMLSchema-instance\">"
+
"<request i:type=\"b:ExecuteWorkflowRequest\" xmlns:a=\"http://schemas.microsoft.com/xrm/2011/Contracts\"
xmlns:b=\"http://schemas.microsoft.com/crm/2011/Contracts\">" +
"<a:Parameters xmlns:c=\"http://schemas.datacontract.org/2004/07/System.Collections.Generic\">"
+
"<a:KeyValuePairOfstringanyType>" +
"<c:key>EntityId</c:key>" +
"<c:value i:type=\"d:guid\" xmlns:d=\"http://schemas.microsoft.com/2003/10/Serialization/\">"
+ entityId + "</c:value>" +
"</a:KeyValuePairOfstringanyType>" +
"<a:KeyValuePairOfstringanyType>" +
"<c:key>WorkflowId</c:key>" +
"<c:value i:type=\"d:guid\" xmlns:d=\"http://schemas.microsoft.com/2003/10/Serialization/\">"
+ workflowId + "</c:value>" +
"</a:KeyValuePairOfstringanyType>" +
"</a:Parameters>" +
"<a:RequestId i:nil=\"true\" />" +
"<a:RequestName>ExecuteWorkflow</a:RequestName>" +
"</request>" +
"</Execute>" +
"</s:Body>" +
"</s:Envelope>";
var req = new XMLHttpRequest();
req.open("POST", url, true)
// Responses will return XML. It isn't possible to return JSON.
req.setRequestHeader("Accept", "application/xml, text/xml, */*");
req.setRequestHeader("Content-Type", "text/xml; charset=utf-8");
req.setRequestHeader("SOAPAction", "http://schemas.microsoft.com/xrm/2011/Contracts/Services/IOrganizationService/Execute");
req.onreadystatechange = function () { assignResponse(req); };
req.send(request);
function assignResponse(req) {
if (req.readyState == 4) {
alert(req.status);
if (req.status == 200) {
alert('successfully executed the workflow'); -
How to execute batch file from JSP
hi frens !
i wanna know how to execute batch file from my JSP.i am using exec() method to get call the batch file. but its not working ....plz help
here mine code:-
File F = new File("C:/var.bat");
try{
if (F.exists())
Runtime rt = Runtime.getRuntime();
String url=F.getAbsolutePath();
Process proc = rt.exec(url);
proc.waitFor();
proc.destroy();
catch(Exception IOEx){
System.out.println(IOEx);
}Thanks and Regards
AllwynYou might improve your chances of getting help if you do two things:
1) Explain what "not working" means.
2) ChangeSystem.out.println(IOEx); to IOEx.printStackTrace(); (in the eventhat is in fact related to "not working"). -
How to execute a script(.sql) file from a PL\SQL procedure
I would like to know how to execute a .sql file from a stored procedure and the result of it should update a table. My .sql file contains select statements.
Hi!
just go through the following piece of code -
SQL> ed
Wrote file afiedt.buf
1 declare
2 str varchar2(200);
3 begin
4 str := '@C:\RND\Oracle\Misc\b.sql';
5 execute immediate(str);
6* end;
SQL> /
declare
ERROR at line 1:
ORA-00900: invalid SQL statement
ORA-06512: at line 5ORA-00900: invalid SQL statement
Cause: The statement is not recognized as a valid SQL statement. This error can occur if the Procedural Option is not installed and a SQL statement is issued that requires this option (for example, a CREATE PROCEDURE statement). You can determine if the Procedural Option is installed by starting SQL*Plus. If the PL/SQL banner is not displayed, then the option is not installed.
Action: Correct the syntax or install the Procedural Option.
Regards.
Satyaki De. -
How to track the URL that comes from a referred page using XSQL Custom Handler
Hi,
I have a cold fusion page(say cf.cfm) that sent a request to xsql page(say test.xsql) and then xsql page displays results. I want to capure the URL of cf.cfm page and then after checking its host name and path name for correctness then want to display the test.xsql results.
Please let me know how can I capture URL of the refered page(cf.cfm) in the Custom Handler and then I want to extract host-name and path-name out of that url and on the basis of their values I want to display the result of XSQL page(test.xsql).
Regards
a2012req.getHeader("Referer") will return the referring url
-
How to execute a SELECT statement in java??
Hello !!
In my java program , i need to delete a record of number X, so
i accept the number X from the keyboard
Then before deleting it
i want the program to show me the name, age of the record which has the number X
How to do thishello kylas
actually i didnt get why this program example?? wats
its executing ??? Look at reply #3 in your other thread:
http://forum.java.sun.com/thread.jspa?threadID=713289&messageID=4126346
Notice the similarity? You've now asked "How to delete a record in Java" and "how to execute a select statement in java". You may have noticed that, aside from the SQL and the call to execute and executeUpdate (for delete) it's the same code. This is because you don't so much do these things in Java, you do them in SQL. The Java code simply asks the Driver to execute whatever SQL you write. So, I really hope your next post isn't "how do I execute an UPDATE statement in Java".
Good Luck
Lee -
How to execute procedure in toad software
hiii guy's i run my procedure on sql prompt and it run properly
but when i tried this on toad i got an problem
after compiling my procedure on toad
when i write
execute procedure_name(parameter1,parameter2);
then i get an error i.e
ORA-00900: invalid SQL statement
can someone tell me how to execute procedure on toad
thanks in adv...........how to execute procedure in toad softwareIn TOAD's schema browser you can go to the procedures tab - right click on the procedure in question and choose execute procedure - a window should pop up, where you can give optional parameters - the rest should be almost self explanatory ;)
Maybe you are looking for
-
Schedule Job to run every day at 01:00:00 i.e. mid-night 01:00 AM
Dear Gurus, I want to create a job that will run every day at 01:00:00 i.e. mid-night 01:00 AM. and the above job will be started from 2-Jul-2010 01:00:00 I have created below code. BEGIN DBMS_SCHEDULER.CREATE_JOB( JOB_NAME => 'Smry_Dly_Trial' ,JOB_T
-
How do I download XCode4 from the Mac App store
I initially posted this at the Developer forums, but I chose the wrong forum to post in, and so I was directed here. Original message It failed a few times during the download but when I restarted it it started again from where it left off. This was
-
Kindly provide me this information : There is one printer already running in SAP system with default as Tray 1 . Now my requirement is to create new logical destination of same printer but using tray 2 such that one set of stationary (say new station
-
Suddenly, I can't scroll using the trackpad anymore.
I just installed Maverick today. On my Google Chrome, it suddenly stopped scrolling down. When I tried to view multiple imagines on Preview, gestures like the two-finger scrolling and the zoom in gestures doesn't work either. Help?
-
Hi! i was amazed when i found out that this was possible but was very pissed to find out that I cant make this work. when i import it, the .psd file is just a 2d image like a normal boring picture in the composition. it doesn't have any cameras or nu