Search results

  1. B

    1 button to delete record from 3 tables

    why not just use a delete query with criteria DoCmd.Runsql("DELETE Table2.Id FROM Table2 WHERE (((table2.Id)=" & me.id & "));")
  2. B

    Delete Qry

    It looks like Jon K has a good way to do what you want. for your future reference you can import excel spreadsheets using the docmd or a macro DoCmd.TransferSpreadsheet acImport, 8, "the table name you want to put the data in", "Your excel file name"l, False, "" the false part of the docmd is...
  3. B

    Exporting data to excel

    try this,add this code after the last docmd Dim XLAddress as string XLAddress = the full path & filename of your excel file FollowHyperlink XLAddress
  4. B

    Delete Qry

    when you import a spreadsheet you have the option of importing the headings,so you can choose not to, which will sort your first problem. then you could run a delete query where Breaklvl=0 as it appears all other Breaklvl=1 on your spreadsheet, or a delete query where isnull([dcode]) as it...
  5. B

    tabular subform

    try this Set QDF = dbs.CreateQueryDef("", "SELECT tblHIBOpsTraining.TrainingArea, tblHIBOpsTraining.ID, tblHIBOpsTraining.FormNo" _ & " " & "FROM tblHIBOpsTraining" _ & " WHERE (((tblHIBOpsTraining.TrainingArea)=" & """" & OpsUTCN & """" & ") And ((tblTraining.id = " & OpsUTCID & ")")
  6. B

    Email From Form with Combo box

    if you are trying to refer to a combo box on a form that is open forms![Selecthandler]![eaddress]
  7. B

    I want to run query based on option group selection.

    post it in the forum,as theres a lot smarter people out there than me.As they say two heads are better than one
  8. B

    I want to run query based on option group selection.

    sorry mate you have lost me your query is what sets the records to return,so to return records based on a control on a form,then you would put that criteria in you query,not in a select case make use of the access help files the #name error-this is straight from access help files #Error? or...
  9. B

    How do I add a record and ComboBox list gets smaller

    dont know what happened there il try it again
  10. B

    I want to run query based on option group selection.

    Jim One thing you may need to check, is to make sure you spell the query names correctly in your code,otherwise you will get a doesnt exist error
  11. B

    I want to run query based on option group selection.

    have a look at this demo,i have used your exact code except for the report name and i get no errors
  12. B

    How do I add a record and ComboBox list gets smaller

    Cindy this may give you some ideas there is no error trapping in the code but its a simple way of doing what you want
  13. B

    Forms popup dependant on user specified dates

    i dont know much about fish but wouldnt different tanks require different maintaince tasks at different intervals,you may need a table for maintance tasks as well
  14. B

    I want to run query based on option group selection.

    why are you opening the query as well as the report? create a code module you do this by selecting the modules tab in the db window select new option compare database option explicit public ChargeEstimate as string close and save the module-call it Globals...
  15. B

    Compile Error

    if sUser is your variable where have you declared it your dlookup doesnt appear to be looking anything up
  16. B

    Altering the Print Preview Layout Of a Query

    in the reports design view select file from the menu bar select page setup set your page and print margins,close and save the changes
  17. B

    Visible property

    i am assuming you are using the click event for the calender to set your date field and then hide the calender you cant hide a control that has the focus therefor to hide the calender set your date field,move the focus to the next control then use the calenders visible property eg...
  18. B

    I want to run query based on option group selection.

    your welcome just make sure the data types match in your querys and report
  19. B

    I want to run query based on option group selection.

    I thought the query that your report is based on makes the calculation? set common field names to use rather than the table field names eg:in the query grid for each query the report will be based on query 1 Mytotal:[price] where [price] is the table field name Myitem:[ItemDescription] etc...
  20. B

    I want to run query based on option group selection.

    declare a global variable for the query name Public MyQueryName as string use the on click event for the button that opens your report Select Case me.Option2.value case 1 MyQueryName="Thenameofyourquery" case 2...
Back
Top Bottom