Search results

  1. stopher

    Get current subform control (container) name

    I still can't see why the OP needs the name of the container. If the OP wants to change the datasource of a sub from the sub then it's me.recordsource. The only reason to need the container is maybe to set the master/child properties (?). Maybe a wrapper class might come in handy.
  2. stopher

    Get current subform control (container) name

    Not sure I understand the problem but here's a couple of comments me.name will give the name of the object that the code is run in. So if you ran this in the Onload event of of subform1 it would give "subform1" as the result. me.parent will refer to a parent control. Edit: Sorry, I see...
  3. stopher

    Greatest common divisor

    Good luck with these... http://www.cut-the-knot.org/blue/Euclid.shtml https://proofwiki.org/wiki/Euclidean_Algorithm
  4. stopher

    Class Design Help: Related Data

    If you are not planning to refer to a saleperson elsewhere in your OOP model then sure you can just have properties in your client class for that sales person. You just need to make sure your accessor methods ensure your salesperson info is consistent e.g. don't simply provide separate methods...
  5. stopher

    Export from Access to formatted Excel worksheet

    Of hand I don't know. I'm not very familiar with sub totals in Excel let alone the object model for them. Suggest you start a new thread if you haven't already.
  6. stopher

    Export from Access to formatted Excel worksheet

    For a new topic or problem I would generally recommend starting a new thread. I suspect new threads will get more people looking and helping for threads with no replies.
  7. stopher

    Export from Access to formatted Excel worksheet

    Take a look here.
  8. stopher

    Export from Access to formatted Excel worksheet

    Take a look at the saveas line. It is saving as an xls file currently. You can add a parameter to save as the file format consistent with your formatting https://msdn.microsoft.com/en-us/library/office/ff841185.aspx
  9. stopher

    Run Event Code Of Another Form

    Sorry, I quote the whole lot but Kens bit got dropped. Oh well :o
  10. stopher

    Run Event Code Of Another Form

    Interesting. I'm guessing that the business market needs a distinction as many businesses simply do not want Access rolled out to the masses. But instead roll it out selectively (if at all). For home use I guess their is no real reason not to included it. May for extra revenue but I'm...
  11. stopher

    Run Event Code Of Another Form

    I got 365 home and it was included when I purchased (on Windows). Also see here: https://products.office.com/en-gb/office-365-home
  12. stopher

    Export from Access to formatted Excel worksheet

    Yes, just add more lines for each field you want. I was too lazy to do them all but just wanted to give you the principle. Well done for figuring it out. Just shout if you need more info.
  13. stopher

    Run Event Code Of Another Form

    Not sure if I understand exactly what you are trying to do but maybe a couple of things might help: - you can reference a parent form in subform code with me.parent. So a subform does not need to know the name of the parent for to reference it - you can pass a form (or subform) as an argument...
  14. stopher

    Export from Access to formatted Excel worksheet

    Here's some code. Make sure you reference the Excel object library. Also note the file locations and file names in this code and change accordingly. Put the template in the location. Public Sub createXLorder(ListReference As String) Dim xlApp As New Excel.Application Dim xlWrkBk As...
  15. stopher

    Document Range Method - Word Object Model

    Try this: Function ParentandChildintoSeparateWordDocs() 'Make sure the name of the recordset is unambigous 'Good practice to reference the actual library Dim rs As DAO.Recordset Dim db As DAO.Database Dim rschild As DAO.Recordset Dim wrdApp As Word.Application Dim wrdDoc As Word.Document...
  16. stopher

    Document Range Method - Word Object Model

    .range in your code is referring to everything in your doc i think: (wrdDoc.range) So each time you loop you are applying wdStyleHeading1 to everything then applying wdStyleHeading2 to the last bit. I think you should apply you formatting to the current selection as you go or maybe use...
  17. stopher

    Crosstab Query - Headers

    You would need to create a new field that creates a string to look like your header i.e if the value is say 15 then the text string value in your new field should be "0:29" etc
  18. stopher

    Crosstab Query - Headers

    Your example suggests you were entering your headings as text i.e. enclosed with quotes. To enter as values, just omit the quotes. SO if you want headings for values 1, 2 and five then simply enter the following in the column headings property: 1,2,5
  19. stopher

    Crosstab Query - Headers

    You either need to enter your headings as values e.g. 29. Or convert your data values to text.
  20. stopher

    Crosstab Query - Headers

    Yes you can do that. Check out the relevant section here.
Back
Top Bottom