Results 1 to 5 of 5

Thread: Automating Spreadsheet Selection

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2017
    Posts
    3

    Automating Spreadsheet Selection

    Can you show me how I can make the sheet selected is based off a list box and a combo box together. This is the best I seen with what I am trying to do.

    Listbox has 2 items which is labeled style.
    Combo is the versions based off that style

    Listbox has Base and uppers... "B" & "U" of sheetname.
    Combo has DD .25, Open...etc

    The idea behind mind is making a cutsheet app based on some xlsx sheets i have made, with formulas that change from one to another. To give amount. ....etc.... I have that done.

    Output should display 3 sheets on one page. Option buttons to select cells of location. 1 2 3. After importing I have to put in data to update with formulas from those sheets.

    OK. Sorry. Let me revert back to the main question. I need to make. The sheet selected. To be a variable? Based off of. First. A list box. Then second a combo box. Which will define the variable? For which sheet to copy over.

  2. #2

    Thread Starter
    New Member
    Join Date
    Jul 2017
    Posts
    3

    Re: Importing data from excel to vb6

    Example of sheet name..."BDD .25" "BOP" "UOP". (base drawer door, base open, upper open). if helps explain.

  3. #3

    Thread Starter
    New Member
    Join Date
    Jul 2017
    Posts
    3

    Re: Importing data from excel to vb6

    Quote Originally Posted by JAMESRTECH-MCSA View Post
    Can you show me how I can make the sheet selected is based off a list box and a combo box together. This is the best I seen with what I am trying to do.

    Listbox has 2 items which is labeled style.
    Combo is the versions based off that style

    Listbox has Base and uppers... "B" & "U" of sheetname.
    Combo has DD .25, Open...etc

    The idea behind mind is making a cutsheet app based on some xlsx sheets i have made, with formulas that change from one to another. To give amount. ....etc.... I have that done.

    Output should display 3 sheets on one page. Option buttons to select cells of location. 1 2 3. After importing I have to put in data to update with formulas from those sheets.

    OK. Sorry. Let me revert back to the main question. I need to make. The sheet selected. To be a variable? Based off of. First. A list box. Then second a combo box. Which will define the variable? For which sheet to copy over.
    Added attachments of excel sheet, and the design view
    Attached Images Attached Images   

  4. #4
    PowerPoster
    Join Date
    Dec 2004
    Posts
    25,618

    Re: Importing data from excel to vb6

    the methods in this thread are for using ADO to connect to excel data, it sounds more like you want to automate excel to work with the excel object model

    see the thread, at the top of the office development forum, on automating MS office applications
    i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
    Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next

    dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part

    come back and mark your original post as resolved if your problem is fixed
    pete

  5. #5
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    39,047

    Re: Automating Spreadsheet Selection

    Since the question seems to be Excel rather than VB6, I moved the posts out to a new thread in the Office Development, which seems more appropriate. The techniques used don't seem to be related to the original thread, as westconn1 noted. If this is incorrect, the thread can be moved again. For the sake of completeness, the original was here (since it was mentioned a couple times):

    http://www.vbforums.com/showthread.p...25#post5194425
    My usual boring signature: Nothing

Posting Permissions

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



Click Here to Expand Forum to Full Width