• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 179
  • Last Modified:

Delete last four charactors.

Hi!, guys.

I would ask you how to delete last four charactors.

Here is a string, "movie1.swf"
I would delete ".swf"

If you would tell me how to do that, I really appreciate.

portal123

0
portal123
Asked:
portal123
  • 2
  • 2
1 Solution
 
JimV_ATLCommented:
If you know that you're always going to delete the last four characters, then you cand do

<cfset oldstring = "movie1.swf">
<cfset newstring = left(oldstring,len(oldstring)-4)>

Good luck!

Jim
0
 
portal123Author Commented:
Thank you!,JimV_ATL

porta123
0
 
anandkpCommented:
hi - cld also have been done using

#listfirst('movie1.swf','.')#

K'Rgds
Anand
0
 
portal123Author Commented:
Thank you for posting, Anand!

I appreciate it

portal123

0
 
anandkpCommented:
ur welcome :)

cheers
Anand
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now