Search results

  1. M

    How to combine the two?...

    Hi, Basically, I've got to separate queries. 1st that shows services in a given time frame (defined by user) and 2nd that shows not allocated employees (using "Is Null"). What I need now is how to combine the two queries taking into account the fact that employee might be allocated to a job...
  2. M

    On error cancel event

    Hi John, It work perfectly, Thanks!
  3. M

    On error cancel event

    Hi, Quick question.. What code should there be between DoCmd.RunCommand acCmdDeleteRecord AND DoCmd.Close If I don't enter any data I get a msg "Record cannot be deleted at this time.." so I need a code that on error would cancel the event and carried on with closing the form. This is the...
  4. M

    IF code

    Thanks! I made it work with this code: Private Sub ClientType_BeforeUpdate(Cancel As Integer) If Me.ClientType = "Commercial" Then Me.Title.Enabled = False Me.Forename.Enabled = False Me.Surname.Enabled = False Me.BusinessName.Enabled = True Else Me.Title.Enabled = True...
  5. M

    Easiest way to do...

    Hello, I have many to many relationship (services to employees) so I've broken it down into 3 tables. In the 3 table I use combo box to choose service (ID, title) and employee (ID, full name) My question is... what is the best way to present this in a form taking into account the following...
  6. M

    IF code

    Hi, I didn't put anything in quotes so this is not a problem. Also, I tried to use If Me.ClientType = Commercial Then but I'm not sure what to do with Option Explicit What's more.. I can input data into fields Title, Forename and Surname if I haven't used the combo box, but once I use it I...
  7. M

    IF code

    Hi guys, I'm complete newbie with VBA. I have this form with a combo box to select either "Residential" or "Commercial". If "Residential" is selected I want Title, Forename and Surname fields enabled and Business Name field disabled and vice versa. I have this VBA code: Private Sub...
  8. M

    Improving business by going online

    Hi! I am helping a friend of mine with his business which offers building and constructions services. I am looking for some ways to improve its performance. I was thinking about an on-line system (some kind of website/ message board?) I don’t actually know. The idea is that clients could access...
  9. M

    Calendar - Help Needed

    Hello everyone, I wish to make a calendar which shows dates already booked by customers. All bookings from all records must be shown on the same calendar, but the thing is that these are not one day bookings. In my table I have ‘CommenceDate’ and ‘Duration’ (in days). I use a query to calculate...
  10. M

    IF Statement

    Thanks a lot! :D
  11. M

    IF Statement

    Hello Guys, One question, maybe simple, maybe not but hopefully someone can help me, I've got this: IIf([tblWorks.WorkStartDate]<Date(),IIf([qEndDateForWork.WorkEndDate]<Date(),"Work Done","Work In Progress"),"Future Work") AS WorkStatus besically, this takes the data from tblWorks and a...
  12. M

    Save record code

    Thanks for reply!:) Yes I will use it because I can't find the one I'm looking for. This code works if the user made just one change but if there were few changes only the last change made is undo. Regards, Matt
  13. M

    Save record code

    Hello every1. I am looking for code for a cmd button that will give a msg "Do you want to save changes?" with YES and NO options. If yes then the record will be saved a the form closed if No form wil be closed but no changes made to record. Thanks is advance!
  14. M

    A report that chooses between two addresses

    Dennisk thanks for reply:) I used your idea and it works!:) I have made a query with these details and I've got what I need: HouseNo: IIF(IsNull(tblAppointments.HouseNo),tblCustomers.HouseNo,tblAppointments.HouseNo) Street...
  15. M

    Urgent answer welcomed!

    Hello again, The way with two queries work fine!:) Thanks Peter! regards, matt
  16. M

    A report that chooses between two addresses

    Hello, I am trying to create a report that will be showing details of the appointment. There are address details that have to be displayed and here is a problem I don’t know how to solve because I have address details in the customers table and in the appointments table. If the address...
  17. M

    Count Null records AND......

    Thanks! It works:) regards, Matt
  18. M

    REALLY complex macro

    I have module with this code: Public Function ChangeFieldName(tblDatesDifferences As String, Field1 As String, EndDate As String) Dim db As DAO.Database, tdf As DAO.TableDef Set db = CurrentDb Set tdf = db.TableDefs(tblDatesDifference) tdf(Field1).Name = EndDate Set...
  19. M

    Urgent answer welcomed!

    Bat17 could You please give some example to demonstrate this? Moniker could you take a look: http://www.access-programmers.co.uk/forums/showthread.php?t=123251 ..well if that is pretty straightforward with VBA can you give code because I have no idea how to do it. Thanks!
  20. M

    REALLY complex macro

    I have the following code to rename my column.. Public Sub ChangeFieldName(tblDatesDifferences As String, Field1 As String, EndDate As String) Dim db As DAO.Database, tdf As DAO.TableDef Set db = CurrentDb Set tdf = db.TableDefs(tblDatesDifference) tdf(Field1).Name = EndDate...
Back
Top Bottom