+ Reply to Thread
Results 1 to 6 of 6

Populating a report sheet based on imported values on another sheet

Hybrid View

  1. #1
    Forum Expert
    Join Date
    01-03-2006
    Location
    Waikato, New Zealand
    MS-Off Ver
    2010 @ work & 2007 @ home
    Posts
    2,243

    Re: Populating a report sheet based on imported values on another sheet

    hi th3spankst3r,

    When re-developing a process, it is often a good idea to challenge the validity necessity/design of the existing process. For example:
    - does it need to be processed via Excel at all?
    - did you know you can Create Reports in Access?
    (this may provide a valid alternative)

    I don't want to apprear rude, but I have waited for someone else to help you out with this, because, put simply, to a more experienced eye the spreadsheet looks painfully messy ie it is not designed as well as it could be*. My main suggestion for improving the ERO spreadsheet would be to remove the merged cells and to use the Format - Cells - Alignment - Horizontal: "centre across selection" (& tick "Wrap Text") as necessary. A second suggestion is to change your database export so, that when any info is imported into Excel, each header is presented in a separate column & the related data is presented in the rows below.

    *The following link(s) may be quite useful for your coworker (& you) to help with some better practices in spreadsheet design: http://www.eusprig.org/smbp.pdf which can be sourced from http://www.sysmod.com/sslinks.htm

    Quote Originally Posted by th3spankst3r View Post
    I can make simple changes to my db, but due to its complex nature and large size, I'd prefer not to rethink the whole task. If someone can help me out with what I have, I'd GREATLY appreciate it. If you have trouble understanding what it is I'm asking, please ask questions.
    I've only started learning Access in the last 6 weeks & am lucky enough to be working alongside some helpful & knowledgeable people (so my learning is being accelerated) but I don't yet recognise all the possible complexities. However, in your case, I think you will get a better & more robust solution if you change the process as close to the "source" as possible. To help me (us) understand more clearly...
    - Would Access generated "Reports" work for you?
    - does anybody enter data directly into the db?
    (could a form be created for entry into the db - perhaps into a temporary table for review)
    - do people enter comments directly into the Excel sheet or is it initially manually written on a printed page & then transferred to Excel?
    - how is the data "imported" into Excel?
    - Once (if) you change the format to one row for headers (with more columns across the worksheet), can you use an "Append Table" query in Access to add updates to new rows, instead of overwriting the existing information?

    hth
    Rob
    Rob Brockett
    Kiwi in the UK
    Always learning & the best way to learn is to experience...

  2. #2
    Registered User
    Join Date
    04-26-2010
    Location
    In the dark...
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Populating a report sheet based on imported values on another sheet

    Quote Originally Posted by broro183 View Post
    - Would Access generated "Reports" work for you?
    Probably not, because Access has no way of loading/editing "saved reports", and in fact there's only a few ways that I know of to "save" a report without buying software. The most viable of these would be to save them as a PDF. However, you still would not be able to load and edit the PDF from within the database. This is needed to add entries to an ERO.

    Quote Originally Posted by broro183 View Post
    - does anybody enter data directly into the db?
    Yes, in fact, all of the data is input directly into the database forms and manipulated by forms as well. Any additions or changes made to the data in my db is done through forms. The idea is that instead of filling out a paper ERO, a user can click on the "Open ERO" button to open the form for filling out an ERO, which provides a little better description for new Marines who don't know much about EROs in the first place. They input the information, click the "Open" button, and it essentially fills out the ERO for them (by exporting to Excel, and then the functions on the ERO worksheet would pull the data over into the correct format). Then they could simply print the ERO when the work is done as a receipt.

    Editing EROs works the same way, they would specify an ERO number type in the work that they did to the gear, click "Annotate" and it would add an entry to the specified ERO.

    Quote Originally Posted by broro183 View Post
    - do people enter comments directly into the Excel sheet or is it initially manually written on a printed page & then transferred to Excel?
    I think the above quote's response should answer this question, hopefully. Everything will be input into the database. When the repairs are done, that's the only time paper should ever be needed. In the Marine Corps, every piece of gear we have has a record jacket that goes with it, just to provide proof of maintenance history, ownership history, etc. The receipt printed after work is done will go in this record jacket. That, ideally, will be the only paper involved in the maintenance process once my database is implemented.

    Quote Originally Posted by broro183 View Post
    - how is the data "imported" into Excel?
    I have written a function within my database that will export a predetermined set of data to a predetermined set of cells in a predetermined worksheet in a predetermined workbook. So when someone is starting an ERO, the db generates the next available ERO number using another function, and then the ExportToExcel function uses that ERO number to open up the blank ERO workbook, switches to the "Import" worksheet, and then pastes the contents of the recordset (created by the Open ERO form) into the predetermined set of cells (which, for opening a new ERO is row 2) and then adds a header (in row 1). After exporting, it switches to the ERO worksheet and then saves the workbook as the ERO number into a specified folder.

    When someone is editing an ERO, the predetermined workbook that is loaded is the ERO number designated by the user. It loads the workbook, switches to the "Import" worksheet, pastes the recordset (created by the "Annotate" form) into the specified set of cells (for annotations, this is row 4) with a header (row 3). It then switches to the ERO worksheet and saves the workbook.

    When closing an ERO, the same process is followed, except that it prints the ERO worksheet after all exporting and formatting is done.

    Quote Originally Posted by broro183 View Post
    - Once (if) you change the format to one row for headers (with more columns across the worksheet), can you use an "Append Table" query in Access to add updates to new rows, instead of overwriting the existing information?
    I don't believe I'll have a problem with overwriting the existing information. I have to make a small adjustment to function ExportToExcel, so that it checks the population of the row that it is trying to export to, and if it is populated, check the row+2, if not, go ahead and export. This way, new entries are added down below the last entry, and not replacing it. I don't know much about "Append Table" queries, but there's already a query being used to create the recordsets. That query isn't populated until after the user fills out the form and clicks the button, so I'm not sure running another query would be a better way to do it.

    After I make that adjustment to function ExportToExcel, I believe the only problem I will have is how to format the descriptions of work. Essentially I want the function in all of the "Description of Work" cells to say something like "if I am the first cell NOT populated, populate me with the contents of the row that is 2 rows down from that which is populated above me." for instance let's say that J18 is filled, but J19 is not. J18 is using row 4 to populate itself. I want J19 to use row 6, but ONLY if it is the first empty cell in the "Description of Work" range. So J20 would remain empty.

    This sounds confusing when I re-read it, but knowing what I want, it's easy for me to picture it in my mind. Sorry I can't be more descriptive.

  3. #3
    Forum Expert
    Join Date
    01-03-2006
    Location
    Waikato, New Zealand
    MS-Off Ver
    2010 @ work & 2007 @ home
    Posts
    2,243

    Re: Populating a report sheet based on imported values on another sheet

    hi,

    I'm sorry, I don't think it is worth the effort of developing complex formulae in your existing spreadsheet design...

    Mods/others,
    I'm warping the direction of this thread away from Excel Worksheet Functions sub Forum towards the Access Forum & I apologise for that. If the OP is willing, this thread may need to be moved again!


    Quote Originally Posted by th3spankst3r View Post
    ...
    This sounds confusing when I re-read it, but knowing what I want, it's easy for me to picture it in my mind. Sorry I can't be more descriptive.
    It sounds like you have already got the solution in mind. I think you may need to step back & look at this from the start by identifying what the problem is, my understanding is:

    1 You have a database that users update with the aim of minimising printouts.
    2 Interim printed reports are currently needed for initial manual updating.
    3 Final reports are needed for attaching to dispatches.
    4 An electronic record of these final reports needs (?) to be kept.

    Currently...
    a) Some updates occur in the data base.
    b) Info is exported to specific cells in Excel & these specific cells are referenced to try & put the info in the desired format*.
    c) I think (?) a copy of the Excel file is kept as an electronic record.

    My suggestions are made with no regard to your current db setup, but more for ongoing usability:
    *If Excel is to remain in the process, I strongly recommend redesigning your spreadsheet with NO merged cells (see earlier post). To remove complexity I suggest you modify your ExportToExcel function to write directly to the correct cells in the redesigned Excel Template. This shouldn't be too much of a change, as you are already writing to specific cells, and it removes the necessity for some complicated formulae to "align this with that...".
    However, because users are already interacting with the db, I will go a step further & suggest completely removing Excel from the process:

    With that in mind, I think that you can achieve "points 1-4" with Access Reports because:
    - All the information is already within your existing database.
    - I assume, additions to an ERO via your db are stored within (appended to) an existing Access table which can be used as the source for the reports. See here for an explanation of Append queries (this concept is probably hiding within the forms you use).
    - Yes pdf'd Reports can easily be created when necessary. In the mean time, data sits patiently in the Table.
    - With this data already existing, the specific report can be created at any time the push of a button (see below).
    - Unfortunately I'm not experienced enough to provide a solution esp without seeing your existing db design. However, you may be able to add the flexibility to your db yourself by using the ideas in the below links:

    http://www.grbps.com/access4.pdf
    http://www.eggheadcafe.com/software/...ecific-re.aspx
    http://allenbrowne.com/ser-50.html
    http://www.brighthub.com/computing/w...les/42372.aspx
    http://office.microsoft.com/en-us/ac...963181033.aspx

    Try creating a test Access Report using Create - Report Wizard...
    This will give you a starting point & you can then move the controls around in Design or Layout View to achieve the layout you want to see.

    If you need any specific help, can you please upload a zipped version of a stripped out sample database?
    (I think this is legal file type for uploading...?)
    This will allow any of the knowledgable Access guys to whip up a mock form/report without needing to start from scratch, so 1) the solution is more likely to be offered and 2) it will be more specific.


    Rob

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1