User Profile

Collapse

Profile Sidebar

Collapse
Wildster
Wildster
Last Activity: Feb 18 '09, 01:20 PM
Joined: Feb 29 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Wildster
    replied to Multiple counts
    Thanks guys, big help
    See more | Go to post

    Leave a comment:


  • Wildster
    started a topic Multiple counts

    Multiple counts

    Hi,

    How can you count x and y as seperate counts from the same field?

    i.e. A table has the field Gender and I want to have one count which counts the number of records with 'male' as the gender' and another count which counts 'female' as the gender?

    Any help will be very much appreciated
    See more | Go to post

  • The references were the problem, thanks very much for your help
    See more | Go to post

    Leave a comment:


  • Thanks for the post, it makes sense what you're saying. Although I've completely stripped the query back to something very basic and it still doesn't like OpenRecordset. There is something else more underlying which is causing the error (the solution you gave probably solved what would have been a preceeding error once this one was corrected).

    I've stripped the code back to: -

    Code:
    Dim db As DAO.Database
    Dim Rs As
    ...
    See more | Go to post

    Leave a comment:


  • Hi,

    I've got a similar problem to the one in this post which was solved.

    My error returned is "Invalid Argument" and it points to the line where OpenRecordset is used.

    My code is: -

    Code:
    Private Sub Command26_Click()
    
    Dim test As Database
    Dim Rs As DAO.Recordset
    Dim Msg As String
    Dim bFlag As Boolean
    
    Set Rs = CurrentDb.OpenRecordset("SELECT
    ...
    See more | Go to post

    Leave a comment:


  • Wildster
    replied to SQL Query
    Is there a way that the two queries can be brought together as one?

    Thanks
    See more | Go to post

    Leave a comment:


  • Wildster
    replied to SQL Query
    Didn't know you could do a query on a query, Genious!!

    Thanks very much for you help...
    See more | Go to post

    Leave a comment:


  • Wildster
    started a topic SQL Query

    SQL Query

    Hi,

    I've generated a query using the query builder in Access and it has generater the following: -

    Code:
    SELECT tblBooking.Booking_Date, tblBooking.Booking_Type, tblBooking_Time_Slot.Booking_Time_Slot, tblEmployee.Employee_Name
    FROM tblEmployee INNER JOIN (tblBooking INNER JOIN (tblBooking_Time_Slot INNER JOIN tblBooking_Slot ON tblBooking_Time_Slot.Booking_Time_Slot_ID = tblBooking_Slot.Booking_Time_Slot_ID)
    ...
    See more | Go to post

  • SQL query to return 1 record from multiple similar records

    Hi,

    I’ve setup a table which contains records with multiple duplicated time fields (tblTime_Slots)
    i.e.
    ID Time_Slot
    1 08:00
    2 08:00
    3 09:00
    4 09:00
    etc…

    I want to bring back the Time_Slots in a combo box, but rather than bringing back each Time_slot twice I want to write an SQL query that will only display each Time_Slot once.
    i.e....
    See more | Go to post

  • Wildster
    replied to An event within an event
    Thanks very much, it's a good solution to the problem and makes sense. Having made a few tweaks here and there it now works perfectly.

    Thanks again...
    See more | Go to post

    Leave a comment:


  • Wildster
    started a topic An event within an event

    An event within an event

    Hi,
    I want to put an event within an event but it seems as though this can't be done and I need to figure a work around. Basically I am trying to say that if the user clicks on the 'cmdRenewTraini ng' button then it just saves the record without the prompt asking if they wish to save. If they dont press the 'cmdRenewTraini ng' button then I want the prompt to ask them if they want to save changes. The code looks to make sense but I think...
    See more | Go to post

  • Wildster
    replied to DCount within VBScript in Access
    Sorted it, just added the AND statement at the end of the script I previously had, and also used a query to refer to the Still_With_Comp any checkbox from a linked table as you advised.

    Many thanks for the point in the right direction....
    See more | Go to post

    Leave a comment:


  • Wildster
    replied to DCount within VBScript in Access
    Hi, how would I add the criteria for the checkbox, would it be as simple as using another AND statement at the end? i.e.


    Code:
    intStore = DCount("[Training_ID]", "[qryTrainingGiven]", "[Training_Renewal_Date] <=Now() AND [Training_Renewed?] =0 AND checkbox = true")
    Thanks,...
    See more | Go to post

    Leave a comment:


  • Wildster
    started a topic DCount within VBScript in Access

    DCount within VBScript in Access

    Hi,

    I'm having a little trouble with some VB code within Access.

    I have the following code which assigns a DCount to an integer: -

    Code:
    intStore = DCount("[Training_ID]", "[tblTrainingGiven]", "[Training_Renewal_Date] <=Now() AND [Training_Renewed?] =0")
    It basically counts the number of records which have a Training_Renewa l_Date which is previous to todays date....
    See more | Go to post

  • Wildster
    replied to Complex booking form using VBA code
    Hi S7,

    Thanks for your quick response, the majority of it makes sense and it looks as though it covers everything needed. However when I click on the checkbox which contains the code is brings back the error message: -

    MS Access can't append all the records in the append query....and it didn't add 1 record to the table due to key violations

    The code it is getting stuck on is as follows: -

    ...
    See more | Go to post

    Leave a comment:


  • Wildster
    started a topic Complex booking form using VBA code

    Complex booking form using VBA code

    Hi,

    I have a form in Access 2000 running Windows XP with the following fields: -

    Booking_ID
    Date
    Person_Name
    Booking_Type
    8-9am (y/n checkbox)
    9-10am (y/n checkbox)
    10-11am (y/n checkbox)
    11-12am (y/n checkbox)

    I'm trying to write some VBA code which for any given date only allows a max of 3 bookings each for the two timeslots 8-9am and 9-10am, and a max...
    See more | Go to post
No activity results to display
Show More
Working...