<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
	<channel>
		<title>www.ritlabs.com [Topic: Extracting an email address from a file name]</title>
		<link>http://www.ritlabs.com</link>
		<description>New posts in Extracting an email address from a file name of  forum at www.ritlabs.com [www.ritlabs.com]</description>
		<language>en</language>
		<docs>http://backend.userland.com/rss2</docs>
		<lastBuildDateTag>Tue, 26 Jun 2007 06:56:58 +0300</lastBuildDateTag>		<item>
			<title>Extracting an email address from a file name</title>
			<description><![CDATA[<b><a href="http://www.ritlabs.com/en/forums/forum4/topic4809/message18290/">Extracting an email address from a file name</a></b> in forum <a href="http://www.ritlabs.com/en/forums/forum4/">The Bat! - Configuring the E-mail Client</a>. <br />
			You are remarkable, even when you are too tired to post. Thank you. Your last solution was successful.<br />Much thanks again. <br />
			<i>26 June 2007 06:56:58, <a href="http://www.ritlabs.com/en/forums/">Alex</a>.</i>]]></description>
			<link>http://www.ritlabs.com/en/forums/forum4/topic4809/message18290/</link>
			<guid>http://www.ritlabs.com/en/forums/forum4/topic4809/message18290/</guid>
			<pubDate>Tue, 26 Jun 2007 06:56:58 +0300</pubDate>
			<category>The Bat! - Configuring the E-mail Client</category>
		</item>
		<item>
			<title>Extracting an email address from a file name</title>
			<description><![CDATA[<b><a href="http://www.ritlabs.com/en/forums/forum4/topic4809/message18289/">Extracting an email address from a file name</a></b> in forum <a href="http://www.ritlabs.com/en/forums/forum4/">The Bat! - Configuring the E-mail Client</a>. <br />
			I shouldn't post when I'm supposed to sleep. The extra part is supposed to get before the filename, not before the path.<br />Try:<br />%SetPattRegExp='C:­\\Documents and Settings\\My Documents\\Ouput\\(.*?)~~(.*?)\.­txt'%- <br />%RegExpBlindMatch='%To'%-­ <br />%ModifyOnce(To)%- <br />%SetHeader(To,%SubPatt='2­')%- <br /><br />%SubPatt='2' because the address is now the second subpattern.<br /> <br />
			<i>26 June 2007 05:52:48, <a href="http://www.ritlabs.com/en/forums/">Roelof Otten</a>.</i>]]></description>
			<link>http://www.ritlabs.com/en/forums/forum4/topic4809/message18289/</link>
			<guid>http://www.ritlabs.com/en/forums/forum4/topic4809/message18289/</guid>
			<pubDate>Tue, 26 Jun 2007 05:52:48 +0300</pubDate>
			<category>The Bat! - Configuring the E-mail Client</category>
		</item>
		<item>
			<title>Extracting an email address from a file name</title>
			<description><![CDATA[<b><a href="http://www.ritlabs.com/en/forums/forum4/topic4809/message18288/">Extracting an email address from a file name</a></b> in forum <a href="http://www.ritlabs.com/en/forums/forum4/">The Bat! - Configuring the E-mail Client</a>. <br />
			Thank you again for your assistance.<br />Glad to hear "should be possible".<br /><br />I did try your recommendation without success.<br /><br />You said "two minor changes in the regular expression"<br />which I believe are (.*?) and ~~, but I also see the SubPath='2' is different from the original SubPath='1'.<br /><br />I have tested it both ways without success.<br /><br />I would be very eager and happy to test another solution that you may suggest.<br /><br />This what the file currently looks like:<br /><br />%SetPattRegExp='(.*?)~~C:\\Documents and Settings\\My Documents\\Ouput\\(.*?)\.txt'%- <br />%RegExpBlindMatch='%To'%-<br />%ModifyOnce(To)%- <br />%SetHeader(To,%SubPatt='2')%- <br />Hi %ABToFirstName="%ToFName", <br /><br />Thank you <br /><br />Regards, %FromFName<br /><br /><br /><br />Thanks again. I look forward to your reply. <br />
			<i>26 June 2007 05:08:44, <a href="http://www.ritlabs.com/en/forums/">Alex</a>.</i>]]></description>
			<link>http://www.ritlabs.com/en/forums/forum4/topic4809/message18288/</link>
			<guid>http://www.ritlabs.com/en/forums/forum4/topic4809/message18288/</guid>
			<pubDate>Tue, 26 Jun 2007 05:08:44 +0300</pubDate>
			<category>The Bat! - Configuring the E-mail Client</category>
		</item>
		<item>
			<title>Extracting an email address from a file name</title>
			<description><![CDATA[<b><a href="http://www.ritlabs.com/en/forums/forum4/topic4809/message18287/">Extracting an email address from a file name</a></b> in forum <a href="http://www.ritlabs.com/en/forums/forum4/">The Bat! - Configuring the E-mail Client</a>. <br />
			Sure, should be possible.<br /><br />Try something like this in your .tpl file:<br /><br />%SetPattRegExp='(.*?)~~C:\Documents and Settings\My Documents\Output\(.*?)\.t­xt'%- <br />%RegExpBlindMatch='%To'%-­ <br />%ModifyOnce(To)%- <br />%SetHeader(To,%SubPatt='2­')%- <br />Hi %ABToFirstName="%ToFName"­, <br /><br />That's two minor changes in the regular expression that extracts the address.<br /><br />I didn't test this though.<br /> <br />
			<i>26 June 2007 04:32:29, <a href="http://www.ritlabs.com/en/forums/">Roelof Otten</a>.</i>]]></description>
			<link>http://www.ritlabs.com/en/forums/forum4/topic4809/message18287/</link>
			<guid>http://www.ritlabs.com/en/forums/forum4/topic4809/message18287/</guid>
			<pubDate>Tue, 26 Jun 2007 04:32:29 +0300</pubDate>
			<category>The Bat! - Configuring the E-mail Client</category>
		</item>
		<item>
			<title>Extracting an email address from a file name</title>
			<description><![CDATA[<b><a href="http://www.ritlabs.com/en/forums/forum4/topic4809/message18282/">Extracting an email address from a file name</a></b> in forum <a href="http://www.ritlabs.com/en/forums/forum4/">The Bat! - Configuring the E-mail Client</a>. <br />
			On theBat! forum I asked if theBat! could extract an email address from a file name, and send the file to that address, if the file name was email@emailaddress.com.txt.<br /><br />I was kindly provided 2 files, sendfile.cmd and sendfile.tpl (shown below) and they worked successfully. Thak you.<br /><br />Now I am hoping I can get some help with theBat! to extract the email address, from a file name, that contains more than just the email address. The files have a name seperated by ~~ followed by the email address and then the extension. Here is an example of a file name:<br />myLifeStory~~email@emailaddress.com.txt<br /><br />Can theBat! extract the email address from a file name of this type and place the email address into the TO; line, and send it just as the files below accomplish?<br /><br />My main question here is: Can the file(s) below be modified to extract only the info that apppears between ~~ and .txt? (and place it in the TO: line? etc.<br /><br />Thank you. I look forward to your assistance.<br /><br />Sendfile.cmd<br />For %%i in ("C :\Documents and Settings\My Documents\Output\*.txt") do "C:\Program Files\The Bat!\thebat.exe" /MailT="C:\Documents and Settings\My Documents\Output\Sendfile.tpl";A="%%i";To="%%i";S=¬"¬%%i";Send <br /><br />Sendfile.tpl<br />And a sendfile.tpl, as template. Containing this: <br />-----Start of Sendfile.tpl-------------¬ <br />%SetPattRegExp='C :\Documents and Settings\My Documents\Output\(.*?)\.txt'%- <br />%RegExpBlindMatch='%To'%- <br />%ModifyOnce(To)%- <br />%SetHeader(To,%SubPatt='1')%- <br />Hi %ABToFirstName="%ToFName",<br /> <br />
			<i>25 June 2007 15:24:03, <a href="http://www.ritlabs.com/en/forums/">Alex</a>.</i>]]></description>
			<link>http://www.ritlabs.com/en/forums/forum4/topic4809/message18282/</link>
			<guid>http://www.ritlabs.com/en/forums/forum4/topic4809/message18282/</guid>
			<pubDate>Mon, 25 Jun 2007 15:24:03 +0300</pubDate>
			<category>The Bat! - Configuring the E-mail Client</category>
		</item>
	</channel>
</rss>
