First of all.. You should consider Forum Rule #1) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered.
I suppose since the group title is: "MS EXCEL AND VBA MACROS" then some people may be asking Excel questions, but the majority of people participating in this group do so because: "VBA CODE REQUIRED" Now.. on to your problem. Your assumption that there should be some Excel status variable SOMEWHERE that indicates when Excel must display #### instead of a number is certainly logical. After all, if you change the font (size or type) and sometimes even the zoom factor of the sheet, the cell content display changes to ####, so there MUST be something! But, as far as I know, there is no VBA function (that I am aware of) that can determine this state. I have hundreds of lines of code that are used specifically to determine this "overflow" state. The truth is that whether a cell value can be displayed relies on many factors. The font size and the font and the content itself. Some fonts are "proportional width" fonts.. That is: some characters are "thinner" than others: iiiii takes up less space than OOOOO Some fonts (Courier New) are fixed-width fonts.. That is: all characters are the same width. AND, the same characters and font are WIDER if they are BOLD. So.. what I've done in the past is to create a hidden "helper" column. Making it have the same content as the monitored column. Create a "change" event in which each time the monitored column is changed, the "helper" column is updated (including font selection) and an "autofit" is issued for the column. Then compare the column width of the two columns. If the "helper" column is larger than the monitored column, then the content has "overflowed". This technique is not 100% accurate. Especially since changing the font or font size does not trigger the change event. It WOULD be nice if someone did know of a status code that would indicate an "overflow" condition. It would save me lots of cpu cycles! Paul ----------------------------------------- “Do all the good you can, By all the means you can, In all the ways you can, In all the places you can, At all the times you can, To all the people you can, As long as ever you can.” - John Wesley ----------------------------------------- ________________________________ From: Prashant Pawle <ppawle.ex...@gmail.com> To: excel-macros@googlegroups.com Sent: Sun, November 11, 2012 2:54:25 AM Subject: $$Excel-Macros$$ VBA CODE REQUIRED Dear Team, Need a code for listing cell references from all sheets which have too narrow column width(#####). Sample file attached Regards, Prashant -- Join official facebook page of this forum @ https://www.facebook.com/discussexcel FORUM RULES (1120+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. 6) Jobs posting is not allowed. 7) Sharing copyrighted ebooks/pirated ebooks/their links is not allowed. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. --- You received this message because you are subscribed to the Google Groups "MS EXCEL AND VBA MACROS" group. To post to this group, send email to excel-macros@googlegroups.com. To unsubscribe from this group, send email to excel-macros+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/excel-macros?hl=en. -- Join official facebook page of this forum @ https://www.facebook.com/discussexcel FORUM RULES (1120+ members already BANNED for violation) 1) Use concise, accurate thread titles. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will not get quick attention or may not be answered. 2) Don't post a question in the thread of another member. 3) Don't post questions regarding breaking or bypassing any security measure. 4) Acknowledge the responses you receive, good or bad. 5) Cross-promotion of, or links to, forums competitive to this forum in signatures are prohibited. 6) Jobs posting is not allowed. 7) Sharing copyrighted ebooks/pirated ebooks/their links is not allowed. NOTE : Don't ever post personal or confidential data in a workbook. Forum owners and members are not responsible for any loss. --- You received this message because you are subscribed to the Google Groups "MS EXCEL AND VBA MACROS" group. To post to this group, send email to excel-macros@googlegroups.com. To unsubscribe from this group, send email to excel-macros+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/excel-macros?hl=en.