+ Reply to Thread
Results 1 to 7 of 7

Not able to format text and autosums,

  1. #1
    Registered User
    Join Date
    10-10-2010
    Location
    UK
    MS-Off Ver
    Excel 2003
    Posts
    17

    Cool Not able to format text and autosums,

    Hi all,
    I am having problems in formatting the cells after pulling/downloading data from a website.

    The text i download should be in this format
    -594-103
    -543-966

    No matter what i format the cells as (General) etc, the cells just calculate the sum and gives me this.
    -697
    -1509
    But when i click on the actual cell, it shows the contents as
    =-543-966
    =-543-966
    If i delete the "=", it still calculates..
    Is there a way around this please?

    p.s
    If it helps, The code in the data-import is

    WEB
    1
    http://website-address.php

    Selection=AllTables
    Formatting=rtf
    PreFormattedTextToColumns=True
    ConsecutiveDelimitersAsOne=True
    SingleBlockTextImport=False
    DisableDateRecognition=False
    DisableRedirections=False


    Thanks

  2. #2
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Not able to format text and autosums,

    If there are only a few cases, manually precede the string with an apostrope

    e.g.
    '-543-966

    Did you try Format > Text ?
    Last edited by Marcol; 10-28-2010 at 09:40 AM.
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  3. #3
    Registered User
    Join Date
    10-10-2010
    Location
    UK
    MS-Off Ver
    Excel 2003
    Posts
    17

    Cool Re: Not able to format text and autosums,

    Quote Originally Posted by Marcol View Post
    If there are only a few cases, manually precede the string with an apostrope

    e.g.
    '-543-966

    Did you try Format > Text ?
    Hi Marcol, Thanks for response.

    Yea i tried Format "Text", there are several hundred instances so I highlighted the whole column, formatted it to "Text" and find & replaced "=" with apostophe ' ,
    this actually worked for most cases.
    But any of the 2 sets of 3 numbers that actually start with the number "0" ie
    -087-789 or -312-023
    lose the "0" so that i end up with -87-789 or -312-23

    Stange huh

  4. #4
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Not able to format text and autosums,

    Hmmm....?

    I think the damage to these examples is already done at the import stage.

    If you can import your web data to a text editor, then replace the - signs with an unique character, say #, import that file into excel as a text file.

    Then use this
    =SUBSTITUTE(A2,"#","-")

    Copy and PasteSpecial > Values

    This seems to work.
    Last edited by Marcol; 10-28-2010 at 10:40 AM.

  5. #5
    Registered User
    Join Date
    10-10-2010
    Location
    UK
    MS-Off Ver
    Excel 2003
    Posts
    17

    Re: Not able to format text and autosums,

    Quote Originally Posted by Marcol View Post
    Hmmm....?

    I think the damage to these examples is already done at the import stage.

    If you can import your web data to a text editor, then replace the - signs with an unique character, say #, import that file into excel as a text file.

    Then use this
    =SUBSTITUTE(A2,"#","-")

    Copy and PasteSpecial > Values

    This seems to work.
    Hi,
    Yea im trying to find a way to pull data in Text editor, automatic importing from excel is easy to use but as to do it via another way i havent a clue. I need a Word help forum LOL

    I can physically copy n paste it from the site straight into Text editor, replace = with blank as you said then paste it into Excel.

    Thanks for your help

    Stu

  6. #6
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Not able to format text and autosums,

    I don't think that will work.

    Check Post #4 again.

    I think doing as you suggest will just take you back to the start, it does if you use notepad whether you paste from notepad, or import as a .txt file.

    I used this in a text file
    #087#789
    #312#023
    #594#103
    #543#966

    then applied the substitute function

    [EDIT]
    Could you paste a typical table into word and post it?
    Last edited by Marcol; 10-28-2010 at 01:51 PM.

  7. #7
    Registered User
    Join Date
    10-10-2010
    Location
    UK
    MS-Off Ver
    Excel 2003
    Posts
    17

    Re: Not able to format text and autosums,

    Got ya!

    yes i see now, works! easier than before but im unable to change the import options.
    I think its an importing software problem that adds the =- which screws it all up.

    Thanks Marcol

+ 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