Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / February 2006

Tip: Looking for answers? Try searching our database.

How to make a cross-tab query on a form interactive.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Stefan - 04 Feb 2006 19:07 GMT
Hello,

I've created an cross-tab query for visualisation my monthly expences, like
this:

              Feb 2006  Jan 2006   Dec 2005  ...
Clothing        45,00       60,00
Food            99,00       75,00         97,00
...

The query itself works fine, even if i limited the months (with the between
function).

So, to change these 'between' two months i wish to type them in a textbox
before i refresh the subform.
However, as soon if i make a subform based on the crosstab-query the values
and number of the labels for the months become permanent on the form and
don't change if i choose other months.

How can i make these query properly working on a form.   I use Access 2000.

Signature

many thanks,
Stefan

Duane Hookom - 04 Feb 2006 21:44 GMT
Try set the SourceObject of your subform using code like:

       Me.fsubOne.SourceObject = "Query.qxtbMyCrosstab"

Signature

Duane Hookom
MS Access MVP
--

> Hello,
>
[quoted text clipped - 20 lines]
> How can i make these query properly working on a form.   I use Access
> 2000.
Stefan - 05 Feb 2006 12:57 GMT
Duane,  thank for your reply but it won't work.  I still need to put fields
on the form.

However,  this morning i thought on something about using a listbox linked
to a SQL-string.

And it's working but with two minor problems:
1) Sometimes i need to scroll the list to see other months, in that case the
first column disappears from the screen.   How can i freeze it??

2) The alignment of the values are leftsided.  Is there a possibility to
changed it??

In the cross-tab query i can't refer to a field on a form for criteria so i
make the sql-string with visual basic and put it programmaticly into the
rowsource.

--
thanks
Stefan

> Try set the SourceObject of your subform using code like:
>
>         Me.fsubOne.SourceObject = "Query.qxtbMyCrosstab"

> > As soon if i make a subform based on the crosstab-query the
> > values and number of the labels for the months become permanent on the form and
> > don't change if i choose other months.
Duane Hookom - 06 Feb 2006 00:18 GMT
Search google groups on this string to see if the solution works for you.
  fsubone query "fsubone" group:*access* author:hookom

Signature

Duane Hookom
MS Access MVP
--

> Duane,  thank for your reply but it won't work.  I still need to put
> fields
[quoted text clipped - 28 lines]
>> > form and
>> > don't change if i choose other months.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.