How to prevent OpenOffice/LibreOffice Calc from changing what you input (data, numbers,…)

旧街凉风 提交于 2019-12-03 05:19:26
Robert Ilbrink

I understand your problem with pasting pure unformatted text. This may be more work than you like (we can try to automate that later) but when I paste data from Notepad, I am prompted with an import screen as you can see below. Select the column header(s) and then select Column type: Text. This should solve your paste/import problem. An alternative is to handle this with an AutoHotKey script.

Oh b.t.w. the @ is the format type for text, just like you have HH for 24 hour or ddd for weekdays...

If you want your input to be interpreted as text and preventing Calc to do fancy (and annoying) things with your input, you have to change the format before entering any value.

  • Select the cells/columns/rows.
  • Right-click 'Format Cells...'
  • Select the tab 'Numbers'
  • In the list 'Category', select 'Text' (the last option)
  • Select the format '@' (it is the only one in this category)
  • Click on 'Ok'

You may need to tweak the 'autocorrect' options as well. Go to 'Tools > Auotcorrect Options...'. Here is a link that may help: https://help.libreoffice.org/Calc/Deactivating_Automatic_Changes

When you are importing, you're given a bunch of options. Select "Quoted field as text" so any text inside quotes is treated as text which is interpreted by LibreOffice as sacred and they do not modify it in the way they they modify something that they identify as number

When you have your data in the clipboard click Edit -> Paste as... in main menu. In next window choose "Paste as text". All your data will be pasted as is.

I initially arrived at this page with a very similar (but not identical) problem. I am posting the solution here for the benefit of those who might be visiting with the same issue.

Every time I would save, close, and then re-open my .XSLX spreadsheet in OpenOffice, it would delete the spaces I had entered in between text. For example:

  • "Did not attend" would become "Didnotattend".
  • "John DOE" would become "JohnDOE", etc.

Specifying "text" (@) as the format (as recommended above) did not help me, unfortunately.

What ultimately did solve it was saving it as an .ODS file instead of .XSLX .

just simply put character ' before the text, '0.1.16 and calc will interprate it as text data

My issue was currency, properly formatted would change to a much larger number if the numbers entered could represent a date; such as 4.22 becoming $42,482. I discovered that adding a trailing zero solved the problem.

I had pasted numbers from another site and it kept coming up with dates. I just messed around and hit the arrow that's on the paste board to give me the option of unformatted text or HTML format. I selected unformatted, a window opened to show me the text I wanted so I pressed o.k.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!