please help .. VBA to split data within the same field.

M

Mary

I am linking up to outlook inbox to extract mails. When my mails are
received, they are put in a series of fields. I am more interested in
splitting the contents table. This is the body of the outlook mail. Below is
a sample of our data reads in the same field.
Username=Terry L. Farmer
[email protected]
UserCompany=Millicent Pty Limited
UserComments=learning about data mining and
I would like a vba that will create a new table with a field for each item.
As shown below:

Field1
Username
Field2
Useremail
Field3
Usercompany
Field4
Usercomment

Please any help will be great. I have been searching for this for a while
but now look.
 
R

Roger Converse

You want a NEW table for each e-mail received? I get a ton of e-mails daily,
so I am guessing that you want to append new, truncated e-mail data to a
different table.

I am not sure I am understanding your issue correctly. Are you just looking
to remove everything before the "=" sign?

If so you can create a query that finds the position of the "=" sign and
then takes everything to the right of the "=" sign.

Field1 - FindSign: InStr(1,[fieldname], "=")
Field2 - GetText: Mid([FindSign]+1, 80) <== Where 80 is the number of
characters that you want to return.

Thanks,
Roger
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top