kiranreddys.com
Kiran's personal website
Blog    Forums   Sitemap   Social    Phone
 
     

 
Knowledgebase
 
Home
Knowledge base home, and site home.
Categories
List of all Knowledge base categories.
Glossary
An alphabetical list of technical terms.
Contact Me
Contact me for knowledge base questions
My Blog
My articles, white papers, ideas and thoughts.
 

 
 


String manipulation in Crystal Reports

Date Added January 1, 1970 | Print | Bookmark
'Code By Kiran Reddy
'String manipulation, convert a string to a date format
'If the date is stored in your database as a string or a number e.g..20040321 (yyyymmdd), you can convert this in to a proper date e.g dd/mm/yyyy
'Open formula editor and select Basic Syntax from drop down box and add following code

dim str1 as string
dim strday as string
dim strmon as string
dim stryear as string
dim strdate as string
str1 = {YOUR.FIELD}

stryear = left(str1,4)
strday = right(str1,2)
strmon = left(right(str1,4),2)

formula = "Schedule Date: " & strday & "/" & strmon & "/" & stryear

Was this article helpful?

Yes No

Category: Crystal Reports - General

Last updated on January 1, 1970 with 6593 views

1 User Comments

George
June 10, 2010 09:03 am

On line for strmon = left(str1,5,2) system is asking for a Statement is expected here message

Leave a Comment

CAPTCHA Image
Security code

 



Home | About Me | Products | Support | Contact | Knowledgebase | Forums | Blog | Site map | Site Search | Subscribe | Links | Social | News

Travel | Guest Book | All Pages | History | Site Calendar | Recipes | Ex-Rates | UK Stuff | Downloads | Telugu Stuff | Tell a Friend | Feedback

Bookmark and Share
www.kiranreddys.com
Terms of Use
Site contents Copyright © 2008-2009 Kiran Reddy. All rights reserved.