Search results

  1. I

    Forms and Subforms

    Hi hhh Your physical data model seems at first sight correct ! But if there is maximum 1 adjustment per tuple (dateID/staffId), merge staffPay and payAdjustments tables. In opposite case, I propose you to change a little bit your scheme as follows: In staffPay table Create a PKT = autonumber...
  2. I

    use one form with mor record source

    Hi Ashabi47 Considering 1st form name form1 2d form named frmNavigation Inside frmNavigation, a navigation object renamed myNavObj To assign dynamically form1 to myNavObj on each page click event, proceed as follows: DoCmd.BrowseTo ObjectType:=acBrowseToForm, _ ObjectName:="form1"...
  3. I

    Help with Database Form

    Hi msharohoney DoCmd.OpenQuery "qryAppendResults" in Private Sub cmdEvaluate_Click() generates an error normal because qryAppendResults has this SQL code : INSERT INTO tblResults ( AreaID, ActivityID ) SELECT [Forms]![frmEvalPartA]![cboArea] AS AreaID, tblActivities.ActivityID FROM...
  4. I

    Update from an excel file - Help appreciated :)

    Hi G1ZmO Modify your code as follows Public Sub insertButton_Click() dim SalePriceColNbr as long SalePriceColNbr = Number for the SalePrice column in Excel worksheet dim SalePrice as double code... While myWorksheet.Cells(r, 1).Value <> "" SalePrice = myWorksheet.Cells(r ...
  5. I

    Key field best practice

    You can also read this post Multiple Primary Keys or Composite Unique Index
  6. I

    Multiple Primary Keys or Composite Unique Index

    hi gemma, my target is to clarify Pk concept. The only meaningful PK is the unique index which singles out each record on a table. And the autonumber PK is only an artefact of the true PK
  7. I

    Multiple Primary Keys or Composite Unique Index

    a comment about the 5 NF and conceptual data model should be more constructive
  8. I

    Multiple Primary Keys or Composite Unique Index

    hi, About PK, I always make a différence between PKT primary key technical for making a link with others tables PKF primary key functional by declaring a unique index composed of fields which single out a record. For exemple considering a table client pkt :idclient = autonumber pkf (unique...
  9. I

    How to Display Intermediate Cumulative Sum By Page Footer

    Hi, On a report, how to display Hi, On a report, how to display Intermediate cumulative sums by page footer, that is, on Page 1, sum of displayed records , page 2, sum of displayed records + Page 1 records , And so on Thanks for your help
  10. I

    Report printing in different orientations

    Hi sphere_monk Try this :eek: Me.Printer.Orientation = acPRORLandscape here for more information
  11. I

    Declaring API functions in 32 or 64 bits

    Hi My Access project must run on 32 bits & 64 bits and uses registry API. So I turned to How To Use the Registry API to Save and Retrieve Setting for inspiration. And for typing my variables considering the environment, I use DefType command. My code in a module is as follows: #If Win64...
  12. I

    Multiple Report Instances :how to Set Focus on particular opened instance

    We need to use BringWindowToTop API windows Declaration on general part module Public Declare Function BringWindowToTop Lib "user32" (ByVal hWnd As Long) As Long In the code -> BringWindowToTop obj.hwnd Thanks to Dirk Goldgar
  13. I

    How to refer with VBA to a sub-report in a form?

    Hi , I have a form with inside a sub-report. In a module, I need to refer to the sub-report but I have no idea how to do? :banghead: Thanks for your help
  14. I

    Multiple Report Instances :how to Set Focus on particular opened instance

    Hi Ranman256, What do you mean? It's not possible to set focus on a report instance ! In any case, for each report instance, there is an item with its Hwnd in my clsReport collection. obj.Visible ' Error 438 corrected => obj.Visible = True/False Any idea about how to to move into the...
  15. I

    Multiple Report Instances :how to Set Focus on particular opened instance

    Hi My problem is to set the focus on a particular Report instance opened . I copy a function which works perfectly for form object but not for Report object. My function: Function mInstanceReportCA(varYear As Variant) Dim oReport As Access.Report Dim obj As Object ' Création du...
  16. I

    INSERT INTO without duplication (AC2007)

    Hi AOB A little advice, create always an auto incremented field which is a technical primary Key (tPK) Then add a unique index composed with the different fields which define your real functional PK (fPK) Then If you try to add a record with existing fields composing your fPK, your insert will...
  17. I

    Running total for a criteria

    Hi ikzouhetnietweten I don't really understand your request, so could you give me example with expected outcome? But for example, in you report, for calculating the record number with Event = In, add a text field with this expression: And you will obtain :23
  18. I

    Sort, group and sort again kind of problem.

    Hi KingBroil Just a question, when an item is back, do you reset the SortiDate = ""? If you do this, it's easy to select the no retrun items SELECT * FROM table WHERE SortiDate = "" could you send a screen capture of your database model and give an example about your need with explicit data?
  19. I

    copy forms and modules from one database to another

    Hi Jaye7 To export forms from an active database, you need to close all opened forms so before calling DoCmd.TransferDatabase acExport, "Microsoft Access", "D:\...\DatabaseTarget.accdb", acForm, "frmActiveDbName", "frmTargetName"add this code Do While Forms.Count > 0 DoCmd.Close...
  20. I

    Variable start of the month query, WHERE IF clause

    Hi thraling, You can call a VBA function from a query. The function must be declared in a module (Warning not in class module !!!) The function will be called for each record of the select query In a module public function functionForSQL (parameter1 as type, parameter2 as type,...) as return...
Back
Top Bottom