Search results

  1. C

    multi-column listbox

    hello, I have a form with a listbox containing columns"ID", "Name", "Surname" User can select multiple rows. Upon clicking OK button, selected rows are inserted into a table. Important part of code behind OK button: For Each i In Combo6.ItemsSelected rst.AddNew rst![ID] =...
  2. C

    Append qry also updating

    Hello, I have a button on my form that inserts a record into a table, filled with the contents of textboxes on that form. It works, but it is also does something strange - more oten than not it also updates one of the existing records with the data from the form (it only updates one of the...
  3. C

    Avoiding duplicate records

    Hello, I have the following piece of code that inserts records into a table using recordsets. It works fine, but i want it to check if the combination of field "Question Number" and "App ID" already exists in my table, and if it does, then skip the row and continue with next one. Set rst =...
  4. C

    If function

    Hello, I've created the following code (not working) testSQL= "SELECT Product FROM ...." If IsNull(DoCmd.RunSQL(testSQL)) Then ... When my SELECT statement returns no rows, I want my If code to be executed. But the syntax above is incorrect. How do I fix it? Thanks in advance
  5. C

    Basic VBA task

    Hello, I'm new to VBA and i need some help with this. I want VBA to scan a certain table column and insert the highest value it finds there into a variable. How do I do that? Any help would be greatly appr.ed
  6. C

    nested loop query

    Taking it back, problem solved by using ultra-simple INSERT INTO...SELECT I'm dumb ------ Hi, I have the following problem: I need to loop INSERT INTO query the following way: I have columns "WeekNumber" and "Weekday" Now I need to pre-create rows for a whole year. It should look this way...
  7. C

    Subdatasheets

    Hello, I'm sorry if this has been already discussed but I've been searching without result. I have a table "A", with table "B" in it as a subdatasheet. Now when i insert a new row into "A", i need a new copy of the table "B" to be created, meaning every row in "A" would have it's private copy...
Back
Top Bottom