Search results

  1. MarkK

    Seeking Elegant Solution for Traversing Control Hierarchy to Find Parent Form

    What matters though is what the control renders as its Parent. I could make a CollectionA and put controls in it, but that doesn't make my CollectionA the Parent of the control.
  2. MarkK

    Seeking Elegant Solution for Traversing Control Hierarchy to Find Parent Form

    Here's my stab at these problems. Both functions recursively crawl up the Control/Page/Tab/Form hierarchy using the Parent property, which all members expose. - The MainForm is the first object that doesn't have a Parent - The ParentForm is the first Access.Form we encounter above the object...
  3. MarkK

    Opening a form in a library and retrieving a returned value

    If your library contains a function that returns a reference to the form, then consumers of your library can manipulate that reference. From a public function in your library, you can return a public class that raises events. That class can open the form, handle that form's events, and then...
  4. MarkK

    The Law Perverted

    Lock him up.
  5. MarkK

    Table relational design (Buyers - Payments - Agents)

    There is every reason to store the commission on the date it is incurred. with the payment or transaction on which it is calculated. Any time a rate is subject to change, like tax or payroll or commission, the amounts calculated using today's rate should be stored in a record with today's date...
  6. MarkK

    Table relational design (Buyers - Payments - Agents)

    Isn't the commission an attribute of the payment? Like, if you already have a payment table that connects buyer and agent, wouldn't it work well to record the commission in a field of the payment table? It occurs on the same date as the payment. It should be linked to the same buyer and agent...
  7. MarkK

    Object Required message not understood

    OffsetPolyline is neither declared, nor assigned a value in the code you posted, but you try to reference it's Coordinate() member.
  8. MarkK

    Opening form move to upper left automatically

    1) I have had unpredictable form sizes before, but not locations. I can solve size problems if I open the form in design view, change the Auto Resize and Auto Center settings and save the form. Then open the form again in design view, and change those settings back. 2) There is an...
  9. MarkK

    Solved Code not save when at runtime

    Hit <Ctrl> + S all the time.
  10. MarkK

    Library ACCDB Calls to Referencing Project Procedures?

    Say I have a class created in the FE based on FE data and the Library know nothing about it, say a cCustomer class with a CreateOrder method that returns a new cOrder instance. And say I want to run cCustomer.CreateOrder from the Library. In this case cCustomer can Implement IAction, which is...
  11. MarkK

    Library ACCDB Calls to Referencing Project Procedures?

    You can define an interface in the Library, and then in the front end, implement that interface with custom functionality. In the library, create a class called IAction that exposes a single method Public Function Execute(Optional dcn as Scripting.Dictionary) as Variant. Now, in clients of...
  12. MarkK

    Squatters have rights. Homeowner arrested

    Is that all you have? Those stories are outrage-engine clickbait. In America you used to be able to buy and sell human beings. The arc of history tends towards justice. If you disagree, you are probably selling something.
  13. MarkK

    Module Import or Export

    If was your programmer, I would ask for the whole system, your FE and your BE. I would then make the requested changes to the FE. Then I would return the FE to you for testing, with an incremented version number, and a description of the changes made under that version number. If you are...
  14. MarkK

    Inserting numeric values into a Table, using SQL : What's the correct VBA code to use in the VALUES part of the code ?

    The difficult and error-prone problem of cobbling together SQL statements in code is why DAO allows you to create and run a temporary QueryDef. Here's a code example... Private Const SQL_INSERT_SCORE As String = _ "INSERT INTO tblTestScores " & _ "( dtTestDate, numScore...
  15. MarkK

    Object Invalid or No Longer Set Error

    You can also do this... Function FieldExists(table As String, field As String) As Boolean On Error Resume Next FieldExists = CurrentDb.TableDefs(table).Fields(field).Name = field End Function I timed them both on a seven column table, looking for the last column in the table, and they are...
  16. MarkK

    Filtering from a multiselect listbox with other filters

    Look at this block of code... If Me.ckPrimaryDiag Then strVisibleColumns = strVisibleColumns & "PrimaryDiag, " If Me.ckSecondaryDiag Then strVisibleColumns = strVisibleColumns & "SecondaryDiag, " If Me.ckDateEntered Then strVisibleColumns = strVisibleColumns & "DateEntered, " If...
  17. MarkK

    List of methods of a class in intellisense - 2

    It may also be important to note in this discussion that the VBA TypeOf operator can distinguish if an object implements an interface. Say you have an Access.Form called Form_Form1 and it implements IKitayamaControls and INavBarHost, then the following code... Dim frm As New Form_Form1...
  18. MarkK

    New line on IF Statement

    You also don't have to compare a boolean to True or False in order to determine if it is True or False, since, as a boolean, it is already True or False. As a result you can do.... Me.Chk1Discipline = Me.Chk2Discipline And Me.Chk3Discipline And Me.Chk4Discipline ...
  19. MarkK

    Pay your bills

    Yes. Understanding national defence spending policies of NATO member states? Just like gym dues. This is what I love about Trump and his followers: They can take complex and nuanced political and economic issues, and frame them so simply, that even an idiot can understand.
  20. MarkK

    Verify a File Path

    To solve this I would just create the path. If you can create it, it is valid. If you can create it, you can delete it.
Top Bottom