Search results

  1. MajP

    Calculated Field Error

    I think the correct statement would be even narrower. Calculated fields in a table support a subset of Access SQL functions and operators. So the \ operator is a Access Sql operator AFAIK, but for some reason not supported. Supposedly Mod is Access Sql and does not work The question is what...
  2. MajP

    Calculated Field Error

    I did check it and it is in the expression builder and does not work. The expression builder is somewhat limited but there are still functions it shows that are not supported.
  3. MajP

    Calculated Field Error

    Table level calculated fields do not support UDFs.
  4. MajP

    Calculated Field Error

    I tested FIX and that works. That should give the same results. Mod does not work either. Also INT works. And since you will always have positive values it is the same as fix, /.
  5. MajP

    Calculated Field Error

    I tested it in the most recent version of Access and get the same issue. Says I cannot use it.
  6. MajP

    Solved Get A Pointer In SubForm To Already Instantiated Class

    I just doubt this design makes any sense If you need a single class as a helper that all subforms can use then in standard module you have a global CA and CB. You can use CA as your factory to build CB. You can make these predeclared as people have been describing. But if you are declaring...
  7. MajP

    Solved Get A Pointer In SubForm To Already Instantiated Class

    Going back to what I said in the first thread. If class A is the only thing holding a reference to class B you have to access it through Class A. But since an instance of A is intantiated in a subform you have to reference A through the subform. I added accessors in class A, but not required...
  8. MajP

    Access subform - Current event does not fire on first record selected

    That is as expected. If you select the first record which is the current record when the form opens then the on current event is not going to happen again when you select the record. You will need another event or another code to capture selecting the current record.
  9. MajP

    Access subform - Current event does not fire on first record selected

    Why? Why not work with the forms recordset if ado or the clone of the forms recordset? But if it is a pass through query it is a dao recordset. Not sure I understand.
  10. MajP

    Solved Get A Pointer In SubForm To Already Instantiated Class

    To be clear there is no such thing as a static class in VBA. When they say that clsErrorHandler in Northwind is static class that is incorrect and misleading. Personally I think they should change the verbiage to a "Pseudo Static Class". In Northwind 2 it states That is incorrect. It is a...
  11. MajP

    Solved Get A Pointer In SubForm To Already Instantiated Class

    If your variable is public in a standard module then yes you should be able to reference directly If your variable is public in a forms module then think of it as a property of the form. The subform needs to reference it through the form that instantiated it. Something like Dim bb as clsB set...
  12. MajP

    How to Properly Query and Search Multi-Valued Fields in a Form?

    @arnelgp example is probably the hardest thing to do and has a lot going on. This demonstrates using an MVF control with a helper table to build a filter for an MVF field. Here is another example that is does the same thing but has several MVF controls to filter several MVF fields (not my...
  13. MajP

    Solved Treeview nodelevel

    I pull those values to format the tree on load. It was less code then a few dlookups. Public Sub FormatTree() With tvw.TreeView .Font.Size = Nz(Me.FontSize, 11) .Font.Name = Nz(Me.FontName, "Calibri") .Indentation = 150 End With 'In the future align these two names...
  14. MajP

    Solved Treeview nodelevel

    It is an easy assumption that a node has a level property. In .net there is a level property of a node, but not in VBA. If you ask Chat it will tell you there is a level property in a vba treeview, but that is wrong. So you have to roll your own function. According to chat. You can simply...
  15. MajP

    Solved Treeview nodelevel

    Here is a simplified demo
  16. MajP

    Solved Treeview nodelevel

    If this is mirroring ItemGenie then Locations can be nested (a box can be inside a cabinet that can be inside the garage). Items cannot be nested or at least that was how it was designed (cannot do fuel tank inside of lawnmower). 1. Determine if it is a location or an item. If item all items...
  17. MajP

    Solved Treeview nodelevel

    I am completely lost. I am showing an image that is 7 levels deep of "headers". Each level has different formatting based on the header level. The tag tells me what type SB, Bill Item, Comment, or Header The node level tells me what level. For headers I use the level in addition to the type...
  18. MajP

    Solved Treeview nodelevel

    Here is image with more header levels Here is more of the format code Public Sub FormatNodes() Dim nd As Node For Each nd In tvw.Nodes FormatNode nd Next nd End Sub ' Public Sub FormatNode(nd As Node) If nd.Tag = "Header_" Then FormatHeader nd ElseIf nd.Tag = "BillItem_"...
  19. MajP

    Solved Treeview nodelevel

    here is the function to return the colors. I pass in the nodelevel determined from the tvw.getNodeLevel and the node type determined from the tvw.getNodeIdentifier. For headers the node level matters. Public Function GetNodeColor(NodeLevel As Integer, nodekey As String, BillID As Long) As Long...
  20. MajP

    Solved Treeview nodelevel

    That is not true there are multiple levels of headers shown. I can have formatting up to 8 levels of headers. Headers are formatted by level. As I said you determine if it is a header and then you use the level to determine the formatting. The other items SB, Comment, Bill item get a constant...
Back
Top Bottom