Search results

  1. M

    Remove options on navigation control

    Hello, Is it possible to remove the 'search' and unfiltered' options on a form's navigation control (see image)? Thanks for the help.
  2. M

    Date expression returns 'wrong' value

    Hello, I'm using a DateDiff expression to calculate the difference in hours and minutes between two dates. For example, Start date: 12/07/2017 13:20 End date: 12/07/2017 17:00 will return the correct value '4.4' (4 hours 40 mins). However, the following does not: Start date: 12/07/2017...
  3. M

    Compile Error

    I get a 'Method or data member not found' error message when trying to compile code. The code falls over when it gets to a particular control (txtKARY) at a line which reads: If Me.txtKARY = "47,_ _,+21" Then Me.txtKCD = 0 I'm not sure what the problem is. I know there is a control called...
  4. M

    Recordset is not updateable

    Hello, The problem has only been occurring since yesterday and no changes were made to either table structure or forms (apart from moving one textbox on a form a couple of centimeters). I have two databases, front- and back-end. The two forms in question are based on one table each (table1 and...
  5. M

    Form caption not visible

    Hello, I use some code to write some information into the caption of a form, like so (in form's open event): Me.Caption = "Subject Number: " & Forms!frmperson!txtSubjectNumber & "; Name: " & Forms!frmperson!txtSurname & ", " & Forms!frmperson!txtFirstname This works fine if the form is not...
  6. M

    Subforms, dropdown box and synchronisation

    Hello All, I have a form-subform situation. The subform, which is in datasheet view, contains two dropdown boxes, Country and District (1-n). I want the district dropdown to only display records based on what's selected in the country dropdown. There will only ever be any content in District...
  7. M

    moving from one subform to another

    I have two subforms on a main form. When I move out of the last control of the first subform, I use the following code to move to the first control of the second subform: Forms!frmFMVisit!frmSubFamilyEthnicDetails.SetFocus This is giving me problems in that it appears that moving out of the...
  8. M

    Normalisation Problem?

    Hello All, Here is the situation: A parent can have many relations (maternal- and paternal grandparents, siblings, father and mother and children). Each of these relations can in turn have zero or more medical conditions. Any single medical condition can be assigned to zero or more relations...
  9. M

    Return two dates from one value

    Hello, I'm trying to write a function that will accept an input parameter - Q1, Q2, Q3 or Q4 - and return two dates, a start and end date based on the value of the input parameter. So if the input was Q1, the start date would be '01/01/2013' and the end date '31/03/2013'. I can return one date...
  10. M

    Export to Excel truncates text field

    I use the code below to loop through a recordset and then export every record with a matching practice id to an Excel spreadsheet. The code works fine as it is, except for a minor problem with spreadsheet itself. I've noticed that one of the fields in the Excel file has been truncated to 30...
  11. M

    Create multiple spreadsheets

    Hello, I'm trying to create a series of excel spreadsheets from a recordset object. The recordset contains three records (to test), so I'd like to create three excel spreadsheets. The name of the spreadsheet is comprised of the 'practice' and '.xls'. Effectively, i want to code to loop through...
  12. M

    Sending email

    I have a difficult problem with a database. We have patients from multiple GP Practices. We need to send these practices a report with the results for their patients, say on a monthly basis. There may be up to 80 practices. I think I understand how to, say, send one email containing one...
  13. M

    Datasheet sort

    Hello, I've just noticed that the text-boxes in datasheets in Access 2010 have a down arrow for sorting. Is there a way to remove or disable this feature? TIA.
  14. M

    Export report as .rtf file

    In an Access 2003 db, I'm able to right-click on a report. One of the options that appears is 'Export'. You can then select 'Rich Text Format (*.rtf) in the 'Save as Type' drop-down box of the window that appears. The database that users needed to do this with has now been updated to Office...
  15. M

    Access 2010 views

    Hello All, Have a slight issue when I'm looking at forms (or other objects for that matter). They all appear as a 'tab' in a central pane, so that the navigation pane is on the left, the form/table/report etc in the middle, and the properties pane on the right. I'd like switch to a view where...
  16. M

    Refresh unbound controls

    I have a form with a subform. The subform contains a combo box (bound), from which the user can select a parent. The subform also displays some other data relating to the parent in a number of unbound controls. These get updated when the user selects something from the combo box. If the parent...
  17. M

    Variable datatype

    I have a little bit of code to extract the name and description of each variable in the table I name and results are written into a temporary table (tblTemp). I would also like to extract the data type of each variable, but am stuck as to the VBA designation of this property. Can anyone help...
  18. M

    Requery not working

    I have a form with a list box. The rowsource of this listbox is set to a bit of sql that is run when the form is opened: SELECT BatchDate, Count(BatchDate) AS [No Of Deaths] FROM tblMR515Deaths WHERE StudyCauseOfDeath Is Null AND SCDinICD10 Is Null GROUP BY BatchDate The data in...
  19. M

    Date problems

    I'm developing a Windows Forms app using VS 2008 with a SQL Server 2005 database. I've developed a search where users can search for data by entering one or two criteria. One of these is a date which corresponds to a date field in my database. The user clicks on a button, which feed the...
  20. M

    Extracting parts of string

    I need to extract data from a string into two new variables (called 'NHSNew' and 'NHSOld'). The string is mostly separated by a '/'. Data to the left of the string goes into 'NHSNew' and data to the right into 'NHSOld'. I can do this first part OK as shown below. Data to the left of the '/'...
Top Bottom