| |

VerySource

 Forgot password?
 Register
Search

Follow-up problems after DataGridView is imported into Excel

[Copy link]

0

Threads

5

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-12 12:15:02
| Show all posts
How about you create a template, change the format to text, and then write it in with your original program.
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-12 15:45:01
| Show all posts
worksheet.get_Range(xlApp.Cells[1, 3], xlApp.Cells[10, 3]).NumberFormatLocal = "000000000000";//Set the cell format here for 3 columns and rows 1 to 10 are displayed as 12 digits Numbers, fill in the missing positions with 0
Reply

Use magic Report

2

Threads

8

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 Unknown

 Author| Post time: 2020-8-12 21:45:02
| Show all posts
to:5风随心动

Your method is to call the com method, I am now using stream to read and write. Thank you!
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list