rajuchacha007 Posted July 26, 2010 Share Posted July 26, 2010 Experts,In my report, I dispalying start time details of some data processes. When the expression class is set to java.lang.String I get the result in following way. Start Time 2010-05-28 18:06:36.0If I keep the expression class to java.util.date I get following result.Start Time: 5/28/10 6:06 PMIf I keep the expression to java.sql.TimeStamp I get following result.Start Time: 5/28/10 6:06 PM. My question is, is it possible to keep the expression class set to java.lang.String and set the clock 12 hours format instead of 24 hours format. (Right now I am able to see the time in 24 hrs format) so that i can see AM and PM along with seconds details. In other two expression classes I am not able to see seconds detail. Is it possible to achieve this? Do I need to set any property in this case? Or do I need to pass any SQl query for this? Also I see a blank page at the end of report which contains only header. I mean to say, my report is 3 pages. I see 4 pages. 4th blank one including header. Why I am seeing this? Please suggest/advise. Best regards. Link to comment Share on other sites More sharing options...
slow Posted July 26, 2010 Share Posted July 26, 2010 use the expression class set to java.util.Datebut use this pattern (copy it in the texfield) : yyyy-MM-dd KK:mm:ss a for the extra page I think there is a bad layout organization... try to set it better.give us feedback. (next time try to choose a better title maybe with some extra letters...)________________________________________________________if it works (and IT WORKS)... give me KARMA points please! : ) ________________________________________________________listening: A SERBIAN FILM (SRPSKI FILM) - SoundtrackPost Edited by slow at 07/26/2010 09:03 Link to comment Share on other sites More sharing options...
rajuchacha007 Posted July 26, 2010 Author Share Posted July 26, 2010 @slow Thank you for replying. I am doubtful about pattern. We do have pattern property in the report. Did you mean to copy this pattern (yyyy-MM-dd KK:mm:ss a)in text field expression? Link to comment Share on other sites More sharing options...
slow Posted July 26, 2010 Share Posted July 26, 2010 I'm talking about copy it to the "pattern expression", the 4° row in the text field properties editor on the right side of your Ireport standard layout when you click on the Date textfiled you want to format and show... 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