Solved

i have problem how pass i to field(image) to an image?

Posted on 1998-12-31
5
153 Views
Last Modified: 2010-04-04
i have problem how pass i to field(image) to an image?
i have these code:
table1.fieldbyname('foto').assign(image1.picture.graphic)
i need invert the process
something image1.picture.graphic:=table1.fieldbyname('foto').value
somebody can help me?
how is the form correct?
0
Comment
Question by:jamiguel
  • 3
  • 2
5 Comments
 

Author Comment

by:jamiguel
ID: 1354009
Edited text of question
0
 
LVL 5

Expert Comment

by:heathprovost
ID: 1354010
This should do it

Image1.Picture.Assign(Table1.FieldByName('foto').Value);
0
 
LVL 5

Expert Comment

by:heathprovost
ID: 1354011
Correction

Image1.Picture.Graphic.Assign(Table1.FieldByName('foto').Value);

but you really dont need to use the graphic property, you can just use the picture property. for example

Table1.FieldByName('foto').Assign(Image1.Picture);
and vise versus
0
 

Author Comment

by:jamiguel
ID: 1354012
i write these code:

image1.picture.assign(table1.fieldbyname('Foto').value);
and
image1.picture.graphic.assign(table1.fieldbyname('Foto').value);

but in both cases mark these error:  (at time of run or compile)
"incompatible types 'Tpersistent' and 'Variant' "

0
 
LVL 5

Accepted Solution

by:
heathprovost earned 0 total points
ID: 1354013
Sorry about that, I wasnt thinking the correct answer is

Image1.Picture.Assign(TBlobField(Table1.FieldByName('Foto')));

This WILL work, I tested.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

747 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now