B4J Question How to remove equals signs from POP3 data.

ottercat

Member
Licensed User
When you retrieve a message in the download completed event there will be equals signs placed in the middle of the lines of text. I believe they are all an equal number of characters. I'm assuming 64 characters. I've tried a number of different methods to get rid of them but since I am decoding HTML I can't just strip out all of the equals signs. Why are they there and how do I remove them? Another programming language I use does not do this but this language of yours lets me do what I need to on mobile devices as well as the desktop with one common language.

<html><div style=3d"font-family: arial, helvetica, sans-serif; font-size:12=
px;">you have been added as a user in the removed.<br /><br />you can =
access the site at: <a href=3d"https://url.emailprotection.link/?bck_xtoxqk=
wg~~">removed foods removed</a><br /><br /><table cellpadding=3d"5" cell=
spacing=3d"0" style=3d"font-size:12px; font-family: arial, helvetica, sans-=
serif;" width=3d"90%"><tr><td colspan=3d2 style=3d"background-color:#3067b1=
; color:#f8f298;"><b>new account information</b></td></tr><tr>
<td style=3d"border-bottom: 1px solid black;width:150=
px;" bgcolo......
 
Last edited:

ottercat

Member
Licensed User
I have removed some info here for obvious reasons. I have also put the font as fixed width courier new so that you can see that it comes in as fixed length strings of 75 characters plus the equals sign. This seems to be a byproduct of some sort of encoding. Essentially every 75 characters it puts in an equals and apparently an embedded hidden crlf.

<html><div style=3D"font-family: Arial, Helvetica, sans-serif; font-size:12=
px;">You have been added as a user in the ------------.<br /><br />You can =
access the site at: <a href=3D"https://------------------------------------=
qZt4JCcGPWFGsEhB-DAEej8pAWQ1at_Wu1nQeJcwfubenfBR7wWQ9A8M0BmBUkjsla0MDsVGypf=
Wg~~">---- Foods ------------</a><br /><br /><table cellpadding=3D"5" cell=
spacing=3D"0" style=3D"font-size:12px; font-family: Arial, Helvetica, sans-=
serif;" width=3D"90%"><tr><td colspan=3D2 style=3D"background-color:#3067B1=
; color:#F8F298;"><b>New Account Information</b></td></tr><tr>
<td style=3D"border-bottom: 1px solid black;width:150=
px;" bgcolor=3D#EFEFEF>E-Mail Address: </td>
<td style=3D"border-bottom: 1px solid black;" bgcolo=
r=3D#EFEFEF>[email protected]</td>
</tr><tr>
<td style=3D"border-bottom: 1px solid black;width:150=
px;" bgcolor=3D#FFFCDF>Password: </td>
<td style=3D"border-bottom: 1px solid black;" bgcolo=
r=3D#FFFCDF>8Hf7Iql</td>
</tr><tr>
<td style=3D"border-bottom: 1px solid black;width:150=
px;" bgcolor=3D#EFEFEF>Created For: </td>
<td style=3D"border-bottom: 1px solid black;" bgcolo=
r=3D#EFEFEF>Group Email</td>
</tr></table><br /><br />Thank You,<br />
<br/>
---- Foods -------------<br />=20
Outbound Logistics Team <br />
<br/>
For the ----- Outbound Logistics team, email: <a href=3D"mailto:eek:utboundlog=
[email protected]">[email protected]</a></span><br />
For Technical support, e-mail:<a href=3D"mailto:[email protected]">s=
[email protected]</a></span><br /></div>
</html>
 
Upvote 0

ottercat

Member
Licensed User
well it got screwed up because I edited it but you get the idea. PS we will donate to your project if we get this working. :)
 
Upvote 0

ottercat

Member
Licensed User
Found an earlier post by Erel that solves it. This would be in the download completed event of course. Thanks! Will register soon.

Dim s As String
Dim MSG As Message
MSG = MailParser.ParseMail(Message,File.DirApp)


s = MSG.Body
s = s.Replace("=" & Chr(13) & Chr(10), "")
Log(s)
 
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
Please use [CODE]code here...[/CODE] tags when posting code.

codetag001.png

codetag002.png

codetag003.png
 
Upvote 0
Top