Opening a form from a Pop-up

I have a pop-up form I have created so that instructors can double-click on a 
user number and a New Student form is supposed to open.  I have done several 
pop-up boxes to open other forms and they all seem to work just fine.  
However, on this particular pop-up, when I double-click a number, I get the 
following error message "The specified field '[UserNumber]" could refer to 
more than one table listed in the FROM clause of your SQL statement."  I am 
using a query to draw the information and there is only one table being used 
in the query.  When I check the SQL statement, I only have one table listed 
in the FROM section.  There is one difference between the other pop-ups and 
this one.  The other forms are forms where data has already been entered, but 
this one has no data in the form.  There is, however, a form with a form 
number.  Any ideas on what I'm doing wrong?

--Lizasue
0
Utf
11/14/2007 5:55:03 PM
access.formscoding 7493 articles. 0 followers. Follow

3 Replies
1091 Views

Similar Articles

[PageSpeed] 28

It's hard to say without seeing your code.  What is the code in the double-
click event of the User number?  And, what is the recordsource of the popup
form?  Is there any code in the On Open event of the popup?  Your
observations suggest that the error may not be caused by the on-click event,
but may be in the popup form itself.

Can you provide some details, please?

John
 

lizasue wrote:
>I have a pop-up form I have created so that instructors can double-click on a 
>user number and a New Student form is supposed to open.  I have done several 
>pop-up boxes to open other forms and they all seem to work just fine.  
>However, on this particular pop-up, when I double-click a number, I get the 
>following error message "The specified field '[UserNumber]" could refer to 
>more than one table listed in the FROM clause of your SQL statement."  I am 
>using a query to draw the information and there is only one table being used 
>in the query.  When I check the SQL statement, I only have one table listed 
>in the FROM section.  There is one difference between the other pop-ups and 
>this one.  The other forms are forms where data has already been entered, but 
>this one has no data in the form.  There is, however, a form with a form 
>number.  Any ideas on what I'm doing wrong?
>
>--Lizasue

-- 
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/Forums.aspx/access-formscoding/200711/1

0
J_Goddard
11/14/2007 6:10:37 PM
On Nov 14, 9:55 am, lizasue <liza...@discussions.microsoft.com> wrote:
> I have a pop-up form I have created so that instructors can double-click on a
> user number and a New Student form is supposed to open.  I have done several
> pop-up boxes to open other forms and they all seem to work just fine.  
> However, on this particular pop-up, when I double-click a number, I get the
> following error message "The specified field '[UserNumber]" could refer to
> more than one table listed in the FROM clause of your SQL statement."  I am
> using a query to draw the information and there is only one table being used
> in the query.  When I check the SQL statement, I only have one table listed
> in the FROM section.  There is one difference between the other pop-ups and
> this one.  The other forms are forms where data has already been entered, but
> this one has no data in the form.  There is, however, a form with a form
> number.  Any ideas on what I'm doing wrong?
>
> --Lizasue

Hi there.  Whenever Access gives you an error like that, it's always a
good idea to put in the table or query name from where you're pulling
your data - even if you're only pulling from one table.  So instead of
using "UserNumber", use "Tablename.UserNumber".

Let me know if this works for you.

Dorothy

0
Dorothy
11/14/2007 6:33:04 PM
Dorothy, that was the ticket!  Thanks so much.
-- 
Lizasue


"Dorothy" wrote:

> On Nov 14, 9:55 am, lizasue <liza...@discussions.microsoft.com> wrote:
> > I have a pop-up form I have created so that instructors can double-click on a
> > user number and a New Student form is supposed to open.  I have done several
> > pop-up boxes to open other forms and they all seem to work just fine.  
> > However, on this particular pop-up, when I double-click a number, I get the
> > following error message "The specified field '[UserNumber]" could refer to
> > more than one table listed in the FROM clause of your SQL statement."  I am
> > using a query to draw the information and there is only one table being used
> > in the query.  When I check the SQL statement, I only have one table listed
> > in the FROM section.  There is one difference between the other pop-ups and
> > this one.  The other forms are forms where data has already been entered, but
> > this one has no data in the form.  There is, however, a form with a form
> > number.  Any ideas on what I'm doing wrong?
> >
> > --Lizasue
> 
> Hi there.  Whenever Access gives you an error like that, it's always a
> good idea to put in the table or query name from where you're pulling
> your data - even if you're only pulling from one table.  So instead of
> using "UserNumber", use "Tablename.UserNumber".
> 
> Let me know if this works for you.
> 
> Dorothy
> 
> 
0
Utf
11/14/2007 9:45:02 PM
Reply:

Similar Artilces:

VBA to open website and pass details
I have a acceess database for a shop and what to take payment via a online terminal, i have the website address and log in detaits. I have got the following code however i alwasy get an error or "Dim iePage As HTMLDocument" Any idea what could be causeing this Private Sub Command0_Click() Dim ieApp As InternetExplorer Dim iePage As HTMLDocument Set ieApp = New InternetExplorer ieApp.Visible = True ieApp.Navigate "https://live.sagepay.com/MySagePay/loginpage.asp" 'wait for page to load Do Until ieApp.ReadyState = READYSTATE_COMPLETE Loop Set iePage = ie...

Completing field on subform from command button on main form
This is a simplistic version of what I need to do. I have a form named frmCLIENT with a subform named sfFAMILY. On the form frmCLIENT I have a command butten and when I press it I want it to automatically complete a field named CHILDREN on the subform sfFAMILY with the word "NONE". Can anyone help me. Thanks, LDMueller The code for the button is Me.YourSubformName.Form.Children = "None" Me.YourSubformName.Form.Children.Requery 'so that you can see the results This assumes that the subform has only 1 record or that the record you want editing, is the first ...

I can't open Outlook Express on home computer
I am not sure if this newsgroup can help, but I can't open outlook express. I use version 5.0 from office 2000. My operating system is Windows ME. I have checked all .DBX files are not read only and have tried regenerating the Identities Registry Key. I have even tried downlowding a the program again. I don't know what else to do, it is getting tiresome always going through webmail to access my email. Thanks, Laura-Lee Try posting this in an Outlook Express news group - this is not one of them. Outlook is a part of Microsoft Office and is what this group supports. Outlook E...

the open xml file macintosch cannot be opened
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel Hi <br> I am working a word document saved as .docx and i saved it yesterday and today when I open it here is the message : <br><br>the open xml file macintosch cannot be opened because there are problems with the contents, unspecified errors, location : 2 <br> when I press OK, the second message appears : word found unreadable contents in &quot;name of the doc.docx&quot; Do you want to recover the contents of the document ? if you trust the source, click yes. <br> When I cl...

Cannot open Outlook #3
My problem is that when I go to open Outlook, a message pops up stating: Outlook Express could not be opened because MSOE.DLL could not be loaded: I have e-mails that I need and I was wondering if there was something I could do that would allow me to open up Outlook without losing any important information/e-mails? Thanks. Then you need to post to an Outlook express ng, OL is a different App David "kakazi" <kakazi@uclink4.berkeley.edu> wrote in message news:0a0301c3d3e8$3734dab0$a001280a@phx.gbl... > My problem is that when I go to open Outlook, a message > pops u...

Outlook 2003 Crashes Opening Other Users Calendar
Outlook 2003 SP3 all patches running against Exchange 2003. When user goes to view another users calendar outlook generates an Unknown Error, crashes and then comes right back up. It's a super fast restart. I've deleted the OST and recreated it, but it persists and its not just specific calendars. it can happen with anyone's or work fine, but its pretty persistent. Has anyone run into this? Thanks A little more info. Two events.... Event Type: Error Event Source: Microsoft Office 11 Event Category: None Event ID: 1000 Date: 4/24/2009 Time: 9:51:46 AM User: N/A Computer: TK...

i have a pps file that i cant open what do i need to open it with
i recieved a few pitures and cant open then because they are a pps file what do i need to open them with???? Certainly not Excel. Those are PowerPoint files. You can download a PP viewer from here. http://www.microsoft.com/downloads/details.aspx?FamilyId=428D5727-43AB-4F24-90B7-A94784AF71A4&displaylang=en Note instructions for download and installation. Gord Dibben MS Excel MVP On Fri, 29 Sep 2006 10:44:02 -0700, Marty <Marty@discussions.microsoft.com> wrote: >i recieved a few pitures and cant open then because they are a pps file what >do i need to open them with??...

place cursor in a specified text box in a Word form
Hello, I have a Word form developed in vba and when a specific textbox is empty a message box appears to tell the user to enter some data before they can proceed. When they click ok to continue the cursor places itself in textbox4 on the form but I want it to be in the box they have left empty (in this case textbox5). I have used the SetFocus method but that doesn't seem to do anything, it still ends up in textbox4. Any ideas anyone? Thanks. What sort of a form? If a protected form see http://www.gmayor.com/formfieldmacros.htm -- <>>< ><<> >...

Open File IF Not Opened
Goodmorning! I was looking for someone who could tell me how I could make a Macro Appliction open files only when there not opened. When a file is allready opened it should be left at alone. When a file is being opened, this file should be granted the opportunity to update it's pivot tables and carry out any external links. I hope someone has the answer! Thanks in advance! Here's some code that might help. It tests whether a file is open: if it is it activates it, otherwise it opens the file. If IsWindowOpen(lStr_FileName) Then Windows(lStr_FileName).Activate ...

Opening to a file
How can I set up Excel 2003 to open to a particular file. I have the Excel Win XP shortcut pointing to the file but Excel still opens a blank file. Thanks, CMA If you want a specific Excel file to open when you open excel application, then goto: The path to Startup folder would similar to this: C:\```Application Data\Microsoft\Excel\XLSTART Windows Explorer, move the icon of the workbook you want to open to an alternate startup folder. If you want to keep the workbook in its current location, use the Create Shortcut command on the File menu to create a ...

Text Form Fields
Not sure if I have posted this in the right area, but here goes. I am more familiar with excel so working with forms in word is new to me. I have been tasked with developing a number of forms at work in Word 2003 for posting on our website. A guy who left, and is now not contactable, developed a whole range of forms before he left. He made sure the forms could be filled in online by inserting text editable fields for client use (both the 'greyed out' section and dotted lines can be seen when viewing and completing online and the dotted lines auto-delete as text is inserte...

Outlook 2000 opening screen
When I open Outlook 2000, the first screen I see has the Inbox open. The Outlook Bar has the Outlook Shortcuts revealed. I don't mind seeing the Inbox, but I would like the Outlook Bar to reveal the shortcuts in the "My Shortcuts" section instead. I can't seem to find a way to set this, so I'd really appreciate some help. Many thanks. This may help http://support.microsoft.com?scid=kb;EN-US;Q198012 "Chocolate Sauce" <whoknowswhat@whoknowswhere.com> wrote in message news:Xns94697A308338Ewhoknowswhatwhere@195.8.68.206... > When I open Outlook 2000, t...

Open a "read only" floppy
I have a 3-1/2 floppy that I can't open. When I try to open it, I get a pop up box that says the fopppy is "read only" or can't be accessed or trying to access a read only location. Don't know what I did when I copied the info on the floppy but I need to retreive what is on it. HELP PLEASE! Never save a file to a floppy or try to open one from a floppy. If not ruined, try to COPY to the HD and then try to open. -- Don Guillett SalesAid Software donaldb@281.com "Diane" <anonymous@discussions.microsoft.com> wrote in message news:0ced01c3d581$ca4235...

Opening a recordset
How do you open a recordset where in the table is residing in another MDB file? -- Message posted via http://www.accessmonster.com Before I am using Set RS = CurrentDb().OpenRecordset(qryTest) qryTest is a query that gets its record from a linked table. That is exactly what I want to employ, opening a recordset from a linked table. jbkirby wrote: >How do you open a recordset where in the table is residing in another MDB >file? -- Message posted via http://www.accessmonster.com ...

table or form creation
I have tried for hours to get this work and I cannot. I need to do this. I have a list of items I sell for our charity group. I have various items and various sizes. e.g. Short sleeve t-shirts, long sleeve t shirts, hoody's etc., size small, medium, large, xlarge, xxlarge for $10 each. I want to put a name with the order, then add a cost per item, then total all the items purchsed. I want the final form to look like this. name item cost per item total # of items total cost In the end i want the report to say John Smith 1 XLarge and 1 medium SSleeve tee shirt $20.00 and ...

Opening hyperlinks in email
When I try to access a web page within a email I have received I get the following message..."this operation has been cancelled due to restrictions in effect on this computer". Anyone know what I need to correct in order to view attachments or hyperlinks within email I receive? ...

Cannot open excel docs from My Documents
I have Excel 2000 running on Windows 98SE. When I try and open a doc. from any folder outside of Excel a message pops up that says "Cannot find the file 'C:\My Documents\(Whatever the path folder is)\(name of Document).xls (or one of its components). Make sure the path and filename are correct and that all required libraries are available." At the same time it will open Excel, but no document. If I go to the open file button in Excel, then the file will open. I got a response from another newsgroup, but it did not solve the problem. He had me go to Explorer\View\Fo...

IDR_MAINFRAME Remains After Opening Document
I am using MSDS version 7.1.3088 on Windows XP. I have been using AppStudio to create a Windows program and have been using the default which uses IDR_MAINFRAME if a document is not open and IDR_PRONAMETYPE when a document is open. I don't know what I did (actually I was making an icon and copied the icon between IDR_MAINFRAME and IDR_PRONAMETYPE) but now the IDR_MAINFRAME is always the menu whether a document is open or not. I was wondering how I could return the program to the condition where the IDR_PRONAMETYPE menu is up when a document is open. Many thanks in advance, Peter. Pe...

why must I open an Excel document twice to get it to open after .
After I reinstalled Office due to a *&!X% worm, I now must open an Excel document twice in order to get it to open at all. The first time I try to open it the Excel doc is blank or totally gray. Then when I try to open it again, (file, open, etc.) the doc appears the way it used to when I opened it the first time. What happened? I know it has to do with where the docs are stored but how do I fix it? Hi When you try to open it the first time do you use File|Open, or do you double-click on the file in Explorer? If it's the double-click option, go to Tools|Options|General and ma...

can not open outlook #3
How do I run dectect? Does it run from Outlook? Since=20 outlook shuts down right after it's opened, I can't=20 access any outlook functions. thanks, Re: can not open Outlook=20 From: "Milly Staples [MVP - Outlook]"=20 <MillyS@donteventhinkaboutmailingmemvps.org> Sent: =20 5/10/2004 7:57:34 PM=20 =20 =20 Wiping out and reinstalling does nothing 99% of the=20 time. Try running=20 Detect and Repair first. --=81 Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion=20 intact. Due to the (insert latest virus name here) virus, all mai...

Possible to change default "All Open Workbooks" to "This Workbook" in macro dialogue box?
This is something that is always a problem for me. Whenever I'm selecting macros to run they are _always_, nearly without any exceptions at all, macros that are found in the current workbook. I'm always having to change the option of "All Open Workbooks" to "This Workbook" whenever I open the macro dialogue box. Can we change that (even if it's a reg edit)? Tx. :oD ...

Displaying Pictures in Columns on a Form
I have a form which displays (1) Teacher Name and (2) Teacher Picture. On the same form, I have a Subform with pictures of all the Students associated with the particular Teacher. Each pic of the Student shows, BUT, if there are more than 4 or 5 students, the pictures begin to scroll. Is there a way that I can have 2 columns of pictures so I can dispay maybe 8 or 10 student pics, then possibly with a NEXT button to move to the remaining student pics for that Teacher if there are any? I can't think of a clean way. And, I have to assume you using a2007...as the ability to display pi...

Excel cannot open email program.
I often use "file.. send to... mail recipient" to send a spreadsheet as text in the body of an e-mail. I prefer that to sending excel as an attachment, since my recipients may not have excel and usually don't need to see formulas. On my new computer however I get the message "excel could not open the e-mail program" if I try the first option above. Both excel 2002 and outlook 2002 are working fine. I "repaired" office just to be sure. Still doesn't work. Only difference is that the computer came with a trial version of office 2003 which I don...

Outlook will not open
Using Windows NT and Outlook 2002. In attempting to archive and copy .pst files, something has gone awry and Outlook will not longer open. I have used the Office repair on the installation disk, which did not help. Then, I reinstalled Office, which did not help. I suspect that the program is having difficulty reading various archived and copied .pst files, which are in different drives and various folders. I had run scanpst on all the .pst files before this problem occurred and they were all fine. Any thoughts will be much appreciated. Thanks. It fails to open with what error ...

reminders not popping up
I have a machine where reminders popup for emails in the Inbox, but don't popup for emails in Inbox's subfolders. They once did. It seems to have started after synchronizing offline folders. Any suggestions???? You may have been mistaken; by default, Outlook only fires reminders from the Inbox, Contacts, Calendar, and Tasks folders in the default mail store. It will not fire reminders from other default folders or from user created folders. You'd need a third party add-in to extend the functionality to other folders -- two such add-ins can be found at www.slovaktech.com. -...