vba - Excel adding an ' to the beginning of all my cells (APOSTROPHE being magically added) -


with thisworkbook.sheets("worksheetname").cells.range("a1:a1000000") .formula = formulavariable .value = .value end 

when excel .value=.value adds ' beginning of values. if right click , paste value removes '. problem code extremely efficient , takes less 1 second when try remove ' takes forever load cells.

give try:

sub testit()     formulavariable = "=1+2"     thisworkbook.sheets("worksheetname").cells.range("a1:a1000000")         .clear         .formula = formulavariable         .value = .value     end end sub 

edit

if wish fill cells null then:

sub fillwithnulls()     formulavariable = chr(61) & chr(34) & chr(34)     thisworkbook.sheets("worksheetname").cells.range("a1:a1000000")         .clear         .formula = formulavariable         .value = .value     end end sub 

Comments

Popular posts from this blog

c++ - QTextObjectInterface with Qml TextEdit (QQuickTextEdit) -

javascript - angular ng-required radio button not toggling required off in firefox 33, OK in chrome -

xcode - Swift Playground - Files are not readable -