+ Reply to Thread
Results 1 to 9 of 9

Ways Bypass 255 Character String Variable Type Limit

  1. #1
    Registered User
    Join Date
    05-29-2009
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    15

    Ways Bypass 255 Character String Variable Type Limit

    All,

    I occasionally have Users enter a string type variable (named str_RC in my code below) that is longer than 255 characters. I've seen some conflicting google search results saying that they are surprised they are getting cut off and ones that say they are not. Is there a way to by pass this issue?

    i.e. if my user inputted the string below I'm getting issues after "H096".

    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Last edited by rkl303; 01-26-2015 at 01:44 PM.

  2. #2
    Registered User
    Join Date
    05-29-2009
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: Ways Bypass 255 Character String Variable Type Limit

    Bump for some help.

  3. #3
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,626

    Re: Ways Bypass 255 Character String Variable Type Limit

    Where are you getting the issues?
    If posting code please use code tags, see here.

  4. #4
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Ways Bypass 255 Character String Variable Type Limit

    Why are you using Array(RC_Member) when RC_Member is already an array?
    Remember what the dormouse said
    Feed your head

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

    Re: Ways Bypass 255 Character String Variable Type Limit

    Surely people are not typing that long string into the InputBox (which is limited to returning 254 characters)?

    You could create a userform with a textbox.
    Entia non sunt multiplicanda sine necessitate

  6. #6
    Registered User
    Join Date
    05-29-2009
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: Ways Bypass 255 Character String Variable Type Limit

    Nori - my pivot table is not able to filter past the 255th character(s) in the string so the items
    H097, H098, H099, H100, H102, H105, H108, H736, H742, H743, H744, H759, H761, H832, H858, H860, H862, H894, H943, HB01, HB02, HB03, HB04, HB07, HB46, L153"

    Are not showing up in my pivot table

    ----------------------

    RomperStomer - Poor coding as I like to use the macro recorder to figure out how to code things. It works though sadly enough.

    ---------------------

    shg - They could and have tried which is why i am here. I added an "add to" function so they could put the next 255 charcters into my filter.
    Our cube should has a heirarchy that allows them to filter on this specific region's set of RC's which is roughly 500 characters but sadly the tech team didn't design it that way and our budget now for tech support and actual support we have been getting is a joke and so I am resorting to creating macros for this effor.

    I am not familar with userforms at all but from what I am seeing on google I am not sure if I like it. Selecting the ~80 items from a user form seems like the same exact thing as doing it in a pivot table which may have around 500 possiblilties. I guess I could have the user select a different range after selecting which pivot table they want to apply the filter to but that seemed a bit hard to stop 1/4 way through the process to get that information.

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

    Re: Ways Bypass 255 Character String Variable Type Limit

    A textbox on a form would serve only in lieu of the InputBox, as a means of getting a string longer than 254 characters into the code.

  8. #8
    Registered User
    Join Date
    05-29-2009
    Location
    Denver, CO
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: Ways Bypass 255 Character String Variable Type Limit

    Sweet that worked perfectly shg.

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

    Re: Ways Bypass 255 Character String Variable Type Limit

    You're welcome.

+ 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. [SOLVED] SUM of Character CODE in a variable length string
    By Speshul in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-21-2014, 11:56 AM
  2. Trim trailing CR/LF character(s) off of string variable
    By btmtdk in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-04-2014, 11:44 AM
  3. Ways around 255 cell limit?
    By catholicbunny in forum Excel General
    Replies: 3
    Last Post: 06-01-2011, 03:22 PM
  4. Limit character type and length in cell possible?
    By Fidd$ in forum Excel Programming / VBA / Macros
    Replies: 29
    Last Post: 07-01-2010, 04:31 AM
  5. Changing a specific character type in text string
    By cianid in forum Excel General
    Replies: 1
    Last Post: 03-20-2005, 07:35 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