Search results

  1. J

    Join Query Without Duplicates

    I'm questioning your placement of where the Design lead is. Shouldn't this field be in the projects table, instead of the assignments table? Your query would be much easier if it were, as well as this seems like the right place to put the field for normalization.
  2. J

    stLinkCriteria with alphanumeric fields

    The way to catch this kind of problem is to stop Access in debug on the next line and look at stLinkCriteria. At that point you would probably notice that there were not quotes or apostrophes around your code
  3. J

    Complicated formula?

    Here's how an If works. If(booleanTest,True,False) you put something into the booleanTest which can either be true of false. So with my last formula, =if(AE30=0,0.2,if(AE30<=6,0.1,0)) I am testing AE30 to see if it equals 0, if so I put 0.2 into whichever cell my formula is placed in (AF30). If...
  4. J

    Add text at end of value of textbox

    You could just have an unbound field which moves the data into the hidden bound field, but plog's first suggestion sounds better to me.
  5. J

    Complicated formula?

    what didn't work about my formula? I'm looking at the two descriptions you've provided, and they don't look the same. If AE30 value >2 then AF30 = 0.2 If AE30 value is between 1 and 2 then AF30 =0.1 Else AF30 = 0 0 = 0.2 >0 but <6 = 0.1 >5 = 0 I'll try again with your new requirements...
  6. J

    Complicated formula?

    =if(AE30>2,0.2,if(AE30>=1,0.1,0)) put the formula in AF30
  7. J

    Merging duplicate value

    Sounds like you can make an append/update query. you'll create a query with tblTemp and tblData with a left join (all records from tblTemp), then make it an update query. This will add records if not existing, and update fields for records already existing. If this won't work because you want...
  8. J

    Double Click File Name Errors Import

    You just need to put them where you're sure you're done with the objects, I usually put them at the end of the sub/function so that if there is an error, or I jump to the end of the function, I still clear the objects.
  9. J

    Double Click File Name Errors Import

    You should be removing all of your objects from memory at the end of your function by Set var = Nothing for each object which you did a Set on. e.g. Set sMyPath = Nothing Set objXL = Nothing
  10. J

    Error 2450 - Can't Find Form

    I think you should be able to reference the form this way Forms(strForm)![Patient ID] the reason [Forms]![strForm] doesn't work is that you are specifying a form named 'strForm'
  11. J

    Delete records in one table that relates to another table

    @arnelgp - records should be deleted from "Tbl_Finances", not "Tbl_Periods"
  12. J

    Including the sum of records from one query as a field in another

    Can you use the totals button in the design tab? This will sum a field and let you group by client. Specify the time period in the criteria, but uncheck the Show checkbox for the date so it won't try to group on the date.
  13. J

    Navigation form: limit access to tabs (Help)

    Set a breakpoint on your first statement then load the form and advance one line at a time (F8) and find out which line is having the problem.
  14. J

    Delete records in one table that relates to another table

    You do realize that neither table has a primary key defined? And since the Tbl_Finances doesn't have a primary key, how would the code know which record to delete? It would help me if I understood what these fields are. And some explanation of what you're trying to accomplish, not just that you...
  15. J

    Best way for managing several years of data.

    You should have one table which includes a date field (or an integer field representing the date in the format YYYYMMDD, or YYYYMM, or YYYY depending on your reporting needs). This will allow you to filter based on a combobox. You can at any time remove old records which are no longer useful...
  16. J

    Matching File Paths with WildCards

    It could be done various ways. If the folder names will change occasionally, or there is a large number of them, then the table method would work. If the folder names will stay consistent, then hard coding them in the VBA is an option. The most robust way would be to build a VBA routine which...
  17. J

    Matching File Paths with WildCards

    i don't see this line "strFile = line" what is the msg given for the runtime error? what do your debug.print lines show? do you have Option Explicit at the top to make sure all your variables are correctly typed? I don't know when it needs to be done, but sometimes I have to change the \ to /...
  18. J

    Public Function BusinessDays not working

    If the only thing you use this function for is to calculate the number of workdays for the entire month, you could modify it to subtract from the number of workdays if there is a holiday for the specified month instead of checking if the holiday lands on a workday and you always pick a different...
  19. J

    Public Function BusinessDays not working

    Assumption: this routine counts the number of workdays between (and including both) start and end date. therefore the loop counter should be For lngCount = 0 To DateDiff("d", dteStart, dteEnd) because you'll notice that the next line calculates the date to check if it's a holiday. dteCurr =...
  20. J

    Public Function BusinessDays not working

    what values are you passing to the function?
Back
Top Bottom