Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4621538
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T02:42:56+00:00 2026-05-22T02:42:56+00:00

I’m using a simple program that will take tallPDF xml and convert it into

  • 0

I’m using a simple program that will take tallPDF xml and convert it into a PDF view so you know what your looking at. The problem is I’m limited to how many character I can enter. Is this a problem i can correct in the design view of the form or is the primitive in the code because there is very little code?

AGAIN THIS IS NOT MY CODE. I TAKE NO CREDIT FOR IT!

public partial class Form1 : Form
{
    public Form1()
    {
        InitializeComponent();
    }

    private void button1_Click(object sender, EventArgs e)
    {
        try
        {
            // load the XML document template
            System.Xml.XmlDocument documentTemplate = new System.Xml.XmlDocument();
            documentTemplate.LoadXml(txtPDFXML.Text);

            // Setup the document
            TallComponents.PDF.Layout.Document pdf = new TallComponents.PDF.Layout.Document();
            pdf.Read(documentTemplate.DocumentElement);

            // Finally write the PDF document
            webBrowser1.Navigate("about:blank");
            System.IO.FileStream fs = null;
            try
            {
                fs = new System.IO.FileStream(@"Out.pdf", System.IO.FileMode.Create);
            }
            catch
            {
                fs = new System.IO.FileStream(@"Out2.pdf", System.IO.FileMode.Create);
            }

            pdf.Write(fs, false);
            fs.Close();
            fs.Dispose();

            webBrowser1.Navigate(fs.Name);
        }
        catch (Exception ex)
        {
            MessageBox.Show(ex.ToString());
        }
    }
}

This is the form designer.cs

‘partial class Form1
{
///
/// Required designer variable.
///
private System.ComponentModel.IContainer components = null;

    /// <summary>
    /// Clean up any resources being used.
    /// </summary>
    /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
    protected override void Dispose(bool disposing)
    {
        if (disposing && (components != null))
        {
            components.Dispose();
        }
        base.Dispose(disposing);
    }

    #region Windows Form Designer generated code

    /// <summary>
    /// Required method for Designer support - do not modify
    /// the contents of this method with the code editor.
    /// </summary>
    private void InitializeComponent()
    {
        this.splitContainer1 = new System.Windows.Forms.SplitContainer();
        this.txtPDFXML = new System.Windows.Forms.TextBox();
        this.webBrowser1 = new System.Windows.Forms.WebBrowser();
        this.button1 = new System.Windows.Forms.Button();
        ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
        this.splitContainer1.Panel1.SuspendLayout();
        this.splitContainer1.Panel2.SuspendLayout();
        this.splitContainer1.SuspendLayout();
        this.SuspendLayout();
        // 
        // splitContainer1
        // 
        this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill;
        this.splitContainer1.Location = new System.Drawing.Point(0, 0);
        this.splitContainer1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
        this.splitContainer1.Name = "splitContainer1";
        // 
        // splitContainer1.Panel1
        // 
        this.splitContainer1.Panel1.Controls.Add(this.txtPDFXML);
        // 
        // splitContainer1.Panel2
        // 
        this.splitContainer1.Panel2.Controls.Add(this.webBrowser1);
        this.splitContainer1.Size = new System.Drawing.Size(1347, 824);
        this.splitContainer1.SplitterDistance = 693;
        this.splitContainer1.SplitterWidth = 5;
        this.splitContainer1.TabIndex = 0;
        // 
        // txtPDFXML
        // 
        this.txtPDFXML.AcceptsReturn = true;
        this.txtPDFXML.AcceptsTab = true;
        this.txtPDFXML.Dock = System.Windows.Forms.DockStyle.Fill;
        this.txtPDFXML.Location = new System.Drawing.Point(0, 0);
        this.txtPDFXML.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
        this.txtPDFXML.Multiline = true;
        this.txtPDFXML.Name = "txtPDFXML";
        this.txtPDFXML.ScrollBars = System.Windows.Forms.ScrollBars.Both;
        this.txtPDFXML.Size = new System.Drawing.Size(693, 824);
        this.txtPDFXML.TabIndex = 0;
        this.txtPDFXML.WordWrap = false;
        // 
        // webBrowser1
        // 
        this.webBrowser1.Dock = System.Windows.Forms.DockStyle.Fill;
        this.webBrowser1.Location = new System.Drawing.Point(0, 0);
        this.webBrowser1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
        this.webBrowser1.MinimumSize = new System.Drawing.Size(27, 25);
        this.webBrowser1.Name = "webBrowser1";
        this.webBrowser1.Size = new System.Drawing.Size(649, 824);
        this.webBrowser1.TabIndex = 0;
        // 
        // button1
        // 
        this.button1.Dock = System.Windows.Forms.DockStyle.Bottom;
        this.button1.Location = new System.Drawing.Point(0, 824);
        this.button1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
        this.button1.Name = "button1";
        this.button1.Size = new System.Drawing.Size(1347, 28);
        this.button1.TabIndex = 1;
        this.button1.Text = "&View";
        this.button1.UseVisualStyleBackColor = true;
        this.button1.Click += new System.EventHandler(this.button1_Click);
        // 
        // Form1
        // 
        this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
        this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
        this.ClientSize = new System.Drawing.Size(1347, 852);
        this.Controls.Add(this.splitContainer1);
        this.Controls.Add(this.button1);
        this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
        this.Name = "Form1";
        this.Text = "Form1";
        this.splitContainer1.Panel1.ResumeLayout(false);
        this.splitContainer1.Panel1.PerformLayout();
        this.splitContainer1.Panel2.ResumeLayout(false);
        ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit();
        this.splitContainer1.ResumeLayout(false);
        this.ResumeLayout(false);

    }

    #endregion

    private System.Windows.Forms.SplitContainer splitContainer1;
    private System.Windows.Forms.TextBox txtPDFXML;
    private System.Windows.Forms.WebBrowser webBrowser1;
    private System.Windows.Forms.Button button1;
}

}

,

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T02:42:56+00:00Added an answer on May 22, 2026 at 2:42 am

    I stumbled apon a way to lengthen the characters allowed in this notepad style program. I was going to close the question but META informed me that I should post my answer and accept it so others could use it or add to it, etc. So, after looking around in the code and finding nothing that would help I looked at the UI. This included the notepad style window. I clicked on it and looked at the properties to the right hand side. There is a MaxLength property that was set to 3700 which i set to 9999. This increased the ammount of text I was able to input and solved my problem. Again there may have been other ways to do this but this is what I did and it worked out fine.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

No related questions found

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.