Dhiren Joshi

Ranch Hand
+ Follow
since Dec 09, 2003
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Dhiren Joshi

Does any one know how I can be assured of moving into a solo state.
I read up on info on IBM sites and the only information is that if I set portletWindowState="solo" and click that link, I would push portlet into solo state. That does not seem to be happening.

<h3>Your <a <br /> page.finance" rel="nofollow">
<% wpsURL.write(out); %>
</wps:urlGeneration>">Statement of Account
includes:</h3>


then my portlet checks if portlet is in solo state.
But this value always returns back a false.

/**
* @param request
* @return
* $A1
*/
public boolean checkSoloMode(RenderRequest request) {
boolean isSoloMode= false;
request.getWindowState();
System.out.println(" THE WINDOW STATE IN PORTLET="+request.getWindowState());
if (request.getWindowState().equals("solo")) {
isSoloMode=true;
}
return isSoloMode;
}


Is this an incorrect way of checking solo State in Portlet.

Thanks
Dhiren
14 years ago
I am making a very simple JSQL connect call from a Java application.
cstmt =con.prepareCall("{call msp_GetAllNames ?,?,?,?}");

cstmt.setLong(1,this.Number);
cstmt.setDate(2,this.Date);
cstmt.setString(3,this.ID);
cstmt.setInt(4,this.isNumber);

rs=cstmt.executeQuery();

The stored never seems to complete.
Any one gone through this issue.
Running the sp through SQL Query Analyzer works only does not work through Java .

Thanks
Dhiren
I have a test sandbox environment for Portal 6.0 .
I wish to connect my RAD 7.0 to this so that it looks as if I have integrated a WPS 6.0 test environment .
Is this possible. Are there any documentation any one can post if this is doable.. ?

Thanks for your help .
Dhiren
15 years ago
I am creating a URL =new URL("www.somesite.com/pdf/pdfa.pdf");
When this Servlet is invoked , I am getting this error.


I get error
IOException msg=Operation timed out: connect:could be due to invalid address: null
java.net.SocketException: Operation timed out: connect:could be due to invalid address
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:331)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:196)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:183)
at java.net.Socket.connect(Socket.java:478)
at java.net.Socket.connect(Socket.java:428)
at com.ibm.net.ssl.www2.protocol.http.x.b(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.a(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.p(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.<init>(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.<init>(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.a(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.a(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.y.a(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.bb.c(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.bb.connect(Unknown Source)
at com.ibm.net.ssl.www2.protocol.http.bb.getInputStream(Unknown Source)
at java.net.URL.openStream(URL.java:941)
at edu.servlet.pdf.PdfBase.openDocument(Pdf.java:60)

This URL when hit by a browser can be accessed.
More about the box on which the servlet is .
It is a WebSphere WAS6.1 server which is having two address IP Sec.
It is a DMZ box .
Anyone having any idea why I would not be able to access this URL ?
Any idea how to go about debugging this on a WAS 6.1 environment.


Thanks
Dhiren
17 years ago
Can portlets internally call portlets (JSR168) .
This is the code I added.
StringBuffer buf = new StringBuffer(request.getContextPath()+response.encodeURL("/PdfServlet"));
log("BasePortlet jsp file name=" + buf.toString() + "Trying to get to SERVLET PDF/SERVLET"
, METHOD_NAME, CLASS_NAME);
PortletRequestDispatcher prd=getPortletContext().getRequestDispatcher(
buf.toString());
prd.include(request,response);
What happens is this gets redirected into the Webcontent area so not sure how I can invoke my servlet from this RequestDispatcher.

Thanks
Dhiren
17 years ago
Is This possible?
If I want a portlet to communicate with a servlet like this..
StringBuffer buf = new StringBuffer(request.getContextPath()+response.encodeURL("/SomeServlet"));
log("BasePortlet jsp file name=" + buf.toString() + "Trying to get to SERVLET PDF/SERVLET"
, METHOD_NAME, CLASS_NAME);
PortletRequestDispatcher rd=getPortletContext().getRequestDispatcher(
buf.toString());
rd.include(request,response);
Is this possible from inside the portlet. ?
Thanks
Dhiren
17 years ago
Either way what you are trying can not be achieved from portlets.
Youa re trying to open a binary dowloadable file through portlet.
Portlets do not recognize any MIME type except text/html.
So also the httpservletresponse needs to be casted to a websphere specfic servlet response .
Anyway the correct way of handling such calls and I need to send a PDf output is that you invoke a link from your portlet page which in turn invokes a servlet in your web app and do the necessary content header setting in the servlet and write directly the stream output form servlet without going to the portlet.
HTH
Dhiren
17 years ago
I have a JSR168 portlet in WebSphere portal 5.1 .
I have saved data in application-scope of the portlet session.
How can I retrieve that data at the servlet end.
My servlet gets invoked from a JSP on the portlet.

Thanks
Dhiren
17 years ago
I have a PDf file which has forms.
Does any one know of any Java API that can be used to fill in values into the form .
I wish to open the form at runtime and populate the PDF and then show the output as a printer friendly output ?

Thanks
Dhiren
17 years ago
is there a Java API which works with existing PDF ?

Thanks
Dhiren
17 years ago
I have a PDf to which I need to append data at specific locations. The way the PDF is is that it has form fields. I need to fill those fields appending to an existing PDF and save the newly created PDF.
I am trying to using the iText API for Java to do that but I cant figure a way to use them for this purpose.
Has any one done that .Please post a small code snippet as to how I can go about doing this.
Please help me out.

Thanks
Dhiren
17 years ago
Can anyone tell me when which year/month WSAD either in beta or release was first avaialable for devlopers to develope on. ?

Thanks
Dhiren
17 years ago
Can anyone tell me when Java2.0 was released either in Beta version or General availabity.
similarly when was WSAD released for developement.

Thanks
Dhiren
17 years ago
Guys I havent got a reply yet on this .

ANY One PLEASE HELP!!!
Thanks
18 years ago
Just to answer some who asked if such questions are asked in interview. ...
U WONT BELEIVE IT ... Yes and I didnt beleive in any of them and failed one interview process just becuase of a pile of subjective question I had to answer on XML ,XSL,XSLT, Java ,Swing ,JSP and DB all in one taking in half hour sitting.

I have a solid 8 years of Java with SCEA Web service certified too. But that subjective was something like u needed to be prepared to sit for an exam and I didnt believe in such questions until I hit them in my interview process .. so believe me these questions are worth IT for senior Java positions ALSO !!! ... I know I have been bitten once .
18 years ago