• Subform/crosstab (Access 2000)

    Author
    Topic
    #386711

    Greetings,

    I have a field called NumOfApp in the main form and will be automatically field in, depending on how many applicants there are in the sub form. I had 3 records in the sub form and it was working fine, until I went to the table and deleted one record, compact and repaired it, but NumOf App still shows 3, where as in the sub form it shows 2 records (1of 2, 2 of 2). This is the code I had, please comment:

    Private Sub txtCount_Change()
    Forms![Applicant]![NumOfApp].Value = txtCount.Value
    End Sub

    2. I was trying to design a query based report to indicate the member of applicants whose case are denied each month and what % are denied within 10 business days and average # of days. How do I go about designing the crosstab query?

    Thanks,
    DD

    Viewing 1 reply thread
    Author
    Replies
    • #672057

      About your first question:

      As far as I can see, deleting a record in the subform has no influence on NumOfApp. You set NumOfApp when the user changes the value of txtCount. (I don’t know what txtCount is used for, but I would use the AfterUpdate event instead of the Change event to set NumOfApp.) Events such as Change (or AfterUpdate) only fire if the user changes the value interactively, not if the value is changed by Access or by code.

    • #672185

      About the second question:’

      What do you want as row headers and what as column headers?

      It might actually be easier to let the report do the aggregating – that’s what reports are good in. You could group the data by month and calculate the various numbers in the group header or footer.

    Viewing 1 reply thread
    Reply To: Subform/crosstab (Access 2000)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: