JSP NEXT Actions-ALERTS
hi all,
i am using next actions in jsps
and i need to display a message to the use(on the screen)-an alert
how can achieve this in jsps?
any ideas
regards and thanks in advance
Hi u try this JavaScript u will get action name
function fnName() {
frm=document.FormName;
frm.action = "<html:rewrite action='/actionFileName.do' />";
alert("Going to this Action " + frm.action) ;
frm.exec.value = "methodName";
frm.submit();
}
Similar Messages
-
How to send List from jsp to action class
hi,
i m fetching list from database and showing to jsp as follows:
user can update that list i need to collect that updated list in next action class but i m not able to do that. can anybody suggest me any solution the code i m using is as follows:
<html:form action="/myUpdate">
<table>
<tr>
<td>
<label><input type="text" property="name" name="name" value=""/></label>
</td>
</tr>
<logic:iterate id="address" name="info" property="addressList" indexId="rowindex">
<tr>
<td>
<input type="text" value="" name="address[<bean:write name="rowindex"/>].houseno" />
</td>
<td>
<input type="text" value="" name="address[<bean:write name="rowindex"/>].roadname" />
</td>
<td>
<input type="text" value="" name="address[<bean:write name="rowindex"/>].city" />
</td>
<td>
<input type="text" value="" name="address[<bean:write name="rowindex"/>].state" />
</td>
<td>
<input type="text" value="" name="address[<bean:write name="rowindex"/>].country" />
</td>
</tr>
</logic:iterate>
<tr>
<html:submit/>
</tr>
</table>
</html:form>
here in privious action i m settting bean object in session with name 'info'. it is fetching data and disply it correctly but when i m trying to get this updated data in myUpdate action i m not getting list element.--------------- MyBean.java----------------------
package form;
import java.util.Iterator;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import org.apache.log4j.Logger;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;
* @author Sushant.Raut
public class MyBean extends ActionForm {
Logger log = Logger.getLogger(this.getClass());
/* (non-Javadoc)
* @see org.apache.struts.action.ActionForm#reset(org.apache.struts.action.ActionMapping, javax.servlet.http.HttpServletRequest)
@Override
public void reset(ActionMapping mapping, HttpServletRequest request) {
// TODO Auto-generated method stub
super.reset(mapping, request);
this.name = "";
public String toString()
System.out.println("name : " + this.name );
for(Iterator<Address> iterator = addressList.iterator(); iterator.hasNext();)
Address address = (Address)iterator.next();
System.out.println("city : " + address.getCity());
return null;
private static final long serialVersionUID = 1L;
private String name;
private List<Address> addressList;
* @return the names
public MyBean()
log.info("Bean Construtor is called.");
System.out.println("MyBean:::::constructor is called.");
public String getName() {
log.info("Bean getName() is called");
return name;
* @param names the names to set
public void setName(String name) {
this.name = name;
log.info("Bean setName() is called");
* @return the address
public List<Address> getAddressList() {
log.info("Bean getAddressList() is called");
return addressList;
* @param address the address to set
public void setAddressList(List<Address> address) {
log.info("Bean setAddressList() is called");
this.addressList = address;
public Address getAddress(int index)
log.info("Bean getAddress(int index) is called");
while(index >= addressList.size())
addressList.add(new Address());
return this.addressList.get(index);
public void setAddress(int index, Address address)
log.info("Bean setAddress(int index, Address address)) is called");
this.addressList.add(index, address);
}------------- Address.java------------
package form;
import javax.servlet.http.HttpServletRequest;
import org.apache.struts.action.ActionMapping;
* @author Sushant.Raut
public class Address {
private String houseno;
private String roadname;
private String city;
private String state;
private String country;
public Address(){}
* @return the houseno
public String getHouseno() {
return houseno;
* @param houseno the houseno to set
public void setHouseno(String houseno) {
this.houseno = houseno;
* @return the roadname
public String getRoadname() {
return roadname;
* @param roadname the roadname to set
public void setRoadname(String roadname) {
this.roadname = roadname;
* @return the city
public String getCity() {
return city;
* @param city the city to set
public void setCity(String city) {
this.city = city;
* @return the state
public String getState() {
return state;
* @param state the state to set
public void setState(String state) {
this.state = state;
* @return the country
public String getCountry() {
return country;
* @param country the country to set
public void setCountry(String country) {
this.country = country;
public void reset(ActionMapping mapping, HttpServletRequest request)
this.city = "";
this.country = "";
this.houseno = "";
this.roadname = "";
this.state = "";
}------ MyAction.java------
package action;
import java.util.ArrayList;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.log4j.Logger;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import form.Address;
import form.MyBean;
* @author Sushant.Raut
public class MyAction extends Action {
Logger log = Logger.getLogger(this.getClass());
public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response)throws Exception{
MyBean myBean = new MyBean();
log.info("Bean is Initialised.");
String name = "sushant";
Address address = new Address();
address.setCity("city1");
address.setCountry("India");
address.setHouseno("1111");
address.setRoadname("xyz Road");
address.setState("MH");
Address address1 = new Address();
address1.setCity("Hyderabad");
address1.setCountry("India");
address1.setHouseno("2222");
address1.setRoadname("ABC Road");
address1.setState("AP");
List<Address> addressSet = new ArrayList<Address>();
addressSet.add(address);
addressSet.add(address1);
myBean.setName(name);
myBean.setAddressList(addressSet);
request.getSession().setAttribute("info", myBean);
log.info("Bean is bound to session.");
System.out.println("MyBean object is bound to session.");
System.out.println(myBean);
return mapping.findForward("success");
}-------- show.jsp-----------
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-html" prefix="html" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-logic" prefix="logic" %>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-bean" prefix="bean" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<html:form action="/myUpdate">
<table>
<tr>
<td>
<label><html:text property="name" name="info"/></label>
</td>
</tr>
<logic:iterate id="address" name="info" property="addressList" indexId="rowindex">
<tr>
<td>
<html:text property="houseno" name="address" indexed="true"/>
</td>
<td>
<html:text property="roadname" name="address" indexed="true"/>
</td>
<td>
<html:text property="city" name="address" indexed="true"/>
</td>
<td>
<html:text property="state" name="address" indexed="true"/>
</td>
<td>
<html:text property="country" name="address" indexed="true"/>
</td>
</tr>
</logic:iterate>
<tr>
<html:submit title="Submit"/>
</tr>
</table>
</html:form>
</body>
</html> -
AC 5.3 Critical Action Alert Emails not being sent
HI:
We have set up Critical Action alerts for a couple of transactions and while the on-line alert logs are being generated correctly, the alert email is not being sent to the Risk Owner.
Does anyone know where I can trouble shoot this issue?
Thanks,
Margaret>
Alpesh Parmar wrote:
> Margaret,
>
> Have you set up the SMTP server in visual admin? RAR needs to use this server details to send out an email.
>
> Alpesh
Hi AlpeshMargaret,
Where are the instructions for setting up the SMTP server in visual admin for the purpose of Alert Generation? I am not seeing this in the Configuration Guide. Could you point me to the correct documentation?
Thanks!
Jes -
How to use jsp:plugin action with type = bean
Hi everybody,
I'm new to JSP so it could be a stupid question but I'm wondering how can I use a jsp:plugin action with a type equal to "bean".
Everyone is talking about type equal to applet so the browser can display this applet but if the type will be a bean so then
does it mean I can send a javaBean class to the client?
If yes, then can the javaBean object be executed on a client machine?
Or maybe I'm wrong. I don't know how it works.
Please give me a resolution.
Thanks,
Rafal.its not working.. it shows exception class not found exception.
i have placed the jsp and applet class in the same folder. but its not working.
jsp file path : OracleSpatial\mypackage\webmap.jsp
applet class : OracleSpatial\mypackage\demoApplet.class
demoApplet class inside package "mypackage".
code inside JSP is :
<jsp:plugin type="applet"
code="mypackage.demoApplet.class" width = "100%" height = "100%" >
</jsp:plugin> -
I am using numbers as a CRM and one of my columns is called 'Next Action Required' i.e
Next Action Required
Email Douglas on the 02-12-14 about information needed for tour
Call Thomas 0446 393 about booking trip
Thank you in anticipation
DougUtterly bizarre. I can't see your two follow-up posts when I'm logged in. However...
Things would be simple if Apple implemented Data Detectors for dates in Numbers, as they have in applications like TextEdit and Script Editor. Then you’d have a system-level means of quickly moving from a selected date in your CRM spreadsheet to Calendar.
Until that happy day arrives, though, we can approximate it with AppleScript and Automator.
First, make sure your Numbers table is called CRM and your column has the header Next action required. (You can change these if you want but you’ll also have to modify the script.) This is the basic setup:
Then, launch Automator and create a new workflow. From the Choose a type… dialog, specify Service.
At the top of the workflow, “Services receives selected…” should be set to text in Numbers.app. (You'll need to choose Other... from the pop-up and then navigate to Numbers.)
In the Library menu at the left, click on Utilities, then drag a Run AppleScript action into the main Automator pane. Delete all the boilerplate text from the script.
It should look like this:
Now copy and paste the script below into the Run AppleScript action.
on run {date_string}
tell application "Numbers"
tell document 1
tell active sheet
try
set crm_table to (item 1 of (every table whose name is "CRM"))
on error
display dialog "No CRM table in this sheet"
return
end try
tell crm_table
try
set the_selection to selection range
set the_row to row 1 of the_selection
on error
display dialog "Select some text in a cell"
return
end try
set the_col to item 1 of (column of the_selection)
set header_cell to cell 1 of the_col
if value of header_cell is "Next action required" then my run_calendar(date_string)
end tell
end tell
end tell
end tell
end run
on run_calendar(date_string)
try
set date_string to date_string as string
set real_date to date (date_string)
on error
set real_date to (current date)
end try
tell application "Calendar"
activate
switch view to day view
try
view calendar at real_date
on error the_err
display dialog the_err
end try
end tell
end run_calendar
Click the little hammer at the top to make sure that the script compiles (indents and colours in). If it doesn’t, you may need to sort out some line breaks in the copied and pasted script.
Now save the workflow as Go to date in Calendar. Quit Automator.
So what does the script do? Basically, it looks at the selected text in a Numbers cell and checks to see that the table name is “CRM” and the column header is “Next Action Required”. It then tries to convert the selected text into a valid date. If it can, it takes you to that date in Calendar. If it can’t, it takes you to today’s date. In both cases it switches Calendar to day view. You have to bear in mind that if you select all of “10/10/14 Call John re contract” it won’t understand that part of this is a date, and won’t go to October 10. You'd have to select just "10/10/14"
To run the Service, right-click or control-click on the selected text and go down to Services, then choose Go to date in Calendar:
Alternatively, run it from Services in the main Numbers menu.
You can set up a keyboard shortcut for any Service in System Preferences - Keyboard - Shortcuts. Post back if you need more info about this.
Tested with Numbers 3.5 (2109). This will not work with Numbers '09.
Hope this works for you, let us know how you get on.
H -
SPAM : next action - Perform Adjustment
Dear All,
I am applying SAP-HR support pack SAPKE47080 on my SAP R/3 4.7. I am getting " Perform Adjustment " as a next action.
Import phase 'RUN_SPDD_?' (17.02.2009, 21:55:07)
Manual modification adjustment is neccessary
Interrupt the import for execution of manual actions (17.02.2009, 21:55:07)
This is the log entry of SPAM. I am unaware of this .
plz suggest what should i do ?
Thanks in advance.
Ankit GuptaSomeone (maybe you) adjusted a table or other dictionary objects - you have to check and adapt all those that they appear "green" again.
When done, go back to SPAM and continue SP application.
http://help.sap.com/saphelp_nw70/helpdata/EN/2e/6d66587d9011d396b60000e82de14a/frameset.htm
Markus -
"get specified text" - how to pipe its result to next action in my Automato
trying to understand Automator's "get specified text" action. It seems to ask a question in the middle of a workflow, to which you input the answer. I want to pipe its output to the next action, ie, ask the user for a text string to which a text stamp will be applied to a multi-page PDF. Similiar to what Adobe Acrobat Pro can do if you go Documents/Add/Watermark.
There must be a simpler way then to spring for $500 to get a text stamp (basically a script's authors name) as a large diagonal background across all pages of a script thats been turned into a pdf.
Any suggestions or ideas are welcome. Im going to attempt to provide this solution free to the Mac community, since I couldnt find one out there.OK, that makes a little more sense.
The Watermark PDF Files action isn't going to do what you want - at least not without a little more work.
If you look at the Automator definition of that action it requires a list of files as its input. You can't pass in a piece of text to use as the watermark.
Therefore the 'Watermark PDF Files' action can follow the 'Get Selected Finder Items' (since that returns a list of files), but the watermark action requires the watermark be specified at build time - you can't add a dynamic watermark at runtime.
In addition to that, the watermark action requires an image file to be used as the watermark, not a piece of text.
The only Automator solution I can see to this would be to have one action that asks for text and generates a corresponding image file. This can then be used as the watermark file by the action. Off-hand, though, I can't see an easy Automator way to create an image file from an arbitrary piece of text... -
Conflicting Action Alert in RAR
Hi All
Has anyone got such a strange symbols/notations while checking the conflicting action alerts in GRC RAR> Informer tab> Alerts ?
3/13/2009 - 1:23:54 PM
User BI team HCLTBI01 (HCLTBI01)
Risk Violated B003: Basis Development & Client Administration
I could not understand what means?
Regards
AbhijeetHi Abhijeet
Check thread https://forums.sdn.sap.com/click.jspa?searchID=23633733&messageID=7005670
Regards,
Vit -
Difference between jsp forward action tag and response.forward()
hi guys
i have just started programming using j2ee technology.
could anyone please tell me what is the difference between the jsp forward action tag and froward method using the response object?There really isn't one. The JSP forward tag is a convenience tag for JSP, that uses the response method.
-
Passing values from a JSP to Action class
Hi,
I have one JSP in this I have two select boxes.
The first select box is populated with default values.
From the first select box I am selecting the value and moving to the other select box using java script.
Now the value in the second select box has to be submitted alongwith some other values which I am getting.
These values are to be submitted to a Action class and further to the form bean using struts.
In the form tag in JSP I am calling the struts action class.
The issue here is,I am able to get other values except the values in the second select box.
I am using simple JSP page to get form values and submitting.
I am not using struts tlds because of project constraints.
Please advise on how to pass these values.
Regards,
RamIf the value from the select box isn't submitted, then it's not inside the form. Check the HTML output of your JSP to debug this problem.
-
Hi everyone, this should be so easy, yet I am stuck.
I have a form region with an item P110_VESSEL_ID. This item is a select list. It is based on the query:
select distinct v.vessel_name, v.vessel_id
from vessels vessels v, frequent_fishermen ff
where ff.dea_permit_id = :G_PERMIT_ID and
ff:vessel_id = v.vessel_id
UNION
select v.vessel_name, v.vessel_id
from apex_collections a, vessels v
where collection_name = 'SUPVES_COLLECTION' and
a.c002 = v.vessel_id
If the user decides against the values in the select list query, they may opt to SELECT ALL VALUES. This SELECT ALL VALUES is a POST ELEMENT TEXT on P110_VESSEL_ID.
<a id="popVessels" href="#"><font color=blue>Select from ALL Vessels</a>
This all works fine.
The issue is that when the user selects a vessel name = 'UNKNOWN' and it's corresponding vessel_id value, I would like an ALERT to appear indicating that they should double check that the vessel is UNKNOWN and not that the is no vessel.
I created a dynamic action
event= change
select type = item
item = P110_VESSEL_ID
True ACtion #1 is the ALERT.
I currently have no other logic, but cannot even get this to work. Any thoughts. I have also tried the SELECT TYPE = jQuery Selector = select[name='P110_VESSEL_ID'] but that does not work either (though I am not certain if the value should be P110_VESSEL_ID or the static name of VESSEL_ID).
Any help is appreciated.
ps. the page is not submitted when the vessel is changed. There is other data that needs to be entered both in this region and others and many validations run when submit, so the submit would not be an option.
thanks again,
KarenKarenH,
KarenH wrote:
I created a dynamic action
event= change
select type = item
item = P110_VESSEL_ID
True ACtion #1 is the ALERT.
This should work. Sometimes I've see where there is other javascript on the page that may have some errors and is causing the dynamic action code to not be executed. Use your favorite browser script console to try and determine if this may be the case.
--Jeff
P.S. Your jQuery selector can be: select#P110_VESSEL_ID -
Passing value from JSP to Action in Struts
Hi,
I am populating JSP page with rows retrieved from the database and
represented as a List of Beans in forEach loop:
<c:forEach var="list" items="${OperationsForm.OperationsList}">
<c:choose>
<c:when test="${list.isCompleted =='Y'}" >
<td width="100">Completed</td>
<td width="100"> </td>
</c:when>
<c:otherwise>
<td width="100">Pending</td>
<td width="100"><input type="image" onclick="
rowId=value; form.action='action.do?command=notify'"
value="${list.OperationId}" />
</td>
</c:otherwise>
</c:choose>
</tr>
</c:forEach>
Have hidden field: html:hidden property="rowId" value="-1"/>
User is clicking the button corresponding to one of the rows
and I need to pass the value of that rowId to the Action class, so it does
something in the database [action completed]
Now how do I pass it , is that the right way of doing it with calling
request.getSession().getAttribute(rowId) in the Action class ?
As of now I am getting Javascript error "Object doesn't support this
property or method", complaining about rowId=value;
Using Struts 1.3
Please help !
TIA,
Oleg.So what you are saying is that I should add rowId here:
<input type="image" onclick="form.action='action.do?command=notify&rowId='
${list.OperationId}"/> , correct ?
I am not sure that it will work, especially with Struts tag.
I will probably try something like:
<html:submit onclick="form.action='action.do?command=notify'" value="${list.OperationId}">
I am relatively new to Struts, so now sure what will work or not and how to do it better. How do I catch the submitted value in the Action in either of these 2 cases, via action.getSession().getProperty("rowId") /
action.getSession().getProperty("submit") ?
I would probably do it as a URL rather than changing the action of the form.I will have to create a new action anyway to process that row [which is sending user e-mail regarding that row data/event].
Is the id the only thing you have to pass in?
Or do you need other values from the screen?Selected rowId is probably the only thing I care about, can access values from the Form in Action.
Thank you,
Oleg. -
Suppressing rows in the next mail alert (EBS)
Hi All,
I am working on an alert and looking to suppress those rows from appearing in the alert which were processed in the last alert.
i.e. Everytime the alert runs, it should NOT pickup the rows shown in the last alert.
I know there is a flag called ''suppress duplicates'' in alert sets page, however it doesnt seem to be working.
(I am not sure how to use this)
Can anyone help please.
Thanks in advance.
-Nil
Edited by: nimTree Consulting on Jun 10, 2009 11:01 AMHi,
I know there is a flag called ''suppress duplicates'' in alert sets page, however it doesnt seem to be working.
(I am not sure how to use this)This feature would work for a detail action (not for a summary action).
Note: 1056367.6 - Alert Sends Multiple Messages for Single Action w/ Suppress duplicate Enabled
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=1056367.6
Can anyone help please.Review the following document and see if it helps.
Note: 76318.1 - How to suppress Duplicate Values in Reports
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=76318.1
Regards,
Hussein -
"Problem in using JSP Standard Actions"
Hi,
I have a HTML file, which forwards a two parameter values to a JSP.
<html><body>
<form action="testaction.jsp">
Name:<input type="text" name="username">
Id :<input type="text" name="id">
<input type="submit">
</form>
</body></html>and my JSP goes this way
<html><body>
<jsp:useBean id="person" class="sample.Employee" type="sample.Employee" >
<jsp:setProperty name="person" property="*" />
</jsp:useBean>
Person is:<jsp:getProperty name="person" property="username"/>
ID is:<jsp:getProperty name="person" property="id"/>
</body></html>The class Employee in the JSP, is a class with getter and setters for user name and employee id.
On entering the data in the HTML page, and on cliking Submit, i am getting this error.
HTTP Status 500
org.apache.jasper.JasperException: Cannot find any information on property 'username' in a bean of type 'sample.Employee'Kindly help.
Thanks.hi,
post your bean file or check
weather
1)
String username = "";
public String getUsername ()
return username;
is correctly coded,
2)
in your jsp before <jsp:useBean
add this code
<%@page import="sample.Employee" %>3)
optional : just check weather your class is in correct path and code package statement in your sample.Employee.java, -
Automator doesn't go to next action step, actions not working
I am trying to make a simple Photoshop CS2 sequence in automator, I downloaded the CS2 actions from http://www.completedigitalphotography.com/index.php?p=339 ... i used:
Flatten Document
Resize Image
Save as TIFF
It only does the first step (flatten), it has a little green check mark next to each other action and said it completed them, but my image size remains unchanged, and it doesn't save as TIFF..
I tried to put 'Resize Image' on its own, and 'Save as Tiff', turns out they don't work on the image..
Whats the use of an automator if it doesn't do more than one action at a time? and whats the use of having actions if they don't do any action..
In the .sit file from the cs2action pack, are there action files or .atn files that i have to copy into my CS2 actions folder? When i upack the .sit file I don't find any .atn files...
Hope someone can ease my frustrations.Hi,
You need to add a "Continue" statement at the end of your
script otherwise you will have to click on Skip to go to next
slide.
And all the Quzzing information can be accessed from Flash
using the Quizn variables.
thanks
ravi
Maybe you are looking for
-
How to parse xml using DocumentBuilder ?
I am trying to parse this xml snippet: <root> <data a="0.0" b="1.0"/> <data a="0.1" b="2.0"/> <data a="0.2" b="3.0"/> <data a="0.3" b="4.0"/> <data a="0.4" b="5.0"/> <data a="0.5" b="6.0"/> </root> using the following: String test = getDummyXmlSn
-
Amount still in the remaining list of PO.
HI all, Could you please check why the amount is still in the Remaining list of PO.We canceled the requisition but it is still inside. How do i clear the amount? Plz help.
-
Hi, I have new database. In which i have to update the runtime repository parameters. Actually this database is the clone of existing database. In the table WB_RT_STORE_PARAMETERS, i have updated the parameter value and parameter name for new databas
-
QBE Error when query by String for Number column
Hi, I have a table with Number column. The column structure is like below: <af:column> <af:inputText> <f:validator .../> <af:converNumber ..../> </af:inputtext> </af:column> QBE is enabled for this column. It works fine when query by Number value, su
-
Problem using WebRowSetImpl within OSGI bundle.
Hallo to everyone, I used to use standard WebRowSetImpl in my Java programs to pass data between application layers without problem. Now, I'm facing an issue using WebRowSetImpl in an OSGI module: I get a ClassNotFound Exception while trying to insta