• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

page breaks being removed after importing table

New Here ,
Jun 01, 2015 Jun 01, 2015

Copy link to clipboard

Copied

Hello,

I am importing tables into a document on open. I have multiple tables, and each time the document is opened the tables are reimported from directory.

The problem is that the page breaks, which sit between the paragraphs containing the tables are also being removed and I need them to stay.

I have tried the following in the import params>

  i=GetPropIndex(importParams,Constants.FS_FormatImportedText);

   importParams.propVal.ival=1;

   i=GetPropIndex(importParams,Constants.FS_RemoveManualPageBreaks);

   importParams.propVal.ival=0;

but this doesn't seem to be working.

Any help appreciated.

Thanks!

Tracey

TOPICS
Scripting

Views

320

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
community guidelines
Community Expert ,
Jun 02, 2015 Jun 02, 2015

Copy link to clipboard

Copied

Hi Tracey, Can you post more of the import code so I can try it out here? Thanks. -Rick

Votes

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
community guidelines
New Here ,
Jun 11, 2015 Jun 11, 2015

Copy link to clipboard

Copied

Hi Rick,

These are what I have set currently>

  //and reimport the matching table filename

                        var importParams = GetImportDefaultParams();

                       i=GetPropIndex(importParams,Constants.FS_ImportAsType);

                        importParams.propVal.ival=Constants.FV_TYPE_XML;

                         i=GetPropIndex(importParams,Constants.FS_FileIsXmlDoc);

                        importParams.propVal.ival=Constants.FV_DoOK;

                        i=GetPropIndex(importParams,Constants.FS_AlertUserAboutFailure);

                        importParams.propVal.ival=0;

                         i=GetPropIndex(importParams,Constants.FS_DontNotifyAPIClients);

                        importParams.propVal.ival=1;

                   //     i=GetPropIndex(importParams,Constants.FS_FormatImportedText);

                 //       importParams.propVal.ival=1;

                //        i=GetPropIndex(importParams,Constants.FS_RemoveManualPageBreaks);

                 //       importParams.propVal.ival="False";

                        i=GetPropIndex(importParams,Constants.FS_HowToImport);

                        importParams.propVal.ival=Constants.FV_DoByCopy;

                        var returnParams = new PropVals() ;          

                        //add notification for user response to trigger set_shading

                        Notification(Constants.FA_Note_BackToUser,  true);

             doc.Import (doc.TextSelection.end , filename, importParams, returnParams);  

I seem to recall testing this at some point and it being ok, but now it is not working... pretty sure nothing much changed here?

Thanks!

Votes

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
community guidelines
Community Expert ,
Jun 12, 2015 Jun 12, 2015

Copy link to clipboard

Copied

LATEST

I don't see anything that looks like it would be a problem. One possibility is to store the paragraph's Start setting before you reimport the table. Then after the import, reapply the setting to the paragraph.

Votes

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
community guidelines