Results 1 to 7 of 7

Thread: {RESOLVED} Displaying Pictures From A File Path Stored In A Database

Threaded View

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Feb 2005
    Posts
    346

    Resolved {RESOLVED} Displaying Pictures From A File Path Stored In A Database

    Hey, I am using an ADO control to display records from my database and I want pictures to be shown to from a field in the same table, it has the pat hto the picture, I am using an image control to show them, when the form is loaded I am trying to get it too display the current record picture, here is my code

    VB Code:
    1. Private Sub Form_Load()
    2. browseConn = "Provider=Microsoft.Jet.OLEDB.3.51;Persist Security Info=False;Data Source=C:\Documents and Settings\Rob\Desktop\VB\contacts.mdb"
    3.     browseConn.Open
    4.     browseRecc.Open "SELECT * from Contacts WHERE Name='" & lblName.Caption & "'", browseConn, adOpenDynamic, adLockOptimistic
    5.     imgAvatar.Picture = LoadPicture(" & browseRecc(" & avatar & ") & ")
    6. End Sub

    And then when I run it, it says 'File could not be found & browseRecc() &'
    can someone please help ?
    Last edited by robcarr2; Jun 3rd, 2005 at 02:27 PM.

    Microsoft gives you Windows, Linux gives you the whole house!


    I am who I am because of who we all are.


    We have just gotten a wake up call from the Nintendo generation.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width