Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Paste data from excel sheet is not working as expected #319

Open
muzaffartp opened this issue Sep 28, 2023 · 3 comments
Open

Paste data from excel sheet is not working as expected #319

muzaffartp opened this issue Sep 28, 2023 · 3 comments

Comments

@muzaffartp
Copy link

Hello nick-keller!

we are using version 3.6.3 in our application.
I even tried version 4.11.2 but getting same issue.
when we copy data from excel sheet and past it in data sheet it gets change, some extra spaces and break line "\n" added to it.
e.g.:
Copied data from excel: TESTING TESTING12345
Resulted data after paste in data sheet: TESTING TESTING12345 (getting following in prePasteValues function : ['TESTING\n TESTING12345'] ).

getting this behavior only for first value in pasted data if copied multiple columns from excel sheet and if first values length is 20 or greater. e.g.:
Pasted TESTING TESTING will work fine, TESTING TESTING12345 will get changed as TESTING TESTING12345.
and it will work fine if I try to past as plain text or use Ctrl/AppleCtrl + Shift + P for paste data.

@adg-mh
Copy link

adg-mh commented Dec 27, 2023

I ran into this and worked around it by changing the order that the mime types are checked to make text/html the last resort as excel also sends text/plain.

I also noticed that the order the mime types are checked is different if you paste through the context menu vs. ctrl+v

@faseehahmed1
Copy link
Contributor

My PR #331 once approved will fix this 🙂.

@charlymarchiaro
Copy link

I'm using version 4.11.4 and this is still happening. The values I'm copying doesn't have multiple lines, just single spaces.
Please provide at least a workaround because being able to copy from an Excel file is one of the main advantages of this component.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants