Search results

  1. R

    Restriction for choices option form

    Suppose I have two tables and a query: tblCompanies tblClients These are related via a query: qrySortContacts I have a form to add orders. In this form both a customer and a client need to be chosen. I would like to restrict the options for Clients on the basis of the choice for...
  2. R

    Export data of current record to Excel

    Well it now works for me. It was a beginner's mistake. The ID is not a numeric value, but is text. Therefore the code should be: Private Sub Export_Click() Dim db As Database Dim cn As ADODB.Connection Dim strSQL As String Dim pad As String Set cn = New ADODB.Connection...
  3. R

    Export data of current record to Excel

    Changing the SQL statement does not change the outcome. I have now inserted strSQL = "SELECT * INTO Temp " & vbCrLf strSQL = strSQL & "FROM [tblProductions] " & vbCrLf strSQL = strSQL & "WHERE ([ID]=" & Me.[ID] & ");" Dim tmp tmp = InputBox("", "", strSQL)...
  4. R

    Export data of current record to Excel

    I have developed a form from which I would like to export the data to Excel. Of course, this could simply be done by clicking External data > Export > Excel, but then the whole table will be exported. What I would like is that only the data of the current record, so the record I have selected...
  5. R

    Create record for each new record

    Hi, I've created two related tables, that have a one-on-one relationship: Now I would like that when I create a new record in tblProductions, that automatically a new record with the same ID will be created in tblPlanning. Till now, this does not happen, and I guess it is because mostly...
  6. R

    Button to add contact

    I appreciate your effort, but obviously I have not been clear enough;) Therefore, I now have uploaded some pics to explain what I meant. I have two forms: frmAddContact and frmAddCompany: Contacts can only be added to companies that are in the tblCompanies. So when a person form a new...
  7. R

    Button to add contact

    Well, now I have tried to use a subform, but that won't do, because form and subform will be related by CompanyID (a 5 letter abbreviation that serves as primary key). The subform will then only display the contacts that are marked with that CompanyID, however since you're adding the company...
  8. R

    Button to add contact

    Hi, I've designed a form to add companies to a list of companies. Now I would like to have a button on the form "Add contact", so that a new contact person for the added company can be added. The button opens the frmAddContact, in which the person's details can be inserted. However I would...
  9. R

    Hello

    Hello all, I'm relatively new to MS Access and currently I'm working on a database project. I have no experience in working with VBA, but I have little experience in programming in Python since I'm studying Biomedical Engineering at Eindhoven University of Technology. I was hoping to find...
Top Bottom