+ Reply to Thread
Results 1 to 8 of 8

Header being sorted

  1. #1
    Registered User
    Join Date
    09-26-2017
    Location
    Mesa
    MS-Off Ver
    2010
    Posts
    7

    Header being sorted

    Hi - I'm new to this so....

    I created a function to sort 2 columns in my excel file - col G (which is numbers) and then col A (which is text)...it works great EXPECT it is also sorting the Header column...and I cant figure out why...what am I missing?

    sample of my code

    Please Login or Register  to view this content.
    thanks!
    Last edited by witpa; 10-18-2017 at 09:52 AM.

  2. #2
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Header being sorted

    Hi witpa,

    Could you first edit your post above and select your code and click on the "#" icon which will put your code in code tags and display correctly.

    Then:
    Read:
    http://excel-ask.blogspot.com/2012/1...od-in-vba.html
    notice the section on Headers.
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  3. #3
    Registered User
    Join Date
    09-26-2017
    Location
    Mesa
    MS-Off Ver
    2010
    Posts
    7

    Re: Header being sorted

    Sorry, that suggestion did not work in a FUNCTION...

    I need to modify the code I have, and not use a MACRO within the excel spreadsheet as this function will be called from a UFT script.

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Header being sorted

    Hi witpa,

    What is a "UFT script"?
    Is your problem still active if you can't use Excel VBA like your example above? Do you still need some help with this question?

  5. #5
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Header being sorted

    If "UFT" means UDF (user-defined function, a function invoked via formula), that's not going to work. A UDF can't operate on (i.e., make changes to) another workbook
    Entia non sunt multiplicanda sine necessitate

  6. #6
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: Header being sorted

    Hi,

    I believe the correct line would be
    Please Login or Register  to view this content.
    Don
    Please remember to mark your thread 'Solved' when appropriate.

  7. #7
    Registered User
    Join Date
    09-26-2017
    Location
    Mesa
    MS-Off Ver
    2010
    Posts
    7

    Re: Header being sorted

    UFT is HP's Unified Functional Test, a software testing tool.
    UFT uses excel worksheets - they are imported in and exported out of the tool...

    When the line of
    Please Login or Register  to view this content.
    was replaced with what was suggested in the article:
    Please Login or Register  to view this content.
    I got a syntax error in the function

  8. #8
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Header being sorted

    What's the point of creating another instance of Excel to do this, rather than opening the file in the current instance?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Helped needed to index match row header, column header, and sheet
    By vw103604 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-15-2016, 12:37 PM
  2. [SOLVED] Extract a non-sorted list with blank cells into a sorted list
    By RJK in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 05-08-2015, 12:41 AM
  3. Replies: 2
    Last Post: 03-07-2015, 08:17 PM
  4. Replies: 1
    Last Post: 03-06-2015, 09:54 PM
  5. Replies: 0
    Last Post: 03-06-2015, 03:07 PM
  6. Replies: 0
    Last Post: 03-06-2015, 12:43 PM
  7. [SOLVED] Create sheets named by header and populate them with sorted data
    By salaso69 in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 02-16-2013, 03:47 PM

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