Search results

  1. G

    Warn about conflicting entries and offer choice to edit conflicting entry or current

    Hi All I'm hoping someone can help me with some code to handle duplicate/conflicting entries. I am creating a resourcing database. Staff are scheduled for either AM, PM or All day for each date using a Form ("Resourcing"). The fields on the form are [Start_Date], [End_Date] and [Duration] (ALL...
  2. G

    Conditional formatting with like

    Just a footnote to this. As previously stated after applying the conditional formatting the form was ridiculously (unacceptably) slow to load. By sheer accident however I discovered that if I put this form into another form as a subform things worked differently. When I tried to open the...
  3. G

    Paste query to Excel template

    Ok so I updated this code posted by Paul Eugen in response to a similar query. It basically copies everything from my query "2014 Resources" to my spread sheet also named 2014 Resources. The spread sheet was created by exporting the query in the first place and then setting all sorts of...
  4. G

    Paste query to Excel template

    Ok Got references sorted Now I'm getting an error with this line of the second code I posted Set XLSheet = XLApp.Workbooks.Sheets("_2014_Resources") It highlights the word Sheets and the error is Method or data member not found.
  5. G

    Paste query to Excel template

    I probably shouldn't :) About 5 format conditions being applied to approximately 250 text boxes. Can't think why that would be an issue for Access but not for excel??????
  6. G

    Paste query to Excel template

    Hello again vbaInet. References is greyed out in the tools menu
  7. G

    Paste query to Excel template

    I also tried to adapt this that I found on here but still get User defined type not defined. Private Sub update_tracker_Click() Dim XLApp As Excel.Application Dim XLSheet As Excel.Worksheet Dim tmpRS As DAO.Recordset Set XLApp = CreateObject("Excel.Application") XLApp.Workbooks.Open...
  8. G

    Paste query to Excel template

    Hi With loads of help from vbaInet I was able to create a form with lots of conditional formatting that did pretty much everything I wanted it to do. The only problem is that it takes about 4 full minutes for the form to open. As an experiment I am reluctantly now trying to display the results...
  9. G

    Conditional formatting with like

    That worked. Yipee
  10. G

    Conditional formatting with like

    Yep. It loads in datasheet view
  11. G

    Conditional formatting with like

    Yep. The default view is datasheet
  12. G

    Conditional formatting with like

    Still stuck. Where do I put this? I tried For Each ctl In Me.Detail.Controls If ctl.ControlType = acTextBox And IsDate(ctl.Name) Then With ctl.FormatConditions .Delete ctl.ColumnWidth = 5760 .Add acExpression, , "[" & ctl.Name...
  13. G

    Conditional formatting with like

    Yes, vbaInet the form is ridiculously slow to load. About three minutes. I appreciate the hint but I'm afraid I don't have the skills to understand it. I know that excel is probably the better solution and I may eventually have to go that route but that will cause me a whole new set of...
  14. G

    Conditional formatting with like

    Thanks vbaInet The problem is that I'm struggling with how to write the column width in to the code. The code at the moment looks like: For Each ctl In Me.Detail.Controls If ctl.ControlType = acTextBox And IsDate(ctl.Name) Then With ctl.FormatConditions...
  15. G

    Conditional formatting with like

    Thanks vbaInet You have really helped. One last question if you don't mind. Could I also set the column width within that code? As the code Identifies all the date fields it would be good to get it to set the column width at the same time. I know the format is .ColumnWidth = xx but...
  16. G

    Conditional formatting with like

    Thanks vbaInet That's brilliant and I'll mark this thread as solved as a result. I do have two questions however. When I use the format wizard I can ask it to check two separate conditions so that if the field contains the word Delivery the background turns yellow and a second condition...
  17. G

    Conditional formatting with like

    Hi vbaInet Sorry I was away for a week and didn't have access to the database. I'll try your code now and let you know. Thanks once again for all your help and sorry for not getting back to you. Guinness
  18. G

    Conditional formatting with like

    Oh I added an expression 3 and expression 4: Dim ctl As Control Dim fcdSource As FormatCondition Dim fcdDestination As FormatCondition Dim varOperator As Variant Dim varType As Variant Dim varExpression1 As Variant Dim varExpression2 As Variant Dim varExpression3...
  19. G

    Conditional formatting with like

    So what I have is: Function AddFormats(ctlSource As Control, frm As Form) As Integer Dim ctl As Control Dim fcdSource As FormatCondition Dim fcdDestination As FormatCondition Dim varOperator As Variant Dim varType As Variant Dim varExpression1 As Variant Dim...
  20. G

    Conditional formatting with like

    Problem is that the field in question contains the "/" which vba wont accept So I can't write: AddFormats Me.02/01/2014_ID, Me I tried: AddFormats Me.[02/01/2014], Me But it crashed I'm losing the will to live Thanks for your help though. It's not your fault that I can't...
Back
Top Bottom