Search results

  1. VilaRestal

    Multiple Many-to-Many relationships?

    I think what you want is rename OrgT as OrgContactsT rename its OrgID field as ContactID and join that to the ContactsT.contactID That gives you a many to many between contacts and organisations. Presumably then you don;t need an OrgID field in Contacts. If that field's already got data in it...
  2. VilaRestal

    button that can only be pressed once per record.

    So long as it's not a continuous form then it's straightforward: In the form's current event check whether the record has been reviewed and enable the button if it hasn't, disable it if it has. At the end of the button's click event (perhaps after checking no errors) disable it. Will have to...
  3. VilaRestal

    Nested IIF issue

    Sorry Ken. I took from you saying I don't like the null test as advice not to use it. I wanted to make clear that only in those cases where you want to treat null and zero length string as the same would you do as you said.
  4. VilaRestal

    Nested IIF issue

    Thanks for explaining and sorry for doubting you. I suppose I always assumed everyone adopted dots as radix points since all computer languages adopted it. It must cause confusion like it did here. I don't entirely agree with Ken. Null and zero length strings are not the same and you don't...
  5. VilaRestal

    Nested IIF issue

    OK but code copied would need to be changed? Does , become the line terminator in SQL? I still think as a feature it sucks big time. People with that country setting are forced to use different syntax to everyone else. Does this only happen in Access SQL or are there are other languages that...
  6. VilaRestal

    Access Glitch? subform question

    Does the subform control actually have a subform source object? A silly question perhaps but if it isn't actually assigned to a form that would produce the behaviour you describe. Maybe the control wizard is switched off and you're not used to it not automatically asking these questions.
  7. VilaRestal

    Record Doesn't Delete

    DELETE in SQL doesn't delete a field, it deletes a record, so you don't specify a field to delete. DELETE tblAppealCases.[Letter Reference] FROM tblAppealCases WHERE should be DELETE FROM tblAppealCases WHERE if indeed you do want to delete that record. If you want to 'delete' the value of...
  8. VilaRestal

    Nested IIF issue

    OK I believe you. It sounds horrible. Every other database, every sample code, every help file needs translating to work with your system. If I were you I'd be trying to find out where that setting is and put it back to normal.
  9. VilaRestal

    Nested IIF issue

    The List Separator setting in Regional settings doesn't affect SQL or VBA syntax. And it would be a really bad idea if it did: it would mean all code written on another computer would need to be changed before it would work on yours. I assure you commas separate function arguments in both...
  10. VilaRestal

    GoToRecord onClick

    So this is an unbound Combobox (it must be, Access won't let you change the value of an autonumber field). To do exactly what you want: If the combobox is called ComboBox1 then the code would be Private Sub ComboBox1_AfterUpdate() If Not IsNull(Me.ComboBox1) Then 'We're going to...
  11. VilaRestal

    Nested IIF issue

    That's a new one on me! I was assuming this was a calculated field in query designer because of name: ... (Which, btw, is not a good 'name' for a field because it is a very common property of ... well... everything) In SQL a semicolon means the end of a line. If it's VBA then the whole...
  12. VilaRestal

    Nested IIF issue

    pr2-eugin is right. For what you're trying to do Nz is 1/3 simpler. But the reason yours didn't work is because you're separating the arguments with semicolons. They should be commas.
  13. VilaRestal

    GoToRecord onClick

    Is that the code that's supposed to open the other form? What it should be is something like If Not IsNull(Me.TrackID) Then DoCmd.OpenForm "Form1", , , "TrackID = " & Me.TrackID in the TrackID combobox After Update event sub. However, your phrase "i would like the form that belongs to the...
  14. VilaRestal

    problem with a popup form opened by another popup form

    I'm not sure why it needs to be a pop up if you're opening as a dialog. But anyway I expect the reason will be because the line DoCmd.GoToRecord , , acNewRec isn't specifying a form so you're letting access decide and it seems if it's set to pop up it decides the wrong form. DoCmd.GoToRecord...
  15. VilaRestal

    Cascading Column Combo Boxes and Multiple Field Sources

    Yes indeed. The Row Source can be set to anything depending on anything. You'll have to explain very clearly what the types of row sources would be for what selected in RequestType. You can change the number of columns of the combobox, the columnwidths. If you SELECT eachField AS [Meaningful...
  16. VilaRestal

    Order By property ignored, form ordered by different field

    Not that antique, I don't think that's a new feature. In the form's properties window, the Data tab page, immediately beneath Order By there should be Order By On Load. Ordering the recordset behind the form as ypma suggests is the most reliable way: Change the form's record source (also in...
  17. VilaRestal

    Novice problems with Class Properties and Arrays. Likely syntax.

    What I mean is they are familiar with the function of the established classes. When I see rs.Edit in code (and rs is a standard DAO recordset) I know I know how it behaves and can debug it much more easily. If I see obj.Edit and obj is declared as clsSuperRecordset then I don't know without...
  18. VilaRestal

    another form

    Global variables are declared public in a module and as such are accessible from any other module including form modules. They're not good programming practice for various reasons that don't all completely apply in Access (they're mostly bad practice for truly object oriented and multi-threaded...
  19. VilaRestal

    another form

    If the second form is opened as a dialog then there's two ways: global variables (set their values in the first form and read them in the second) or OpenArgs. You can combine parameters into the one parameter of the OpenArgs with a delimitter and then use the Split function in the Form Open...
  20. VilaRestal

    Run Time Error: 91

    Well the version you uploaded on mine crashes (fully kills Access - illegal operation) on the line varNodes.Open in this part of the AddNodes sub: 'Test for the type and validity of the source Select Case True Case TypeOf varSource Is ADODB.Recordset, TypeOf varSource...
Back
Top Bottom