Showing posts with label image. Show all posts
Showing posts with label image. Show all posts

Friday, March 9, 2012

Need advice how to write a program to receive an image via email and put it into the SQL S

Hello,
I am trying to find a way to write a program to do the following:
Receive an image via email, retrieve that image and put it into a database.
Could you please give me an advice where to start or point me into the right
direction? Is there an ASP component somewhere that would do the trick?
P.S. I have my own Windows 2003 server and SQL Server 2000, and can install
anything on my server if I need to.
Thank you,
Robert ZolnarHi Vanessa
If you can send the image as an attachment xp_readmail can save this to disc
where it can then be loaded in to the database. For SQL Mail you will need a
MAPI client e.g. Outlook 2000 installed on the server. Check out
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnovba01/html/SQLServerE-mail.asp
and Books online for more. Once the image has been materialised you than
then use something like the Bii sample program to load it
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/samples/samples_2isp.asp
If you want to do away with the Email you could use upload the image file
into a location (share) that is accessable by your SQL Server see
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/samples/samples_2isp.asp
This link also discusses the pros and cons of storing images in the database
John
"Vanessa Lee" <van77788@.yahoo.com> wrote in message
news:roKdnfLGWt-zymXeRVn-sw@.comcast.com...
> Hello,
> I am trying to find a way to write a program to do the following:
> Receive an image via email, retrieve that image and put it into a
> database.
> Could you please give me an advice where to start or point me into the
> right
> direction? Is there an ASP component somewhere that would do the trick?
> P.S. I have my own Windows 2003 server and SQL Server 2000, and can
> install
> anything on my server if I need to.
> Thank you,
> Robert Zolnar
>|||Hello John,
Thank you for your reply. Now that I know about MAPI as you mentioned, I
wonder if there is a way to avoid using SQL server at all and saving the
image to a file with a specific filename for a later retrieval.
Here is how I think it would work:
(1) Receive an image in email attachment.
(2) Retrieve the image from that attachment.
(3) Change the name of the image file into what was written in the Subject
of that email.
(4) Save the renamed image file into a specific folder.
(5) Delete the received email
Do you know about any other components or programs somewhere on the net
already written preferably in VBScript that it might be helpful for me to
look at?
Thank you.
"John Bell" <jbellnewsposts@.hotmail.com> wrote in message
news:O6LWOqVNGHA.720@.TK2MSFTNGP14.phx.gbl...
> Hi Vanessa
> If you can send the image as an attachment xp_readmail can save this to
disc
> where it can then be loaded in to the database. For SQL Mail you will need
a
> MAPI client e.g. Outlook 2000 installed on the server. Check out
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnovba01/html/SQLServerE-mail.asp
> and Books online for more. Once the image has been materialised you than
> then use something like the Bii sample program to load it
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/samples/samples_2isp.asp
> If you want to do away with the Email you could use upload the image file
> into a location (share) that is accessable by your SQL Server see
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/samples/samples_2isp.asp
> This link also discusses the pros and cons of storing images in the
database
> John
>
> "Vanessa Lee" <van77788@.yahoo.com> wrote in message
> news:roKdnfLGWt-zymXeRVn-sw@.comcast.com...
> > Hello,
> >
> > I am trying to find a way to write a program to do the following:
> >
> > Receive an image via email, retrieve that image and put it into a
> > database.
> >
> > Could you please give me an advice where to start or point me into the
> > right
> > direction? Is there an ASP component somewhere that would do the trick?
> >
> > P.S. I have my own Windows 2003 server and SQL Server 2000, and can
> > install
> > anything on my server if I need to.
> >
> > Thank you,
> > Robert Zolnar
> >
> >
>|||Hi
What you are wanting to do should certainly be possible, although I have
never used it with VBScript. See
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/exchanchor/htms/msexchsvr_mapi.asp for the SDK although the example are mainly in C/C++
John
"Vanessa Lee" wrote:
> Hello John,
> Thank you for your reply. Now that I know about MAPI as you mentioned, I
> wonder if there is a way to avoid using SQL server at all and saving the
> image to a file with a specific filename for a later retrieval.
> Here is how I think it would work:
> (1) Receive an image in email attachment.
> (2) Retrieve the image from that attachment.
> (3) Change the name of the image file into what was written in the Subject
> of that email.
> (4) Save the renamed image file into a specific folder.
> (5) Delete the received email
> Do you know about any other components or programs somewhere on the net
> already written preferably in VBScript that it might be helpful for me to
> look at?
> Thank you.
> "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> news:O6LWOqVNGHA.720@.TK2MSFTNGP14.phx.gbl...
> > Hi Vanessa
> >
> > If you can send the image as an attachment xp_readmail can save this to
> disc
> > where it can then be loaded in to the database. For SQL Mail you will need
> a
> > MAPI client e.g. Outlook 2000 installed on the server. Check out
> >
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnovba01/html/SQLServerE-mail.asp
> > and Books online for more. Once the image has been materialised you than
> > then use something like the Bii sample program to load it
> >
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/samples/samples_2isp.asp
> >
> > If you want to do away with the Email you could use upload the image file
> > into a location (share) that is accessable by your SQL Server see
> >
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/samples/samples_2isp.asp
> > This link also discusses the pros and cons of storing images in the
> database
> >
> > John
> >
> >
> > "Vanessa Lee" <van77788@.yahoo.com> wrote in message
> > news:roKdnfLGWt-zymXeRVn-sw@.comcast.com...
> > > Hello,
> > >
> > > I am trying to find a way to write a program to do the following:
> > >
> > > Receive an image via email, retrieve that image and put it into a
> > > database.
> > >
> > > Could you please give me an advice where to start or point me into the
> > > right
> > > direction? Is there an ASP component somewhere that would do the trick?
> > >
> > > P.S. I have my own Windows 2003 server and SQL Server 2000, and can
> > > install
> > > anything on my server if I need to.
> > >
> > > Thank you,
> > > Robert Zolnar
> > >
> > >
> >
> >
>
>