Editing specific cells in Word document header - delphi

I have a Word document and I need to edit specific cells in a header table. I could replace strings, but in this case I need to replace all cell content (and it can vary, so I can not use replacement). I tried this:
dm.WordApp.ActiveDocument.Sections.Item(1).Headers.Item(1).Range.Select; //(accsess header)
dm.WordApp.ActiveDocument.Tables.Item(1).Cell(2,3).select;
but the second command does not access the 2,3 cell of the header table, but the first table in the document body.
Could someone help with this issue? I'm using Delphi 10.2.

Use:
dm.WordApp.ActiveDocument.Sections.Item(1).Headers.Item(1).Range.Tables.Item(1).Cell(2,3).Range

Related

Hyperlink to particular Text in a cell on the same sheet

I'm working with Excel 2010. What I'm trying to accomplish is creating a hyperlink which finds a cell containing some specific text, and simply brings the user to that cell. It would be simple if the cell stayed in the same position in the column, but more data is always being added to that column, and the cell location which contains the text keeps changing.
Although I've seen several articles that I suspect might address the problem, they were so involved that I couldn't be certain they were what I was looking for, since I've been away from this for years, and am relearning it all from scratch.
Thanks for your time and attention.
Say we want to go to "treasure" in column D:
=HYPERLINK("#d" & MATCH("treasure",D:D,0),"jump to treasure")
This can be modified if you did not know which column to search!

Why does copying multi-row text from Google Sheets to the Instagram caption box add a quote mark at the beginning and end of the text?

This may be the most niche question ever but let's try it anyway.
I have a Google Sheets spreadsheet that contains cells with multiple lines of text. Each line of text is separated by a soft break.
As shown below, when I copy the contents of a cell (row 2 in the screenshot) from the Google Sheets app to the Instagram caption box, a quote mark is added to the beginning and end of the caption.
If I copy the contents of a cell and that cell has only a single line of text (row 3 in the screenshot), no quote mark is added.
I am using an iPhone 11 running the latest version of iOS.
The extra quotes are added when there are special characters in the cell. In your scenario, the Line Feed characters are causing this. Definitely annoying.
There is a way around this – using Carriage Return characters, rather than Line Feeds to separate each line. For some reason these characters don’t cause the quotation marks to appear.
One thing you can do in your sheet is to create a helper cell that will take your text, and replace the line feeds with carriage returns (assuming your input text is in cell A2, add this formula to an empty cell):
=SUBSTITUTE(A2,char(10),char(13))
The output for this will look like it doesn’t contain linefeeds, but when you copy & paste from that cell, the linefeeds will be there in the pasted text, without the extra quotation marks.
The quotations are inserted by the target application when non-printable or otherwise incompatible characters appear in the copied text. There are several scenarios in which the quotes don't appear, and several in which they do.
For example in the MacOS Notes application, consider a cell containing either a vertical tab (appearing as a line break in a single cell with a Cmd-Enter on Mac or Cntl-Enter on Windows) or a newline character in a formula such as ="test"&char(10)&"test". When copied and pasted into a record in Notes, the text is copied as is (i.e., as expected). However when pasting into the Notes search box, the quotes appear, such as described in the question.
There appear to be 3 alternative ways to handle this issue:
Strip the non-printable characters with a formula
Using the CLEAN function, the characters will be stripped. This will produce oft undesirable results, but will eliminate the quotes. See the Wrapped in CLEAN column:
Paste elsewhere first
In the Notes example, one can paste the offending text into a Note (or presumably any text editor.) The offending quotes are omitted. The text can then be recopied and repasted without quotes. This will still collapse a line feed into a space:
Publish to Web and copy from there
Publishing a sheet with non-printable characters enables quoteless copy, like the previous option, but may be a preferable. See the test sheet
Copy from the Sample Text column. You can paste without quotes, but the line break is stripped and replaced with a space as above.
this is a common issue. the solution would be to paste your copy into fx bar instead of cell selection. this way you can skip the additional quotes
The easiest of the easiest solution is to copy straight from the cell. Mark the text within the cell instead of marking the whole cell and then copy.
its very easy guys
just follow as i say
step1: type letter in a cell
step2: select logo(A) with 4 dash(-) which is on top
step3: select cell
step4:turn on wrap text
problem solved
if you are using desktop
mac: alt/opttion+enter
windows: alt+enter
you can also select all cell at once then you can select format on menu bar and select text warping and then wrap(this is not recommended as it may destroy your table format)

Not Aligning the data inside a column in pdf generated by using jspdf auto table

I have attached my problem in the below snap , I dont know how to align the data in particular manner inside a column using jspdf-autotable generated pdf.
I have a requirement to show the parent step and child step in a column . so In my code I wrote a logic inside drawCell() for every child step, added 10Spaces and print in pdf.
Inside drawCell() I got cell.text data in the form of array of Strings. I easily added 10 spaces for every string like below
[" String1"," String2"," String3"," TOOLONG STRING dfhdjhdfd..fsdd..."]
If the String is too long some of the letters are hided at the edge of the row ,jspdf tries to place a every string in the same line ,below image shows the problem I am highlighted in that, Please give me some suggestion I am not getting any Idea How to fix it ..Please bear with my English
Try to use the createdCell hook instead of the drawCell hook to add the spaces. It is executed before the width is calculated.

Can I freeze the header row of a fusion table

I've got data from 50 states that I'd like to display in the table format (I've also got it mapped) but the table height is so large that you can't scroll down without losing the header row. Since there's 13 columns with yes/no information, once you lose sight of that row it becomes difficult to understand what you're reading.
I would love to be able to freeze the header row so that data below it can scroll (in both x and y axes). I thought about using an image on top of the table but that doesn't work when the table is wider than the body block.
Here's the table.
You'll note I'm having trouble with column width too, as I can't get that last column to stretch out.
Also, my backup plan is to allow users to simply download the table, but I can't figure out how to set the link to download the table.
Thanks in advance for any help!
Embedded tables use the Google Charts table visualization, which supports a fixed header if you set the height. See the configuration options for details.

Creating multirow table headers

I have a table where my column headers are set with the following instruction :
table.setColumnHeader
I wonder how can I create multilevel table headers like on this page?
As of Vaadin 6.7.3, this is currently not possible using the stock Vaadin table component.
There is a Trac issue raised for changing this for Vaadin 7. See https://vaadin.com/forum/-/message_boards/view_message/900369 for more details.
Depending on your requirements, you could hide the table component's header and try to simulate the header (by using a HorizontalLayout, generating your own headers and listening to column resize events); alternatively, you could simply generate your own HTML <table></table> and assign it to a label component.
In Vaadin7 you can set the table header height dynamically by adding following CSS rule to your theme:
.v-table-header-wrap {
height: auto;
}
The only think is that the column separator is not set to 100% of the header row height ...
A look into the TreeTable component may help you :
Vaadin sampler
Regards,
Éric.
To make a header only of a table use setPageLength(0); this will eliminate the table body and show only the header.
Then create another table with a header and your data and combine these 2 in a layout :)
It's a cool trick, be sure to match the ratio's of first header with the second's table header.

Resources