PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Sun May 09, 2021 5:00 am

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: Fri Jan 29, 2021 7:00 am 
Offline

Joined: Thu Jan 28, 2021 8:29 am
Posts: 6
Hi there

i have set spacebefore in a paragraph but if there more data in first paragraph then its overlap into second paragraph

see the url for the screenshot of my pdf
https://lh3.googleusercontent.com/-VQyA ... -01-28.png

if u see the above image there are two paragraph first one is interview details and second is Applicant details
could you please help?


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 8:17 am 
Offline
PDFsharp Expert
User avatar

Joined: Sat Mar 14, 2015 10:15 am
Posts: 635
Location: CCAA
AnkitB wrote:
if u see the above image there are two paragraph first one is interview details and second is Applicant details
could you please help?
You do not use MigraDoc as intended.
Since you do not share any code I cannot point out what the problem is.
Do you use TextFrames?

_________________
Best regards
Thomas
(Freelance Software Developer with several years of MigraDoc/PDFsharp experience)


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 8:26 am 
Offline

Joined: Thu Jan 28, 2021 8:29 am
Posts: 6
paragraph.AddFormattedText("Interview Instructions : ", TextFormat.Bold);
if (applicantRecord.Notes != null)
{
//paragraph = section.AddParagraph();
paragraph.AddFormattedText(applicantRecord.Notes, TextFormat.NotBold);

}
paragraph.AddLineBreak();
if (applicantRecord.InterViewStatus == false)
{
paragraph.AddFormattedText("Interview Status : " + "UnConfirmed", TextFormat.Bold);
}
else
{
paragraph.AddFormattedText("Interview Status : " + "Confirmed", TextFormat.Bold);
}
paragraph.AddLineBreak();
// Add the print date field
paragraph = section.AddParagraph();
if (applicantRecord.Notes != null)
{
paragraph.Format.SpaceBefore = "10cm";
}
else
{
paragraph.Format.SpaceBefore = "6cm";
}
paragraph.Style = "Heading3";
paragraph.AddFormattedText("Applicant Details", TextFormat.Bold);
paragraph.AddLineBreak();
paragraph.AddLineBreak();


i want dynamic gap between above two paragraph when data eceeds


Attachments:
File comment: u can check the file
Screenshot (168).png
Screenshot (168).png [ 178.26 KiB | Viewed 594 times ]
Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 8:55 am 
Offline
PDFsharp Expert
User avatar

Joined: Sat Mar 14, 2015 10:15 am
Posts: 635
Location: CCAA
I only see code snippets.
Could be a bug, could be a feature - cannot tell with just snippets.

An MDDDL file could help. Or maybe use the Issue Submission Template.

17000 lines of code in a file? I think my boss wouldn't allow that.

_________________
Best regards
Thomas
(Freelance Software Developer with several years of MigraDoc/PDFsharp experience)


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 9:20 am 
Offline

Joined: Thu Jan 28, 2021 8:29 am
Posts: 6
im not facing issue i need to know how to apply dnamic spacing between two paragraph in migradoc when data gets exceeded??


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 9:25 am 
Offline
PDFsharp Expert
User avatar

Joined: Sat Mar 14, 2015 10:15 am
Posts: 635
Location: CCAA
Text should not overlap when MigraDoc is used correctly.
I cannot tell where you use MigraDoc in an unintended way because I only see a snippet.

Use MigraDoc as intended and text will not overlap.

_________________
Best regards
Thomas
(Freelance Software Developer with several years of MigraDoc/PDFsharp experience)


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 9:44 am 
Offline

Joined: Thu Jan 28, 2021 8:29 am
Posts: 6
ok but can you atleast tell me how to make a hyperlink in migradoc pdf to open in next tab?
var furl = "http://google.com;
var h1 = paragraph.AddHyperlink(furl, HyperlinkType.Web);


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group