Search results

  1. J

    VB for sending emails on click

    Yes your email statement needs to go in the if statement so If [Order_Request] = True Then [Order_Date] = Date put docmd.sendobject line here else [Order_Date] = Null end if Just a thought is the [Order_Date] field empty before this proceedure? if so the default for the field is null so...
  2. J

    VB for sending emails on click

    Not sure that you have got your if .. then statements in the right order here. Should be for example if [request]=true then do stuff else do stuff End if Exit statement: do stuff Exit sub Error statement: do stuff End sub Assumming that Received_Request can only...
  3. J

    Word 2003 doesn't run Ac2K query

    I ran a lot of mail merges from word 2003 recently. I used the mail merge wizard and at one step ( 4 I think ) it asks you to select a data source and here you can then choose an access db and then select the relavent query or table. I did find the 2000 word mail merge setup more straight foward...
  4. J

    Record Count

    Dont think you have to do any counting here just compare the current records to the previous records if they are both identical then set the record count to plus one if they are not identical then set it back to one and repeat the process for all records
  5. J

    SQL line continuation help

    Try replacing "*" with '*' or """*""""
  6. J

    SQL line continuation help

    strSQL = "blah" strSQL = strSQL & "more blah" will also work presuming that your SQL syntax is correct. Check that you have the right numbers of brackets, semi colons and quotation marks. One way I have used in the past with this type of issue is to step through the code and use the locals...
  7. J

    Help concerning rounding.

    Two points I believe that the round function is only available in 2003 and also that it may not quite work in the way you would expect eg it rounds down .5 not up ( I am sure I will be corrected here if I am wrong ). I have done a quick search of the forum and i cant find the references to...
  8. J

    Email issue

    Has anyone got an idea why the following is happening. When using docmd.sendobject I have had an irritating problem that whilst it works perfectly with outlook it won't use outlook express despite OE being the default mapi programme ( windows XP and 2003) . After spending a couple of hours...
  9. J

    String Concatenation - where did I go wrong?

    Access 2003 VBA , programmers reference published by Wrox is very comprhensive
  10. J

    Returning A Value from a recordset - Dlookup?

    I believe that the problem is the date strings syntax should be similar to the following strSQL = "field = #" & datDate & "#"
  11. J

    Copying variable fron 1 form to another.

    Gordon Assuming both forms are open this should be straight foward. A line from a recent project illustrates this Forms!frmcreateinvoice!sfrmInvoiceDetail.Form!txtEngineerCode = strEngineerCode there is no reason why the string could not be replaced by a reference to to a field on a form...
  12. J

    Looping through records to sendobject

    On a brief look you do seem to be heading in the right direction. Search the site and you will find lots of threads on this subject. Minor point you have ststartDate = Date()-90 stendDate = Date() but you have dimed both as strings not dates. I find that it is easier when putting a SQL or...
  13. J

    adding numbers in order quickly

    Or assuming that the numbers are consecutive and integers Dim intStartNumber, intEndNumber, intLastNumber, intResult as integer intStartNumber = some input say 1 intEndNumber = some input say 1999 intLastNumber = Right("intEndNumber",1) if intLastNumber Mod 2 = 1 then ' checks last...
  14. J

    Extract Name

    Without putting too much thought into it one method is to search the the string for spaces using the MID function and then extract the letters after the spaces. Of course this assumes that there will always be spaces before the letters you want,that the first name will always be followed by a...
  15. J

    Debug Help

    I suspect that has to do with your SQL syntax. If the variables are strings ( which they were originally) then where statements should be WHERE somefield = """ & strString & """" or equivalent "'" & strString & "'" . I believe that for variants ( always try to avoid them) it is the same as...
  16. J

    Send email using addresses in a table.

    check out the many threads on this subject on the forum. The help file for the sendobject method and action are very comprehensive. Namliam's mail is a short overview of how to do it. If you have already created the query you are 75% there you just need to make a loop to send all the individual...
  17. J

    Sending e-mail through Outlook Express

    Ted regarding the security issue that's true but as the PCs are all in a safe environment behind a firewall and all with up to date antivirus software there is no issue in overiding the security settings for outlook. It would just be nice to be able to use OE but I suspect that is not possible.
  18. J

    Sending e-mail through Outlook Express

    Rich I am having a similar problem and I am not sure there is a solution. Outlook Express is set as the default mapi application and for example if I follow an email link in explorer it uses outlook express. However all office apps I have tried ( access, word and excel ) use outlook. I think it...
  19. J

    Simple question about using the expression builder a query

    I dont believe that you can reference a table field in this way. [tblConstants]![VAT] will not return a value as it is not unique ( even if there is only one record at present ). If there is a bound form that has this field as part of the bound table or query then me!VAT will return a value for...
  20. J

    creating PDF's from Access 2003

    I send emails with .snp files attached and not had a problem yet with users not being able to read them.
Back
Top Bottom