Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Web Controls Tab Pages
Norman M 

10 years ago
I sell on Amazon German France UK. I have a form on it is a web control which links to 1 site. I want create 3 tabs. On one tab is the UK site , the other the German Site and the last the French site.
Current VBA code is:
Private Sub Form_Current()
DoCmd.Maximize
If Site = "FR" Then
    WebBrowser4.Navigate "http://www.amazon.fr/dp/" & ASIN
End If
If Site = "DE" Then
    WebBrowser1.Navigate "http://www.amazon.de/dp/" & ASIN
End If
If Site = "GB" Then
    WebBrowser1.Navigate "http://www.amazon.co.uk/dp/" & ASIN
End If
If Site <> "FR" And Site <> "GB" And Site <> "DE" Then
    WebBrowser1.Navigate "about:blank"
End If
End Sub

What I want to happen is


If Site = "FR" And page = 1 Then
    WebBrowser1.Navigate "http://www.amazon.fr/dp/" & ASIN
End If
If Site = "DE" And page = 1  Then
    WebBrowser1.Navigate "http://www.amazon.de/dp/" & ASIN
End If
If Site = "GB" And page = 1  Then
    WebBrowser1.Navigate "http://www.amazon.co.uk/dp/" & ASIN
End If
If Site <> "FR" And Site <> "GB" And Site <> "DE"  Then
    WebBrowser1.Navigate "about:blank"
End If

If Site = "FR" And page = 2 Then
    WebBrowser2.Navigate "http://www.amazon.de/dp/" & ASIN
End If
If Site = "DE" And page = 2  Then
    WebBrowser2.Navigate "http://www.amazon.fr/dp/" & ASIN
End If
If Site = "GB" And page = 2  Then
    WebBrowser2.Navigate "http://www.amazon.de/dp/" & ASIN
End If
If Site <> "FR" And Site <> "GB" And Site <> "DE" Then
    WebBrowser2.Navigate "about:blank"
End If

If Site = "FR" And page = 3 Then
    WebBrowser3.Navigate "http://www.amazon.co.uk/dp/" & ASIN
End If
If Site = "DE" And page = 3  Then
    WebBrowser3.Navigate "http://www.amazon.co.uk/dp/" & ASIN
End If
If Site = "GB" And page = 3  Then
    WebBrowser3.Navigate "http://www.amazon.fr/dp/" & ASIN
End If
If Site <> "FR" And Site <> "GB" And Site <> "DE" Then
    WebBrowser3.Navigate "about:blank"
End If


So the form display based on Site =

So I created a single page tab control. I selected and dropped the working web control on to the top of the tab.
Tested this it worked.
I then inserted a page saved went to from view and the webcotrol was on the 2nd Page even though I did not put it there, I inserted the third page same thing happened, I want to place 3 independent web controls on 3 pages.


So my questions are

1. how do I have webcontro11 on page 1, webcontrol 2 on page 2, webcontrol3 on page 3.

2. to correct my vba above so the page display on each tab correctly.
This wording is clearly wrong:

"If Site = "FR" And page = 1 Then"

Norman  

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 5/17/2026 11:33:19 AM. PLT: 1s