Search results

  1. M

    A 2013 scrolling marquee

    Woo hoo! Glad to be of assistance. I kicked the marquee script up a bit and tossed it in my main application's "About" screen. I ran into some snag that the Marquee was unable to correctly handle a wider width than the text, or portion of the text. So, FYI if you make the text control's width...
  2. M

    how to run a module?

    You can do one of the following: 1) Wire the button click even to =mySubroutineNameInTheVBAModule and fire the VBA Module subroutine that way 2) You can write a small button click subroutine on the Form Module that calls the code in the VBA module. Doing that you would from the Form editor in...
  3. M

    Delete records from table using VBA

    What is the data type of column StrategyName? I would think it a string data type, thus single quotes are missing around the value being supplied. About error handling, here you go for some reading: Robust VBA Error Handler...
  4. M

    Compare a recordset against a set of rules

    I prefer to code such loops in three methods rather than letting one method keep growing and growing. Also, a bit of the verbosity is due to double checking the adoRS object... such as "adoRS object did not indicate the end, move next, did the adoRS object actually get there? no, rrrr???" If...
  5. M

    Compare a recordset against a set of rules

    Since you mention looping through records, I prefer to use a three method design: Example of SQL SELECT using ADODB.Recordset object to Access FE temp table to scan the FE temp table and perform operations http://www.access-programmers.co.uk/forums/showthread.php?p=1214730 #post1214730 If it...
  6. M

    Annoying visual problem with subform in datasheet/continuous form mode

    You might try decompiling your database... NT Command Script and Documented Steps to Decompile / Compact / Compile an Access DB http://www.access-programmers.co.uk/wiki/index.php/NT_Command_Script_and_Documented_Steps_to_Decompile_/_Compact_/_Compile_an_Access_DB
  7. M

    Compare two textboxes and highlight the differences

    Or rig up functionality to launch UltraCompare! :cool:
  8. M

    Creating an quit program macro with a yes/no message

    You are very welcome, jrod0479.
  9. M

    Return Most Common Value

    That SQL is from Stored Procedures to be executed by a SQL BE DB. Never mind about ISNULL, the rest of the syntax is still valid examples of how to SELECT based on a pick list of supplied values.
  10. M

    Compare two textboxes and highlight the differences

    All right, so you will need to have code to compare a virtual line by line, so a loop breaking the entire string at vbCrLf's, and if a difference is spotted within the virtual lines, then mark that one line red.
  11. M

    how to make insert,update,delete in ms access and vba using function

    I find ADO objects best to work with, when possible. DAO objects when ADO objects will not work in the particular situation. I have worked up some samples here: Example of SQL INSERT / UPDATE using ADODB.Command and ADODB.Parameters objects to Access tables...
  12. M

    Compare two textboxes and highlight the differences

    So is this data all in one string, with vbCrLf characters embedded?
  13. M

    a run once form

    I sort of do this in my apps... I have a "main" form which the autoexec macro starts when the DB opens, once "main" gets done it opens the first form and closes itself. No other form opens form "main" again. Things done in "main" need to be done only once for the entire time the application is...
  14. M

    Return Most Common Value

    Two samples quickly came up... grep is my friend... :cool: AND ISNULL([p].[stocktypeid], -1) IN (-1, 3, 10) --Only consider parts which are NULL/B/P Stocking Type WHERE ISNULL([utoolstatusid], -1) IN (-1, 1, 2) --Only consider parts which are No Tool / Not Quoted / Out forSo first is...
  15. M

    Adding data from Form to Table using VBA

    I have found it helpful to convert ADO VBA code over to Late-Binding style coding. Such is more portable between various ADO versions which may be installed on target computers. The module I coded up was based on ADO 2.8 required constants. For INSERT, you do not supply the key if it is an...
  16. M

    Return Most Common Value

    I would begin by building a SQL SELECT right in the SQL view, SELECT which columns you want returned. Then start by adding criteria to the WHERE clause to eliminate the records you are not interested in. So starting with your first bullet, hopefully that is just multiple possible values for...
  17. M

    Deleting a Temp QueryDef

    Best name the DAO.QueryDef, and delete it by name when you are done with it. Here is sample code of how I make use of DAO.QueryDef objects: Example of DAO.QueryDef objects downloading records from a SQL BE DB via Pass-Through query and populating a FE temp table with them...
  18. M

    one on_click function for more than one control

    Sure, implement your own new custom event on the form, and place in each of the control's events 1 LOC to forward that event to your custom event. Example: 'Record double-click behavior Private Sub fldid_DblClick(Cancel As Integer) Call Me.PartEdit_Click End Sub Private Sub...
  19. M

    Adding data from Form to Table using VBA

    Looks like you did not heed the blue note I added to the bottom of the post you were referencing that linked to an additional VBA Module needed for Late-Binding of the ADO objects. Quickly added the reference, the .CommandType LOC no longer blows up. Looks like you have an excellent start! ;)...
  20. M

    Access 2003 Developed Application Not Running Properly on Access 2007/2010 Runtime

    And here some of those steps are documented: NT Command Script and Documented Steps to Decompile / Compact / Compile an Access DB http://www.access-programmers.co.uk/wiki/index.php/NT_Command_Script_and_Documented_Steps_to_Decompile_/_Compact_/_Compile_an_Access_DB
Back
Top Bottom