You are not logged in. Your edit will be placed in a queue until it is peer reviewed.
We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.
Required fields*
- Hmm... that's the most worrying part, is I've already set it up that way. GotoControl is called from the form with the TabControl1 ('PartDetails'). The page names and subform names autocomplete as well. No Forms reference included, as you said. I'm starting to think this truly is a bug, or exactly as the error says: "The GoToControl cannot be used to go to a subform or tab page in Web forms." Worrying because BrowseTo works perfectly in web, and can swap out subforms entirely. If I had known I could've built similar functionality to TabControl with BrowseTo and a single subform.IT Bear– IT Bear2015-01-20 17:39:09 +00:00Commented Jan 20, 2015 at 17:39
- With further testing I was able to reproduce this error in a fresh database. Start with Access 2010 SP2, and create a new blank web db. No tables required, just create a blank web form with a button and a TabControl with Page0 and Page1. For the button's macro, make it GoToControl=Page1. Save the form and try it out, it should work perfectly. Now before uploading to SharePoint, you will have to set the "Web Display Form" to the one we just created. Now do Publish to Access Services and choose a SharePoint 2010 Server with SP2. Open the DB in web browser, and the button's macro no longer works.IT Bear– IT Bear2015-01-20 17:56:43 +00:00Commented Jan 20, 2015 at 17:56
- Note that the code will work + run in the client side, since controls behind a tab are rendered and exist when the form loads. For a web browser - read my above extended answer - such controls have NOT yet been rendered, and thus goto control will not YET work. Once you displayed that tab, then your code should work since the controls have been rendered and thus are now part of the DOM.Albert D. Kallal– Albert D. Kallal2015-01-21 20:59:57 +00:00Commented Jan 21, 2015 at 20:59
- Albert — I have tried what you said, and even with the tab Page I'm trying to "GoTo" selected & rendered in browser, I still get the error. I've tried to "GoTo" the TabControl first and then the Page, and even tried placing the code within the TabControl itself. Same error every time. I've updated my answer with steps to reproduce this error for yourself, as well as a sample database that demonstrates it. I understand your answer in theory, but in practice it always fails. Cheers if you can get it to work.IT Bear– IT Bear2015-01-28 20:06:53 +00:00Commented Jan 28, 2015 at 20:06
- You cannot switch the tab via code in web based (and I never suggested you could). So using goto control likely not going to help you much. What I stated is you cannot “reference” the control until it been rendered. However goto and referencing are TWO VERY different issues. So in general you cannot execute the goto control command until such time that tab + control has been displayed. (a VERY big difference).Albert D. Kallal– Albert D. Kallal2015-02-14 18:49:01 +00:00Commented Feb 14, 2015 at 18:49
| Show 1 more comment
How to Edit
- Correct minor typos or mistakes
- Clarify meaning without changing it
- Add related resources or links
- Always respect the author’s intent
- Don’t use edits to reply to the author
How to Format
- create code fences with backticks ` or tildes ~ ```
like so
``` - add language identifier to highlight code ```python
def function(foo):
print(foo)
``` - put returns between paragraphs
- for linebreak add 2 spaces at end
- _italic_ or **bold**
- indent code by 4 spaces
- backtick escapes
`like _so_` - quote by placing > at start of line
- to make links (use https whenever possible) <https://example.com>[example](https://example.com)<a href="https://example.com">example</a>
How to Tag
A tag is a keyword or label that categorizes your question with other, similar questions. Choose one or more (up to 5) tags that will help answerers to find and interpret your question.
- complete the sentence: my question is about...
- use tags that describe things or concepts that are essential, not incidental to your question
- favor using existing popular tags
- read the descriptions that appear below the tag
If your question is primarily about a topic for which you can't find a tag:
- combine multiple words into single-words with hyphens (e.g. sharepoint-online), up to a maximum of 35 characters
- creating new tags is a privilege; if you can't yet create a tag you need, then post this question without it, then ask the community to create it for you
default