In Pb, the cross-column header creation method is used in the data window in the form of grid.

Source: Internet
Author: User
Tags transparent color

In the Pb data window, there is a grid data window, because you can drag the column width, inProgramIs widely used, but there are a lot of inconvenience in the production of Chinese-style reports, so the general programmer is "Love and hate ". Next, after finding out how to create a cross-Column Title header, the title header can change with the column width, which is very convenient. The result is shown in:

The procedure is as follows:
1. Add a text file and select the background color as a non-transparent color. Select layer in position and foreground to drag the column width.
2. In the width of the position attribute tab, click the small button on the right to display the dialog box that defines its width. EnterLong (describe ("ck_je_t.x") + long (describe ("ck_je_t.width")-long (describe ("ck_sl_t.x "))Here, the red department is used to explain the dynamic column width of text, that is, the column width is calculated based on the X value of the "amount" column + the width of the "amount" column, and then the X value of the "quantity" column. In this way, when the program is running, you can dynamically set the column width of the "warehouse picking" title bar.
3. then set the text value x. In pb10.5, the small button on the right of the X value is displayed as gray and unavailable. It doesn't matter. Turn it off and find it in the system tree, use Edit source to find it, learn to analyze it, find the added text attribute, add an expression after the default value, and I add"~ Tlong (describe (~ "Ck_sl_t.x ~ "))", Pay attention to the format in which ~ will be used in edit Source ~ T as the separator.
4. Well, let's try. When the program runs, drag the column and the header of the Cross-column header also moves, which completely meets our requirements.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.