Highlighted

RH find/replace in html randomly breaks lines in code.

Community Beginner ,
Nov 27, 2018

Copy link to clipboard

Copied

Hi,

I frequently do find and replace operations in my html code in RoboHelp. I have noticed that when I do a find and replace in the code for all files in a folder, RH sometimes breaks lines randomly, which creates an error. For example, it may change:

     </tr>

to

     </

tr>

This type of error is revealed only when the topic is displayed in the browser after output is generated (previewed topic looks ok).

It also sometimes breaks url's:

      "../../folder1/folder2/folder3/filename.html"

becomes

     "../../folder1/

folder2/folder3/filename.html"

These errors show up as broken links in the project pane.

This may happen 3 or 4 times in a few dozen files, ranging in size from 50 - 2500 lines. Most files are fine, but a handful will have 1 or 2 errors. It is time-consuming to find and fix all of these. Validating the files recognizes that there is an error when it involves a tag, but it never takes me to the correct location in the file when I double-click the error in the error list.

The characters that create the new lines are hidden (no way to show CR or LF in the editor) so I have no way of knowing what is being inserted. I also have no way to find these errant new lines.

Has anyone else seen this?

Any help would be appreciated.

Jeanne

Adobe Community Professional
Correct answer by Peter Grainge | Adobe Community Professional

Yes, anyone who has used Find and Replace.

The only answer is to use external find and replace tools that search across lines and maybe allow wild cards. dnGrep is one that I have used.

Create a backup before using. I always recommend creating the backup as a zip file. That prevents you opening it accidentally and working on it before you realise it was the backup. This way you always have a clean backup that can be used to create a new clean copy time after time.


See www.grainge.org for free RoboHelp and Authoring information.

@petergrainge

Topics

HTML

Views

174

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

RH find/replace in html randomly breaks lines in code.

Community Beginner ,
Nov 27, 2018

Copy link to clipboard

Copied

Hi,

I frequently do find and replace operations in my html code in RoboHelp. I have noticed that when I do a find and replace in the code for all files in a folder, RH sometimes breaks lines randomly, which creates an error. For example, it may change:

     </tr>

to

     </

tr>

This type of error is revealed only when the topic is displayed in the browser after output is generated (previewed topic looks ok).

It also sometimes breaks url's:

      "../../folder1/folder2/folder3/filename.html"

becomes

     "../../folder1/

folder2/folder3/filename.html"

These errors show up as broken links in the project pane.

This may happen 3 or 4 times in a few dozen files, ranging in size from 50 - 2500 lines. Most files are fine, but a handful will have 1 or 2 errors. It is time-consuming to find and fix all of these. Validating the files recognizes that there is an error when it involves a tag, but it never takes me to the correct location in the file when I double-click the error in the error list.

The characters that create the new lines are hidden (no way to show CR or LF in the editor) so I have no way of knowing what is being inserted. I also have no way to find these errant new lines.

Has anyone else seen this?

Any help would be appreciated.

Jeanne

Adobe Community Professional
Correct answer by Peter Grainge | Adobe Community Professional

Yes, anyone who has used Find and Replace.

The only answer is to use external find and replace tools that search across lines and maybe allow wild cards. dnGrep is one that I have used.

Create a backup before using. I always recommend creating the backup as a zip file. That prevents you opening it accidentally and working on it before you realise it was the backup. This way you always have a clean backup that can be used to create a new clean copy time after time.


See www.grainge.org for free RoboHelp and Authoring information.

@petergrainge

Topics

HTML

Views

175

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Adobe Community Professional ,
Nov 28, 2018

Copy link to clipboard

Copied

Yes, anyone who has used Find and Replace.

The only answer is to use external find and replace tools that search across lines and maybe allow wild cards. dnGrep is one that I have used.

Create a backup before using. I always recommend creating the backup as a zip file. That prevents you opening it accidentally and working on it before you realise it was the backup. This way you always have a clean backup that can be used to create a new clean copy time after time.


See www.grainge.org for free RoboHelp and Authoring information.

@petergrainge

www.grainge.org for free RoboHelp & Authoring info. Use the blue Reply button at the top to help me help you.
The black Reply link nests replies and they sort out of order.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Community Beginner ,
Nov 28, 2018

Copy link to clipboard

Copied

Thanks Peter. I have a very old find and replace tool that still works, so I do use that for multi-line and wildcard operations. Unfortunate that Adobe has not seen fit to fix this as it renders that feature unusable in some cases. (It does work a lot of the time - just unpredictable as to when it will fail...)

I'll put a request in the bug database.

Jeanne

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...