Stripping variable
Hi, I have the following variable (which can change based on directory). Below is the output from some examples: dir = D:\mywork\temp dir1 = D:\mywork\temp\dir1 How can I output only temp or dir1 from the above variables? --- Colonel Nathan R. Jessop Commanding Officer Marine Ground Forces Guatanamo Bay, Cuba --- ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com
Stripping variable
If all look similar to that shown, you might treat path as a list, with the / as delimiter. Then do a ListLast with the delimiter set to / My thought Keith Dodd [EMAIL PROTECTED] ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting.
RE: Stripping variable
ListLast(dir, \) HTH -Original Message- From: FlashGuy [mailto:[EMAIL PROTECTED]] Sent: Tuesday, December 3, 2002 13:30 To: CF-Talk Subject: Stripping variable Hi, I have the following variable (which can change based on directory). Below is the output from some examples: dir = D:\mywork\temp dir1 = D:\mywork\temp\dir1 How can I output only temp or dir1 from the above variables? --- Colonel Nathan R. Jessop Commanding Officer Marine Ground Forces Guatanamo Bay, Cuba --- ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com
RE: Stripping variable
erm... ListLast(dir1,\) should do it. -Original Message- From: FlashGuy [mailto:[EMAIL PROTECTED]] Sent: 03 December 2002 13:30 To: CF-Talk Subject: Stripping variable Hi, I have the following variable (which can change based on directory). Below is the output from some examples: dir = D:\mywork\temp dir1 = D:\mywork\temp\dir1 How can I output only temp or dir1 from the above variables? --- Colonel Nathan R. Jessop Commanding Officer Marine Ground Forces Guatanamo Bay, Cuba --- ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com