1 Reply Latest reply: Oct 6, 2015 4:22 PM by Petter Skjolden RSS

    Export TextBox object Value to txt file using VB macro

    Amir Kachlon

      Hi all,

       

      I have single value string in a text bix object which I want to export into txt file,

      anyone can help me with syntax?

       

      Thanks alot

       

      Amir

        • Re: Export TextBox object Value to txt file using VB macro
          Petter Skjolden

          You can export the text along with a lot of other properties of the TextBox by doing this:

           

          Sub myExport

            ActiveDocument.GetSheetObject("TX01").WriteXmlPropertiesFile "d:\temp\textbox.xlm"

          End Sub

           

          You will have to pick out the text by finding what is enclosed by <Text> and <v> tags... the XML-file contains hundreds of lines:

           

          <QVObjects>

            <TextObjectProperties>

              <Layout>

          ....

          ....

          .....

                <Text>

                  <v>ABC</v>

                </Text>

           

          .....

          .....