| |

VerySource

 Forgot password?
 Register
Search
View: 46|Reply: 3

happy New Year everyone! I have a question about excel automatic page changing, I would like to ask you. . .

[Copy link]

1

Threads

2

Posts

3

Credits

Newbie

Rank: 1

Credits
3

 China

Post time: 2020-1-19 23:00:02
| Show all posts |Read mode
I am working on a project that uses VC ++ to control excel documents. The settings of the pages are controlled by the parameters in the INI file, that is, they are all variable. Excel will automatically change pages according to the set paper size, header, footer, line height, etc. So how do I know the number of lines per page after excel auto-coordinate in programming? ? Unlimited languages, vb, vc, c # and so on. Hope to provide an interface. Thank you!
Reply

Use magic Report

0

Threads

1

Posts

2

Credits

Newbie

Rank: 1

Credits
2

 China

Post time: 2020-3-19 10:30:02
| Show all posts
Can the program also read the parameters in the ini file?
Reply

Use magic Report

0

Threads

2

Posts

3

Credits

Newbie

Rank: 1

Credits
3

 China

Post time: 2020-4-4 13:15:02
| Show all posts
Each worksheet object has a collection of HPageBreaks, representing all horizontal page breaks.
A HPageBreaks has 0 to n HPageBreak.
Each HPageBreak has a location attribute (a Range object), which is the cell in the first column of the row below the page break.
Each Range object has a row property. It represents the row number of the cell in the upper left corner of the range object.
Reply

Use magic Report

1

Threads

2

Posts

3

Credits

Newbie

Rank: 1

Credits
3

 China

 Author| Post time: 2020-4-27 18:45:02
| Show all posts
Thank youqvbcvb, what you said is exactly what we want users to allow.
Thank youzhilang, what you said is our final plan.

After the unremitting efforts of the project team, I finally found a sentence:
mExcelApp.ExecuteExcel4Macro ("Get.Document (64)")

(CApplication mExcelApp; // Application object of Excel)

The above is implemented under the VC ++ MFC project.
Reply

Use magic Report

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

Points Rules

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

Quick Reply To Top Return to the list