Help needed on Leban's JpegGif

G

Guest

I recently saw steve leban's A2KLoadJpegGifVer33GDiPlus (
http://www.lebans.com/loadjpeggif.htm )and

liked it's way of doing things, but I could use some help. I am looking for
a way to import an image

(tiff) into a form/subform. We have a server (\\Jofopt02\drawings) that
stores all of our tiff's

from Autocad. When we lookup parts info withn Access from B.I. server it
returns info including a

drawing name, lets call one "Sample01". It does not include the .tif
extention. Is there a way to

alter the fLoadPicture to use the server drive (\\Jofopt02\drawings), use
the drawing name from the

field that contains the drawing name(called DrawNumb), add the .tif
extension, then return the

drawing into the image frame? This way we can see the parts info and a
drawing of it that we can see on one screen or print onto one sheet of paper.

I am baddddd with VBA, but if a sample code for this is do-able, somebody
would have a big fan. Below is the segment form Leban's file that I'd need to
work with


Private Sub cmdLoadPicture_Click()
' You must supply the reference to an Image Control
' when you call this Function. The FileName is Optional.
' If not supplied the File Dialog Window is called.
fLoadPicture Me.JGSForm.Form.Image1, , True
' To pass a FileName including the path
' call the Function like:
'fLoadPicture Me.Image1 , "C:\test.jpg"
' Set ScrollBars back to 0,0
' Scroll the Form back to X:0,Y:0
ScrollToHome Me.JGSForm.Form.Image1
End Sub
 
S

Stephen Lebans

Something like:
fLoadPicture Me.Image1 ,"\\Jofopt02\drawings" & Me.DrawNumb & ".tif"

The above code assumes you actually have a control on the form named
"DrawNum". If you don't then refer to the field in the recordset
directly. Also make sure you are using an Image control not an OLE Frame
control.


Perhaps you should use an ActiveX control instead. I really like the
Microsoft Office Doument Imaging ActiveX control. This control only
works with Win2K or higher and Office 2003.
http://www.microsoft.com/downloads/details.aspx?FamilyId=8F93E445-B1CF-4
477-A373-E17417D616BC&displaylang=en
--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
G

Guest

Thanks, I'll give it a try. On the Active-X issue though, at work we have
Windows XP-Pro and Office XP (2k2). I don't know part 1 of active-x. This
gives me a good starting point. If I encounter any issues, you might see
another question on this site. Again, THANKS A LOT (Yes, I know that's
shouting, but thanks, realy).
 

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