Save & Retrieve Tiff image from blob object to sqlserver using powerbuilder 8.0

Hi,

I have Tiff image files i want to store it as blob object to sql server 2000 using power builder 8.0. The Tiff image should be displayed on the screen.
Can anyone help me how to do this?
Please provide me some code and method to do this.

Thanking you in advance,

Imtiyaz
wellwisher888Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Vikas_DixitCommented:
Hi imtiaz,

u can create the OLE presentation stype datawindow to achieve the same. On the Inser Control screen ( while creating new datawindow, you will need to give the name of the OCX, that you want to display the tiff file with.

Regards,
Vikas
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
gajender_99Commented:
Hi Imtiyaz
I believe here is the solution for you problem.

1.Create a a Column in your table that have a data type of (BLOB/OLE OBJECT/Binary/TextLargeObject)

After the table has been created specify a SQL or quick select and select a presentation style for your new data window object.
In you select list specify the key columns for the table, but don’t select the BLOB column as a part of data source.

To add the BLOB column to your datawindow object click the “OLE Database Blob” from Insert  Controls. Click the datawindow where you want to place the blob object. This opens the database binary/text large object dialog box.

You can change the Client Name to  what ever you want.

Scroll through the list of tables  containing the Blob Column and click the table name.
The Large Binary/Text Columns List box displays all the columns from the selected table, now select the Blob column.

In the key clause type the id column for the table i.e id or emp_id.

You can leave the file template blank.

Now select the ole class by which you want to view the File

You can type a client name or use a computed text to give a name in client name expression.

. when your are running the window (I mean to say retrieved the data) you can double click on the blob column this bring the object which is associated with the blob object you can select a file  and close it .

this works fine in Powerbuilder 7 and it should work fine in 8 also if you get any error message just let me know I can provide a working example for this blob thing

thanks

Gajender
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Editors IDEs

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.