• Post Reply Bookmark Topic Watch Topic
  • New Topic

Converting ASP to Java

 
casey Gould
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello

Can someone help me with this code snippet?

I'm converting from ASP to Java for a legacy site. I believe the first part of the if statement is right but I'm having an issue within the else staetment.

I'm getting date is undefined, I've tried using getYear and getDate but have not been successful.

Any help would be appreciated

ASP:


Java:
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Right: Java doesn't have any of those methods (Date, Month, UCase, MonthName etc.). You need to use the builtin APIs; start here: http://www.coderanch.com/how-to/java/JavaDatesFaq
 
Junilu Lacar
Sheriff
Posts: 10056
120
Android Eclipse IDE IntelliJ IDE Java Linux Mac Scala Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving to JSP forum. I'm also locking the last topic you started for the same question.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!