Joe-

You can't assign a string value to RowSourceType - it's actually an integer.
But you shouldn't need to set that property in code anyway.  What's the SQL
of the empbymonth query?  Open the query in Design view, choose SQL View
from the View menu, and paste the text in a reply.

John Viescas, author
"Building Microsoft Access Applications"
"Microsoft Office Access 2003 Inside Out"
"Running Microsoft Access 2000"
"SQL Queries for Mere Mortals"
http://www.viescas.com/
 

-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of eliotchs
Sent: Thursday, December 01, 2005 2:47 PM
To: [email protected]
Subject: [ms_access] Re: Listbox based on a combobox choice

Hi Mitch,
I tried the following:
Forms!viewincidentsbymonth!Imy.RowSourceType = "Table/Query"
Forms!viewincidentsbymonth!Imy.RowSource = "empbymonth"

'where Imy=Listboxname
It still asks for parameter field data.
I know, I'm not getting something....

PS. I'm not that good with VB.

Thanks
Joe




--- In [email protected], "J. Mitchell Grossack" 
<[EMAIL PROTECTED]> wrote:
>
> Set the listbox rowsource after the user chooses the month and year.
> If the rowsource is set on form open that is when it is looking for 
> the parameters, not when you set the visible property.
> 
> Hope this helps,
> Mitch
> 
> --- In [email protected], "eliotchs" <[EMAIL PROTECTED]> wrote:
> >
> > Hi,
> > 
> > I'm trying to base a listbox on two combobox choices.
> > Example:
> > form has two comboboxes month and year.
> > and a listbox, set to visible.false on open
> > Once month & year is chosen,(OnExit)
> > I make the listbox visble, but I still get
> > the parameter boxes asking for the Month and the year.
> > 
> > Unlimate goal is: User chooses a month, then chooses a year,
> > the listbox then becomes visible on the same form with the 
clients 
> > based on chosen month and year.
> > 
> > 
> > Is there a way around this?
> > 
> > 
> > Thanks In Advance
> > Joe
> >
>








 
Yahoo! Groups Links



 







------------------------ Yahoo! Groups Sponsor --------------------~--> 
Get Bzzzy! (real tools to help you find a job). Welcome to the Sweet Life.
http://us.click.yahoo.com/KIlPFB/vlQLAA/TtwFAA/q7folB/TM
--------------------------------------------------------------------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ms_access/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to