Page 1 of 2 12 LastLast
Results 1 to 15 of 24
  1. #1
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150

    background


    hi. I found this code: API: Put an image in Access window

    this is changing the background picture of access windows. however, when I tried it, i do not know how to fit the background picture in the access windows. i want the picture to be stretch to the whole access background, not center nor tiled?

    can somebody help me. thanks.

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    In the Form_Open code set the DrawMode to 5 and see what happens.
    .DrawMode = 5

  3. #3
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    i tried all numbers rural guy from 1 to 10 and the picture did not stretch to fill the whole access window.

    the number 5 that you want me to try did only show half of the picture vertically.

    do you have other suggestion?

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Sorry Marianne, I have not used the code but reading it suggested that 5 would invoke the STRETCH mode. What sort of picture are you using? bmp, jpg, tif?? What version of Access and what OS?

  5. #5
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    I use ms access 2000 on xp home sp2.

    how did you know that 5 would invoke stretch?

  6. #6
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    By looking at the code. Look at the Case statement further down in the code. What sort of picture are you using?

  7. #7
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    i tried using bmp and jpg file formats. yes, i have seen case 5. but it did not work. have you studied the whole code. do you think that is coded properly? my eyes and brains got twisted here...

  8. #8
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    I'm playing with it now. Did you create the Class and the Standard module and put the code in your form? There is a spot in the form code that needs to be changed as well. I've got acXP so I'll let you know.

  9. #9
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    thanks for bothering of studying it for us. yes I did create the class and module and code for the form. I did change the ".drawmode" to 5.

  10. #10
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    i will wait for your reply ruralguy.

  11. #11
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    It might take a while since I have everything installed and can't get a peep out of it. This could be fun.

  12. #12
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    hehehe...thought it was fun too....I will also try solving it. but I will still wait for your reply ruralguy....

    if you other approach of coding this one, it would be worth to try too. I will keep in touch here.

  13. #13
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    hi there ruralguy ! have you solved the problem yet? i tried all night looking at the code and I couldn't figure it out here.

  14. #14
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    I've got it working but what is documented as STRETCH seems to blow up a PRINT SCREEN of what is on the screen at the time. I'm still playing with it.

  15. #15
    marianne is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2009
    Location
    Asia Pacific Region
    Posts
    150
    ok. please let me know if you got it. thanks so much for your effort.

Page 1 of 2 12 LastLast
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Background Format
    By maysamab in forum Reports
    Replies: 7
    Last Post: 04-06-2009, 10:38 AM
  2. Change the colour of a form background
    By r_e_v_a_n_s in forum Forms
    Replies: 0
    Last Post: 11-15-2005, 03:39 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums