Cross Tab Query in Form

N

Nano

I have a 'Crosstab Query' that calculates my each month's calls. The
query is working fine. Every time a new month starst another column
get updated itself. But when I display it in a form only those columns
come that I had added myself in while creating form, the new month's
column dosen't not appear it self. Is there any way that we the form's
column get updated itself ?

Thanking you in anticipation

Regards,
Hasnain raja
 
T

Tom Wickerath

Hi Hasnain,

I have not tried using a crosstab query with a form (since crosstab queries
are read only). The column names are determined at run-time, when you run the
query. I suspect that your form is designed with "hard-coded" field names as
the control sources for each text box. As a result, any new fields that show
up in the crosstab query will not have a textbox bound to it.

You can try the same idea that I implemented in this example, for using a
crosstab query in a report. VBA code behind the report dynamically assigns
the columns to text boxes:

http://home.comcast.net/~tutorme2/samples/SelfAdjustingCrosstabExample.zip


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 
N

Nano

Thanks for the help Tom, the example is quite informative and I have
learn lot of more things from that.

Regards,
Hasnain Raja
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top