Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: lth
  • Order by date
  1. lth

    order by amount of times something appears in a table

    There's a kind of query called a summary query - if you run Access's Query Wizard you should be able to figure out what to do from there, or you can just push the totals button in the query designer (the greek sigma symbol) and select 'sum' for the 'amount downloaded' field. Cheers K
  2. lth

    Queries

    The simple answer (I don't know if there's a more elegant one) would be: Totals: Iif(IsNull[field1],0,[field1] + Iif(IsNull[field2],0,[field2] + Iif(IsNull[field2],0,[field2]; This *should* work but it's off the top of my head. Look in VBA's help under 'iif' for its correct syntax if not...
  3. lth

    Autoforms in VBA

    Well, I hacked together a solution for myself by poking around on MSDN: Dim RemoteApp As Access.Application Set RemoteApp = CreateObject(&quot;Access.Application&quot;) RemoteApp.OpenCurrentDatabase <filename> RemoteApp.DoCmd.<whatever> RemoteApp.CloseCurrentDatabase...
  4. lth

    Autoforms in VBA

    OK, with a bit of poking around, I now have the following code scrap: docmd.selectobject acQuery, <query name>, true docmd.runcommand accmdnewobjectautoform ...which does what I want. Yay! But, can I get another database (ie not the current open one) to create the form? I guess I'm asking if...
  5. lth

    Autoforms in VBA

    Thanks, I'll give it a go.
  6. lth

    Autoforms in VBA

    Is there any way to use Access's handy autoform creator using either VBA or macros? Because it would be really handy. Thanks Kendrick
  7. lth

    Creating tables in VBA

    Yeah, I just found that out myself. *kicks Access* Thanks a lot :)
  8. lth

    Creating tables in VBA

    mp9 - Investigating your method turns up the following chunk of code: Dim dbs As Database Set dbs = OpenDatabase(CurrentDb) dbs.Execute &quot;CREATE TABLE ThisTable &quot; & &quot;(FirstName CHAR, LastName CHAR);&quot; dbs.Close (Dumb newbie question): Database is not...
  9. lth

    Creating tables in VBA

    Thank you both kindly, I will investigate :)
  10. lth

    Creating tables in VBA

    Hello. I would very much like to be able to create tables in Access's VB, beyond the use of 'runcommand acCmdNewObjectTable', ie. I would like to be able to specify, in VB, the attributes of each field. Is this even possible in Access or should I go use MySQL/C++? Thanks a lot. Kendrick

Part and Inventory Search

Back
Top