Solved

Image to Database and Back Again

Posted on 2002-06-04
6
182 Views
Last Modified: 2010-05-02
I need move an image from the image property of a picture box to a database and back again using VB.NET.

I've found a number of references showing how to do this.  They each take a slightly different approach but all only work with Option Strict Off.  When option strict is on they all result in an invalid cast exception.

Can someone provide the code to save and retrieve image data using VB.NET with option strict on?  (I need a solution that does not involve writing the data to a separate file)
0
Comment
Question by:Joe_Griffith
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 7053773
0
 
LVL 7

Author Comment

by:Joe_Griffith
ID: 7054401
I have seen those articles.  They suffer from the same problem I mentioned in that they seem to rely on a type conversion that works with option strict off but for which I can't figure out how to cast directly.  (one is in C# but appears, at least, to be similar to others I have tried.

0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7851458
Joe_Griffith, an EE Moderator will handle this for you.
Moderator, my recommended disposition is:

    Refund points and save as a 0-pt PAQ.

DanRollins -- EE database cleanup volunteer
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 7

Author Comment

by:Joe_Griffith
ID: 7853071
I would be delighted to clean up this question.  Other than increasing the points there doesn't seem to be a way to manage questions anymore.  What action should I take?
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7855643
Joe_Griffith,
Alas, the only direct user option for closing a Question is to Accept a Comment as an Answer.  The following options are available if you post a request to Community Support:
* Split points between two or more Experts
* Delete the question entirely
* Close it, but get a refund of your points

In this case, you are already in the queue for that last option so you need take no action.  If you want to exercise any of these options on your other questions, just make a 0-pt Question in the CS topic area and a Moderator will help you (be sure to include the question ID #).
0
 

Accepted Solution

by:
SpideyMod earned 0 total points
ID: 7912936
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question