How to display 10 Images horizontally on a continuous form using vba (1 Viewer)

isladogs

MVP / VIP
Local time
Today, 19:14
Joined
Jan 14, 2017
Messages
18,186
@Exi
The screengrabs are quite impressive but I thought you were going to upload your db?
 

Exi

Registered User.
Local time
Tomorrow, 03:14
Joined
May 1, 2017
Messages
23
I wanted it on a form using vba instead of a cross tab.
so I can sort and select each Image as it will be the main view Form.
using statics web browser insert would work fine but I know nothing of how to write that code to allow image selection and add more sort options etc.
I'm not trying to see the whole 4000 pics at once just 40 per page as u roll the mouse down the next row loads within a sec even if you go to the last image its only a second delay.
and sorry bout the delay on the database but it took awhile to get it under 2 MB .
 
Last edited:

linux_s2002

Registered User.
Local time
Today, 12:14
Joined
Sep 20, 2017
Messages
21
I wanted it on a form using vba instead of a cross tab.
so I can sort and select each Image as it will be the main view Form.
using statics web browser insert would work fine but I know nothing of how to write that code to allow image selection and add more sort options etc.
I'm not trying to see the whole 4000 pics at once just 40 per page as u roll the mouse down the next row loads within a sec even if you go to the last image its only a second delay.
and sorry bout the delay on the database but it took awhile to get it under 2 MB .

Hi Exi!
Can you upload only the form in "Using static pic.jpg"?
Thanks
Silvia
 

Exi

Registered User.
Local time
Tomorrow, 03:14
Joined
May 1, 2017
Messages
23
sorry Silvia uncertian of what you mean
static was a person who I replied too
so Im uncertian about the "Using static pic.jpg"?
 

static

Registered User.
Local time
Today, 19:14
Joined
Nov 2, 2015
Messages
823
@Exi: It was an image of your form based on my form that you uploaded in a zip.

@linux: Links to the original files are in post #5, page one of this thread.
 

linux_s2002

Registered User.
Local time
Today, 12:14
Joined
Sep 20, 2017
Messages
21
@Exi: It was an image of your form based on my form that you uploaded in a zip.

@linux: Links to the original files are in post #5, page one of this thread.

Thank you!!!!!!!!!!!!!!! It's perfect for me!!!!
 

linux_s2002

Registered User.
Local time
Today, 12:14
Joined
Sep 20, 2017
Messages
21
Hi guys!
I write to you because after the last windows update, my code doesn't work like it used to.
I use webbrowser control and I displayed images horizontal.
After windows update (iframe.dll changed?), now I see images vertical.

Code:
With CurrentDb.OpenRecordset(sQuery)
sBody = "<html><body>"
Do Until .EOF
sBody = sBody & "<div>"
sBody = sBody & "<span style='width:150px;vertical-align:top;margin:1px;'>"

sBody = sBody & "<TABLE border='1' width='300'>"
sBody = sBody & "<TR><TD ROWSPAN='2'><p style='background-color: #F8FAB3;font-family: courier;font-size:9pt;'><b>" & .Fields("Titolo") & "</b></TD></TR>"
sBody = sBody & "<TR><TD>" & "<a href='#" & .Fields("tbl") & "#" & .Fields("ID") & "' style='font-family: courier;font-size:10pt;'>" & .Fields("ID") & "</a></TD></TR>"
If .Fields("genere") & "" <> "" Then
sBody = sBody & "<TR><TD COLSPAN='2'>"
sBody = sBody & "<span style='font-family: courier;font-size:8pt;'>" & .Fields("genere") & "</TD></TR>"
Else
sBody = sBody & "<TR><TD COLSPAN='2'>&nbsp</TD></TR>"
End If

sBody = sBody & "<TR><TD ROWSPAN='3'>" & "<img src ='" & .Fields("copertinaweb") & "' alt='" & .Fields("copertina") & "' height='250' width='170'>" & "</TD>"

sBody = sBody & "<TR><TD><p style='font-family: courier;font-size:9pt;'>" & .Fields("auth")
sBody = sBody & "<br>"

sBody = sBody & "<p style='font-family: courier;font-size:9pt;'>pag. " & .Fields("pagine") & "<br>"

sBody = sBody & "</TD>"
sBody = sBody & "</TABLE>"

sBody = sBody & "</div>"
sBody = sBody & "</span>"
.MoveNext
Loop
End With


What's wrong?

Thanks for help
Silvia
 

June7

AWF VIP
Local time
Today, 11:14
Joined
Mar 9, 2014
Messages
5,423
@linux_s2002, you should start your own thread instead of hijacking a very old one. A new thread will get more attention. Can include a link to this old one if you think it can help understanding your issue.
 

isladogs

MVP / VIP
Local time
Today, 19:14
Joined
Jan 14, 2017
Messages
18,186
@June7
Whilst I agree that a new thread might be better, @linux_s2002 was first involved in this thread when it was active back in 2017.
He/she isn't really hijacking an old thread so much as resurrecting it from the grave
 

June7

AWF VIP
Local time
Today, 11:14
Joined
Mar 9, 2014
Messages
5,423
Same point for resurrecting, new thread gets more attention. And is this really a new issue? Why would Windows update cause code to fail?
 

linux_s2002

Registered User.
Local time
Today, 12:14
Joined
Sep 20, 2017
Messages
21
Ok I create a new thread. I don't know why code fail after windows update.
thanks
 

Users who are viewing this thread

Top Bottom