Search results

  1. SteveSchapel

    Need running total to display zero if null

    Skwilliams, Try it like this: =IIf(IsNumeric(Sum(Nz([Amt],0))),Sum(Nz([Amt],0)),0)
  2. SteveSchapel

    Switch help

    Alternatively... Switch(Nz([Test_MR],0)<#1/1/2010#,"FAIL")
  3. SteveSchapel

    Problem when printing report

    Bosve, Do you have a Group Header or Footer section on the report design? Are you able to zip and attach a sample database file to illustrate this problem. Without looking at it, I can't think of any explanation. If you do upload, can you also please let us know what size labels you are...
  4. SteveSchapel

    Multiple If Statement

    TallMan, Yes, I do think it's a parentheses error. I am not sure exactly what, because I haven't figured out what it is all about. But, for example, in this section of the code: Me.Starts_On_PIP_Update < Date Or Day(Me.Ends_On_PIP_Update) <> 21 And Day(Me.Ends_On_PIP_Update) <> 7 ... I...
  5. SteveSchapel

    How to call a Public variable in a query?

    Teel, By the way, notice we have changed your Question# to QuestionNo, due to the fact that it is inadvisable to use a # as part of the name of a field or control.
  6. SteveSchapel

    How to call a Public variable in a query?

    LOL! Well, true, but in my efforts to illustrate the concept, I had deliberately avoided mentioning this syntax, for fear that Teel might then think we could create a single variable "1,2,3" and go: Where QuesitonNo In(TempVars!VariableName) ... which, for the record, won't work.
  7. SteveSchapel

    Automate LineNumbers for Sub-Form

    Karl, I think the thing to realise here is that data entered into Access tables has no intrinsic order. It is the "barrel of apples" concept. When you are viewing or outputting the data, to your forms ar reports, the only way to have that data in a particular order is to explicitly force it to...
  8. SteveSchapel

    Automate LineNumbers for Sub-Form

    Sorry to butt in here Namliam, but I think you will find that this will work fine: MyCounter = Nz(DMax("MyCounter", "OrderDetailT","OrderID= Forms!OrderF!OrderID")) + 1
  9. SteveSchapel

    How to call a Public variable in a query?

    Teel, A TempVar can be any data type. But it (like any variable) can only hold one value at a time. Do you mean you are trying to get the query to return: Where QuestionNo = "1 Or 2 Or 3" If so, well no, that won't work. There is no question where the number is "1 Or 2 or 3". It has to be...
  10. SteveSchapel

    Problem when printing report

    Bosve, It often takes quite a bit of playing around with labels to get them exactly right. In your case, it sounds like the Height of the report section for the labels is bigger then the actual size of the labels. Try squeezing up the design of the report.
  11. SteveSchapel

    Button opens form with specific data

    Only one word for it... Snap! :)
  12. SteveSchapel

    Button opens form with specific data

    Bsnalex, If Unit Number is the field on your primary form, and NUMBER is the related field in the popup form, then: "[Unit Number]=" & Me![NUMBER] ... is backwards. It should be: "[NUMBER]=" & Me![Unit Number] Oh, and please note, this is VBA, not VB.
  13. SteveSchapel

    Automate LineNumbers for Sub-Form

    Karl, In my experience, this is a very unusual requirement. If there is a "correct order" for your records, then this generally only makes sense if the "correct order" relates somehow to real-world existing data. So you therefore should be able to refer to the real data, without the need to...
  14. SteveSchapel

    Update replace query for characters with bracket

    Shermund, Does this do the trick?... Left([Names],InStr([Names],"(")-2)
  15. SteveSchapel

    Database Search filter

    Dada, How do you want it to do this filtering? Based on the value of one of the fields in your table? Or more than one field subject to the criteria you type into the textbox? And you want exact match, or "contains" match? Can you give some specific examples? Is Title the name of the...
  16. SteveSchapel

    Load Form and Update Table

    Re: Laughing ... :) gratifying to know I have been able to spread a little merriment.
  17. SteveSchapel

    Printing variable number of labels

    Adrian, Make a table with a single field, Number (Integer) data type, and fill this will numbers 1 to whatever the greatest number of labels you could ever imagine wanting printed at any instance. Add this table to the query that the labels report is based on, no joins, and in the Criteria...
  18. SteveSchapel

    Load Form and Update Table

    Twosides, I don't know what you mean by "add a flag". But if I understand the other part of the question correctly, you will be looking at code like this: If DCount("*", "Staff", "YourDateField = Date()") > 20 Then ' your flag raising ceremony here End If
  19. SteveSchapel

    IIF Value Error

    TooManyReports, I know you seem fixed on using an IIf() function in this case, but just curious, did you try the approach I suggested? I would never use IIf in such cases myself.
  20. SteveSchapel

    Annoying syntax error

    Jooey, I am not certain this will be the only problem, but for a start you can drop the word "OUTER". I am pretty sure your parentheses are in the wrong place too. Why not create the query using Access's query designer, and then look at the SQL view to see what you get?
Back
Top Bottom