Search results

  1. D

    Getting the right criteria

    Maybe it is just because it is the end of a pretty hectic week but I just can't think how to do this. I have a list of contract counterparties (the one side). On the many side we have contracts. Contracts can have a status of "Current" and "Terminated". A counterparty may, for example, have...
  2. D

    Solved Find First and Data Type Mismatch

    I am getting a data type mismatch in a Find First. The line of code is: rst.FindFirst ("[FSPNumber]=" & vblFSPA) I have checked that the field (FSPNumber) is a text field and the variable vblFSPA is declared as a string and the data it stores is from a text field. I am sure I am doing something...
  3. D

    Solved Saving records

    Most of my forms have a save button on them. What I find is that when the user click on the save button and the code executes, Access jumps to the BeforeUpdate event which, as a default, has similar code in it. It jumps when it hits the line in the Save button code which commits the changes to...
  4. D

    BuildCriteria for a multiparameter query

    I am building a filter for a multi parameter query. Users select from the dropdowns and then the code assembles the criteria. I am not seeing the results that I expect. The code is a re-use from other forms where it has worked effectively. Of the three criteria, one assembles properly, one just...
  5. D

    Format DatePart to show the month in words

    I have this: SortByMonth: Format(DatePart("m",[DatePublished]),"mmmm") DatePart gives me a number for the month but I want to show that as a name. The above defaults everything to January so that I get: rather than the words for each of the months. Is there another way to do this?
  6. D

    OpenForm and syntax

    I have the following code to open a form: DoCmd.OpenForm "frmCStdContractPOPIA", acNormal, , "[CVName] = " & vblType & " AND [VersionNumber] = " & vblVersion The variables work fine but it gives a syntax error. It looks right to me. What am I doing wrong?
  7. D

    Multiple criteria in opening form

    I am trying to open a form with multiple criteria. I hae tried various combinations but come up with either syntax errors or type mismatch." DoCmd.OpenForm "frmCStdContractDefaults", , , "[CVName]=" & Me!StandardContract & " And [Version] = '" & Me![Version] & "'" This one gives me a missing...
  8. D

    One to Many Relationships and showing rows as columns

    I have a one to many relationship. One table is Products and the other table is Classifications. Each product has at least one classification but some have two. In a normal query I will link the two tables and get the product information twice and the only difference between the rows will be the...
  9. D

    Solved Indexes and Seek

    I am trying to locate and then delete a record based on two criteria. For this, I understand I need to use Seek. For Seek to work, I need to define an index. When I run the code though I get "Operation not supported by this type of object" when I hit the line that defines the index. The table is...
  10. D

    Referencing subform 2

    I know there are multiple (thousands) of sites that deal with this issue but I can't get any of them to actually work. No matter how I reference a subform 2 I get an error. Basically I have a main form (frmCContractBrowser), a subform (frmAmendmentsListsubfrm) and a sub-sub form of...
  11. D

    Adding numbers

    I have extracted a series of numbers from a list box and now I want to total them and store the result in a variable. When I do this I get 12345 which is just the numbers as extracted (Dim as Integer). How do I get them to actually add them together? I am sure this is simple but I can't see why...
  12. D

    Split database slow when developing

    I have a spit database FE on computers/ BE on shared server. The compiled version works at about the speed I would expect it to but when I am adding features to the FE (which also sometimes means I edit the BE and add new tables or fields) the FE is incredibly slow - opening forms, queries...
  13. D

    Solved Seek issue

    I am trying to get the database to check if a record exists. I am using Seek to do this where the code will pick up the record number from the primary table and search on the related table for that index number (IDContract). The code is: Dim db As DAO.Database Dim rst As DAO.Recordset Dim...
  14. D

    Multiple Reports

    I am working on a database where we are going to have to have a great many reports - at least a few hundred. I can see a looming issue as more reports are developed as to how to handle the criteria selection and generate the report - most reports will have different criteria and will look...
  15. D

    Solved WhereCondition produces blank form

    This should work but it produces a blank form and I just can't see why. I am opening a popup form with additional information by clicking on a CommandButton. The OpenForm line looks like this: DoCmd.OpenForm "frmCOutsourcing", , , WhereCondition:="ContractID = '" & Forms!frmCContractBrowser!ID &...
  16. D

    Replace () truncates a string

    I am using the Replace() function to replace a placeholder in the body of an html email. The function works absolutely fine except that it is truncating the string. The string is a text based URL to a file location on a network folder and the string picks up the URL fine but when the Replace...
  17. D

    Solved HTML and Variables

    I am sending email using HTMLBody. I want to insert variables into the body of the text but the variables don't display. Is it possible to display a variable and what is the syntax, if it is? I have tried <var> & variable & <\var> but it just italicised the name of the variable and didn't...
  18. D

    Hyperlink in Email doesn't work

    I want to email a hyperlink to selected persons. The hyperlink points to a corporate intranet and the only recipients are internal so the email should allow it. The hyperlink is stored in a table as a hyperlink and the code pick it up and puts it in the .html of an email. It all works fine until...
  19. D

    Apparently simple queries which aren't

    I am hoping someone can tell me what I am not seeing here. I have a contract register. In simplistic terms one table tracks the counterparty. Each counterparty has a Current field which has a Yes/No list. There is also a contract table which lists the contracts and which has a one to many...
  20. D

    Solved Convert query to sql programatically

    Is there a reasonably simply way to convert a query to as sql statement and insert that into the rowsource of a listbox programatically? I have several queries for one list box and I swop them out according to the need to look at different information. I want to rather have a sql statement in...
Top Bottom