Search results

  1. The Stoat

    How to determine error raised in sub

    My Pleasure :)
  2. The Stoat

    Report in Email body

    Sod that it's late, here's the answer (well most of it!) Public Function getval() As Date Dim Db As DAO.Database Dim Rst As DAO.Recordset Dim QRYdef As DAO.QueryDef Set Db = CurrentDb Set QRYdef = Db.QueryDefs!Q3 ' I had a combo box as the parameter in the query i replace it with [PARAM]...
  3. The Stoat

    Report in Email body

    Hi Kraj, 4 questions.to be clear in my head 1. Is the ("qryMatching_Balance") made up of sub queries? 2. If so do any of them use parameters? 3. Are these parameters based on values in an open form or report? 4. This query will run from the Db window? TS PS Read your PM's
  4. The Stoat

    How to determine error raised in sub

    High Big Jim try this Fup is my function that i deliberatley Fup'd I used the On error resume next in my calling procedure and then when the error occured in my function it evaluated to iserror = true and displayed the msgbox when i correct my function it skipped over the msgbox as hoped...
  5. The Stoat

    I know RunSQL is for action query but is there....

    Hi All, ADO can't be used in 97 and seeing as my db's have to compatible on both 200x and 97 i have to use DAO. Really should spend sometime with ADO as it's so much more like the VBscript stuff i use. Anyway, Kraj, odds on your qry is requesting something maybe a spelling mistake in one of the...
  6. The Stoat

    I know RunSQL is for action query but is there....

    Hi, DAO is simply what i use in Access 2000 as a lot of my work has to be compatible in 97. If your using 97 then you don't need to ref DAO. To be precise you don't need to put DAO.Recordset. If your using 2000 then you could obviously learn ADO(? :D ) instead. The Stoat
  7. The Stoat

    I know RunSQL is for action query but is there....

    Hi, Try this. In Access97 if in 2000 you'll need the Microsoft DAO 3.6 Reference Public Function GetMAX() As Integer Dim Db As DAO.Database Dim Rst As DAO.Recordset Set Db = CurrentDb Set Rst = Db.OpenRecordset("QRY_INTMAX") MsgBox Rst.Fields(0) ' to display result GetMAX = Rst.Fields(0) '...
  8. The Stoat

    Normalisation

    Hi, Def of Second Normal Form (SNF) An entity is said to be in SNF if it is in first normal form and if every non-key attribute is functionally dependant on the unique identifier. Basically this means that the fields within the table relate only to the primary key of that table. As an...
  9. The Stoat

    Normalisation

    Hi Aziz, Interesting. If 2 patients have the same next of kin i.e two daughters of the same Father then strictly speaking you should use a link table, as you have between patient and consultant. In that way if the next of kin details i.e. phone number, changes then you would only need to alter...
  10. The Stoat

    sql INSERT statement..help

    Hi, try this Docmd.Runsql("INSERT INTO template Time VALUES (#" & time & "#);" The Stoat
  11. The Stoat

    Creating Function

    Hi, In a way you have the right idea about the use of functions. There is a good guide to functions in the Access Help and loads of stuff on here. The point i would make regarding your function is that you are simply replacing one line of code with another. Private Sub EnhNameList2_GotFocus()...
  12. The Stoat

    Open webpage help from custom popmenu

    Hello, Found a nice way of creating HTML help files without the need for a help compiler. Basically; 1. Create an .htm(l) file relating to the object/control that you want to display the help for. You can do this in anything from dreamweaver to notepad. 2. Place the files in a folder called...
  13. The Stoat

    Open webpage help from custom popmenu

    Hi all, I've created some test html help pages for my app. I want to allow the user to right hand mouse click on my custom popup menu and jump to the webpage that contains the help for that particular control. I.e. if they RHMC on the Enter Password button it will show them the open internet...
  14. The Stoat

    So what's the secret??

    Hi, Again i can't offer a solution but in the quest to find the problem this may give some answers. On the server (1). Create a new db with a brand new table in 2002. Stick a field in it and import some data from Excel I suggest 65000 rows of 10 digit numbers. (2). Do the same in a new 97db...
  15. The Stoat

    Has update query affected any records

    I couldn't find a way of doing this without to many complictions so i used a temporary querydef. Ce la vie. :rolleyes:
  16. The Stoat

    Has update query affected any records

    Hello, I'm running an SQL update query using docmd.runsql(). I've suppressed the alert using docmd.setwarnings false, but i need to know whether or not the query actually updated any records. Is there a way of doing this without creating a querydef and using the records affected property...
  17. The Stoat

    "OR" criteria in subform link?

    Hi Wayne, I understand what you mean, the problem was that i could not know which field in the child form would relate to which field in the parent form. Put another way , yes i could build an "either or" select query for the child form ( this was my intention) but i needed to link on a field...
  18. The Stoat

    "OR" criteria in subform link?

    I've managed to resolve this problem another way but i would still be interested to hear if anyone can do this. :cool:
  19. The Stoat

    "OR" criteria in subform link?

    Hi, Is it possible to link parent and child forms with an "either or" criteria. I'm currently creating the links and Sql sources for the forms using VBA -hence why this is posted here - but i need to be able to link using one or more fields . As an example i want to display all the records...
  20. The Stoat

    Report in Email body

    Kraj, this should work. Public Sub SendMail() Dim outApp As Outlook.Application Dim outItem As Outlook.MailItem Dim strEMailRec As String 'recipient Dim strEMailTitle As String ' title Dim strEMailMsg As String ' message text Dim Db as Dao.Database Dim Rst as Dao.Recordset ' SET YOUR DB...
Back
Top Bottom