Search results

  1. D

    Primary Key Violation in Update Query

    I need to make sure that there are NEVER two records with both the same ScheduleID and SchedulePage in this table. If it can't be done with the primary key this way, can you point me in the right direction for doing this programmatically with VBA? BTW, this is an access interface to SQL tables...
  2. D

    Primary Key Violation in Update Query

    Hey, I am getting a primary key violation when I try to run an update query. My primary key is a combination of two fields, ScheduleID and SchedulePage. That way for each schedule I can only have one Page 1, one Page 2, etc. When I want to insert a page (say a new Page 2), I need to update...
  3. D

    Interleaf data into one field

    This is a pretty sloppy way to do it, so you may want to wait for someone else to chime in, but I would export to excel and perform some manipulations on the data, such as replacing spaces with slashes.
  4. D

    Dynamic Object Frame

    I found something that works well. I have to massage it a bit more for my purposes, but here is the basic code. First you need to create a form that is editable and not locked, with an unbound object frame that is set to a new bitmap object. Name the frame wrdFrame, or some other relevant...
  5. D

    Dynamic Object Frame

    I would like to open a form that shows a word document (or preferably a thumbnail of a word document) in an object frame. The document(s) displayed would need to change based on information on the form, or sent to the form when opened. I would strongly prefer this to be an unbound frame since...
  6. D

    Connect to network folder as different user/logon?

    Here is the code I used, somewhat simplified. It checks to see if there are already connections to the target network drive, removes them, connects under a different user name, moves a file, disconnects, and reconnects the original network drive configuration. Dim objNetwork Dim objDrivePath...
  7. D

    Min/max from secondary table without returning extra rows from primary

    I love you guys:-) Gonna have to take y'all out for a beer sometime.
  8. D

    Min/max from secondary table without returning extra rows from primary

    Hi all, don't know if this is possible, but right now I'm running a query and then performing Dmin/Dmax on each record in the recordset and it's running SLOOOOW. Perhaps if I can get it from a query it would be faster. I have Table-A and Table-B with a one to many relationship. In the Table-A...
  9. D

    Display msgbox if required field is blank

    It looks like it's throwing the error on the if statement. If they can only choose one option from the combo box, you might try just making the action on "After Update". Or instead of -1, do > 0. You can find out for sure. Place a runtime break on the if statement and look at the value of...
  10. D

    Connect to network folder as different user/logon?

    I may have spoken too soon. Let me see if I can find a way around mapping a network drive to the same folder twice.
  11. D

    Connect to network folder as different user/logon?

    This is very very close. Thank you very much for the reply. In my particular case, I'd love to get another alternative though if anyone has one. My problem is that some users are already mapped to the drive as read-only users. When I try to re-map them, it throws an error. Is there any way...
  12. D

    Connect to network folder as different user/logon?

    I need to know how to connect (via vba) to a networked folder on a server using a different logon (which will need to send a username and password). Background: I have scripted the Access db to move files on a network server. The security folks don't want to give full write access to each user...
  13. D

    One to Many - Help

    It looks as though you have too many relationships there. You should only need one relationship to link the tables together unless I am missing something. You can include Contact_ID in the table, and uncheck the output box to keep it from displaying in the query. That way, you'll just display...
  14. D

    Reports not sorting

    I'm a bit lost on your question, but I do want to know, if everything is the same except for one changed criteria, why don't you set that as a variable and have only one query?
  15. D

    Should I use Select First?

    I'm having trouble with a select first query. I'm getting an error saying whichever item follows my select first statement (in this example TariffID) "is not included in the aggregate function." See example. Background is below. SELECT First (SchedulePage) as FirstPage, TariffID...
  16. D

    Complex query sort

    It should look like this. Note the different sort order on the Table of Contents: Category, Name, Page Rates, AA, 1 Rates, AA, 2 Rates, AA, 3 Rates, BB, 1 Rates, BB, 2 Rates, BB, 3 Statements, First, 1 Statements, First, 2 Statements, First, 3 Statements, Second, 1 Statements, Second, 2...
  17. D

    Delete Query

    I believe this will work as well: DoCmd.SetWarnings False DoCmd.RunSQL "SQL Statement Here;" DoCmd.SetWarnings True
  18. D

    SELECT clause with LAST function causing problems

    Can you show the syntax of the query that gives you an error?
  19. D

    Complex query sort

    I need to sort my query in a rather complicated way, and haven't been able to get the examples I've found on here to work. I have the following fields [Category] [Name] [Page] Here is what I need. Where [Category] = "Table of Contents" Sort by [Name], Then by [Page] Descending Else Sort by...
  20. D

    SQL Query syntax giving Access problems

    Thanks FoFa! Man, you have no idea how long I was trying to solve that problem. Next time I'm in Texas I'll have to buy you a beer!
Back
Top Bottom