<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:media="http://search.yahoo.com/mrss/">
<channel>
<title>ClipboardFusion RSS: Pasting a multi line predefined text in 1 action.</title>
<atom:link href="https://www.clipboardfusion.com/Discussions/RSS/?TopicID=918fa079-d598-46c0-96a0-a7d97f4f9087" rel="self" type="application/rss+xml" />
<link>https://www.clipboardfusion.com/Discussions/RSS/?TopicID=918fa079-d598-46c0-96a0-a7d97f4f9087</link>
<description>ClipboardFusion RSS: Pasting a multi line predefined text in 1 action.</description>
<lastBuildDate>Tue, 09 Jun 2026 22:09:27 GMT</lastBuildDate>
<language>en</language>
<sy:updatePeriod>hourly</sy:updatePeriod>
<sy:updateFrequency>1</sy:updateFrequency>
<generator>https://www.clipboardfusion.com/Discussions/RSS/?TopicID=918fa079-d598-46c0-96a0-a7d97f4f9087</generator>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#15</link>
<pubDate>Wed, 01 Nov 2017 21:32:55 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#15</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Hehe didn't see the edit.
You welcome]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Hehe didn't see the edit.<br/>
You welcome <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-smile.light.svg" alt=":)" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":)" HelpButtonDataAlign="BelowMiddle" />
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#14</link>
<pubDate>Wed, 01 Nov 2017 21:31:32 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#14</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Yes. In my edit, I said I found it as the system time was incorrectly formated. It's been changed now. Never noticed that until now. At work it should be fine.
Thank you for all your help. This will surely excel my skills in C# in the time going forward.]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Yes. In my edit, I said I found it as the system time was incorrectly formated. It's been changed now. Never noticed that until now. At work it should be fine.<br/>
Thank you for all your help. This will surely excel my skills in C# in the time going forward.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#13</link>
<pubDate>Wed, 01 Nov 2017 21:29:21 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#13</guid>
<category>ClipboardFusion</category>
<description><![CDATA[For me it works fine with the changes.
I don't think that is the issue of the code anymore. I highlighted the system time in my image. If you look at the system time in your One Note sheet, it is with ".". I am guessing here but you need to change the time and date display settings from Control ...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
For me it works fine with the changes.<br/>
<br/>
<div class="Image"><a href="https://cdn.pbrd.co/images/GRGv1JG.png" target="_blank" data-fancybox="" data-caption="https://cdn.pbrd.co/images/GRGv1JG.png" HelpButtonData="https://cdn.pbrd.co/images/GRGv1JG.png" HelpButtonDataAlign="BelowMiddle"><img src="https://cdn.pbrd.co/images/GRGv1JG.png" alt="https://cdn.pbrd.co/images/GRGv1JG.png" title=""></a></div><br/>
<br/>
I don't think that is the issue of the code anymore. I highlighted the system time in my image. If you look at the system time in your One Note sheet, it is with ".". I am guessing here but you need to change the time and date display settings from Control Panel-&gt; Region -&gt; Change date, time, or number formats. Again this is a guess, hope it helps.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#12</link>
<pubDate>Wed, 01 Nov 2017 21:23:58 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#12</guid>
<category>ClipboardFusion</category>
<description><![CDATA[After changing to 24 hour clock, and removing the seconds, I get this. Attached
EDIT: Never mind. That was a windows setting. Fixed it.]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
After changing to 24 hour clock, and removing the seconds, I get this. Attached<br/>
<br/>
EDIT: Never mind. That was a windows setting. Fixed it.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#11</link>
<pubDate>Wed, 01 Nov 2017 21:22:01 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#11</guid>
<category>ClipboardFusion</category>
<description><![CDATA[yeh saw your post later.
I get this output when I execute it
Do you get something else?]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
yeh saw your post later. <br/>
<br/>
I get this output when I execute it<br/>
<div class="Image"><a href="https://cdn.pbrd.co/images/GRGsLGk.png" target="_blank" data-fancybox="" data-caption="https://cdn.pbrd.co/images/GRGsLGk.png" HelpButtonData="https://cdn.pbrd.co/images/GRGsLGk.png" HelpButtonDataAlign="BelowMiddle"><img src="https://cdn.pbrd.co/images/GRGsLGk.png" alt="https://cdn.pbrd.co/images/GRGsLGk.png" title=""></a></div><br/>
<br/>
Do you get something else?
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#10</link>
<pubDate>Wed, 01 Nov 2017 21:18:06 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#10</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Same thing I did. hehe. Yea, it works, but I don't use am/pm, I use a 24 hour clock, so I googled it and found that I need to put upper case HH to get 24 hour time. Nice.
Bothers me that the output is with a period as a separator, and not a colon though.
Any idea why that happens?]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Same thing I did. hehe. Yea, it works, but I don't use am/pm, I use a 24 hour clock, so I googled it and found that I need to put upper case HH to get 24 hour time. Nice.<br/>
Bothers me that the output is with a period as a separator, and not a colon though.<br/>
Any idea why that happens?
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#9</link>
<pubDate>Wed, 01 Nov 2017 21:13:00 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#9</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Here is the modified code for time in the title. Also cfmacro file attached for ease of import.
Code
Copy
Select All
using System;
using System.Collections.Generic;
// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Here is the modified code for time in the title. Also cfmacro file attached for ease of import.<br/>
<br/>
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019eae6ef4da76bdb941f6326d6b3a06" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019eae6ef4da76bdb941f6326d6b3a06Js'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019eae6ef4da76bdb941f6326d6b3a06Js" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">using System;
using System.Collections.Generic;

// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when run from the History Menu
// The returned string will be:
//   - Placed directly on the Clipboard
//   - Ignored by ClipboardFusion if it is 'null'

public static class ClipboardFusionHelper
{
    public static string ProcessText(string text)
    {
        //Opens new page in OneNote
        BFS.Input.SendKeys("^({VK_78})");

        //Adds title to the Page
        string TimeTitle = null;
        string CurrentTime = DateTime.Now.ToString("h:mm:ss tt");
        TimeTitle = "Company " + CurrentTime;
        BFS.Clipboard.PasteText(TimeTitle);

        //Sends us to the note field
        BFS.Input.SendKeys("{ENTER}");

        //Nothing changed till here, since you are working with your app

        //Adds 5 separate lines of text separated by a line break
        string MyCustomerInfo = null;

        MyCustomerInfo =  "Customer Number: " + Environment.NewLine + "Customer Name: " + Environment.NewLine + "CI: " 
        + Environment.NewLine + "Ticket: " + Environment.NewLine + "Note: " ;

        BFS.Clipboard.PasteText(MyCustomerInfo);
        return null;
    }
}</pre><textarea id="code019eae6ef4da76bdb941f6326d6b3a06" name="code019eae6ef4da76bdb941f6326d6b3a06" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div>
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#8</link>
<pubDate>Wed, 01 Nov 2017 21:08:25 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#8</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Did the new code work for you?]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Did the new code work for you?
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#7</link>
<pubDate>Wed, 01 Nov 2017 21:07:26 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#7</guid>
<category>ClipboardFusion</category>
<description><![CDATA[I want it to be pasted at the end of my title, so directly after Company.
I changed your code slightly, and it now ends up in the title:
Code
Copy
Select All
using System;
using System.Collections.Generic;
// The 'text' parameter will contain the text from the:
// - Current Clipboard when...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
I want it to be pasted at the end of my title, so directly after Company.<br/>
I changed your code slightly, and it now ends up in the title:<br/>
<br/>
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019eae6ef4ed774bae54a8729e3742fc" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019eae6ef4ed774bae54a8729e3742fcJs'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019eae6ef4ed774bae54a8729e3742fcJs" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">using System;
using System.Collections.Generic;

// The 'text' parameter will contain the text from the:
// - Current Clipboard when run by HotKey
// - History Item when run from the History Menu
// The returned string will be:
// - Placed directly on the Clipboard
// - Ignored by ClipboardFusion if it is 'null'

public static class ClipboardFusionHelper
{
public static string ProcessText(string text)
{
//Opens new page in OneNote
BFS.Input.SendKeys("^({VK_78})");

//Adds title to the Page
string MyTitle = null;
string CurrentTimeofTitle = DateTime.Now.ToString("hh:mm:ss");
MyTitle = "Company " + CurrentTimeofTitle;
BFS.Clipboard.PasteText(MyTitle);

//Sends us to the note field
BFS.Input.SendKeys("{ENTER}");

//Nothing changed till here, since you are working with your app

//Adds 5 separate lines of text separated by a line break
string MyCustomerInfo = null;
string CurrentTimeofCustomer = DateTime.Now.ToString("h:mm:ss tt");

MyCustomerInfo = "Customer Number: " + Environment.NewLine + "Customer Name: " + Environment.NewLine + "CI: " 
+ Environment.NewLine + "Ticket: " + Environment.NewLine + "Customer Contact Time: " + Environment.NewLine +"Note: " ;

BFS.Clipboard.PasteText(MyCustomerInfo);
return null;
}
}</pre><textarea id="code019eae6ef4ed774bae54a8729e3742fc" name="code019eae6ef4ed774bae54a8729e3742fc" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div><br/>
<br/>
The only problems I face now, is that it does not show it with a 24 hour time format, and I get . instead of : as separators.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#6</link>
<pubDate>Wed, 01 Nov 2017 21:05:59 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#6</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Lastly, where do you want the time to be pasted?]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Lastly, where do you want the time to be pasted?
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#5</link>
<pubDate>Wed, 01 Nov 2017 21:05:21 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#5</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Hi Leon
There was a small mistake  Try now
Code
Copy
Select All
using System;
using System.Collections.Generic;
// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when run from the History Menu
// The returned string w...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Hi Leon<br/>
<br/>
There was a small mistake <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-frown.light.svg" alt=":(" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":(" HelpButtonDataAlign="BelowMiddle" /> Try now <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-smile.light.svg" alt=":)" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":)" HelpButtonDataAlign="BelowMiddle" /><br/>
<br/>
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019eae6ef4fd779fbf1553c4e2f2152e" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019eae6ef4fd779fbf1553c4e2f2152eJs'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019eae6ef4fd779fbf1553c4e2f2152eJs" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">using System;
using System.Collections.Generic;

// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when run from the History Menu
// The returned string will be:
//   - Placed directly on the Clipboard
//   - Ignored by ClipboardFusion if it is 'null'

public static class ClipboardFusionHelper
{
    public static string ProcessText(string text)
    {
        //Opens new page in OneNote
        BFS.Input.SendKeys("^({VK_78})");

        //Adds title to the Page
        BFS.Clipboard.PasteText("Company");

        //Sends us to the note field
        BFS.Input.SendKeys("{ENTER}");

        //Nothing changed till here, since you are working with your app

        //Adds 5 separate lines of text separated by a line break
        string MyCustomerInfo = null;
        string CurrentTimeofCustomer = DateTime.Now.ToString("h:mm:ss tt");

        MyCustomerInfo =  "Customer Number: " + Environment.NewLine + "Customer Name: " + Environment.NewLine + "CI: " 
        + Environment.NewLine + "Ticket: " + Environment.NewLine + "Customer Contact Time: " + CurrentTimeofCustomer
        + Environment.NewLine +"Note: " ;

        BFS.Clipboard.PasteText(MyCustomerInfo);
        return null;
    }
}</pre><textarea id="code019eae6ef4fd779fbf1553c4e2f2152e" name="code019eae6ef4fd779fbf1553c4e2f2152e" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div>
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#4</link>
<pubDate>Wed, 01 Nov 2017 19:53:01 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#4</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Thank you guys. I might have made it complicated, but only because this is the first time I have had anything to do with C# or coding.
EDIT: UWK-87: Your changes ended up not working for me.
It created a new pace, and added the title, like I wanted.
But nothing happened with your code. I didn'...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Thank you guys. I might have made it complicated, but only because this is the first time I have had anything to do with C# or coding.<br/>
<br/>
EDIT: UWK-87: Your changes ended up not working for me.<br/>
It created a new pace, and added the title, like I wanted.<br/>
But nothing happened with your code. I didn't get anything after it jumped down from the title.<br/>
<br/>
Thomas Malloch: Thank you. The \n worked like a charm.<br/>
The only thing I need now, is to get the current time in the title, directly behind where it says Company.<br/>
Like I said. I'm new to this coding stuff, so I will probably ask for more advice, but this is really shaping up to be a good replacement.
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#3</link>
<pubDate>Wed, 01 Nov 2017 18:15:12 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#3</guid>
<category>ClipboardFusion</category>
<description><![CDATA[@Leon André Bergman: I think you made it too complex with enter key strokes. Why not keep it simple
P.S: Didn't change the code which was handling your application.
P.P.S: The code also print an extra line with time of customer call
For ease of understanding, I am attaching the cfmacro file wi...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
@Leon André Bergman: I think you made it too complex with enter key strokes. Why not keep it simple <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-smile.light.svg" alt=":)" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":)" HelpButtonDataAlign="BelowMiddle" /><br/>
P.S: Didn't change the code which was handling your application. <br/>
P.P.S: The code also print an extra line with time of customer call<br/>
<br/>
For ease of understanding, I am attaching the cfmacro file with this post. Just import it <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-smile.light.svg" alt=":)" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":)" HelpButtonDataAlign="BelowMiddle" /><br/>
<br/>
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019eae6ef50c75128a89db3d788d12bb" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019eae6ef50c75128a89db3d788d12bbJs'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019eae6ef50c75128a89db3d788d12bbJs" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">using System;
using System.Collections.Generic;

// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when run from the History Menu
// The returned string will be:
//   - Placed directly on the Clipboard
//   - Ignored by ClipboardFusion if it is 'null'

public static class ClipboardFusionHelper
{
public static string ProcessText(string text)
{
//Opens new page in OneNote
BFS.Input.SendKeys("^({VK_78})");

//Adds title to the Page
BFS.Clipboard.PasteText("Company");

//Sends us to the note field
BFS.Input.SendKeys("{ENTER}");

//Nothing changed till here, since you are working with your app

//Adds 5 separate lines of text separated by a line break
string MyCustomerInfo = null;
string CurrentTimeofCustomer = DateTime.Now.ToString("h:mm:ss tt");

MyCustomerInfo =  "Customer Number: " + Environment.NewLine + "Customer Name: " + Environment.NewLine + "CI: " 
+ Environment.NewLine + "Ticket: " + Environment.NewLine + "Customer Contact Time: " + CurrentTimeofCustomer
+ Environment.NewLine +"Note: " ;

return MyCustomerInfo;
}
}</pre><textarea id="code019eae6ef50c75128a89db3d788d12bb" name="code019eae6ef50c75128a89db3d788d12bb" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div>
</div>
]]></content:encoded>
</item>
<item>
<title>RE: Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#2</link>
<pubDate>Wed, 01 Nov 2017 17:55:56 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087#2</guid>
<category>ClipboardFusion</category>
<description><![CDATA[You can easily get ClipboardFusion to paste more than one line at a time by using the "\n" (newline) character in your code. Here's an example:
Code
Copy
Select All
BFS.Clipboard.PasteText("Customer Number: \nCustomer Name: ");
When this pastes, it should look like:
Customer Number:
Custom...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
You can easily get ClipboardFusion to paste more than one line at a time by using the "\n" (newline) character in your code. Here's an example:<br/>
<br/>
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019eae6ef51870718e3978cce5ec7af1" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019eae6ef51870718e3978cce5ec7af1Js'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019eae6ef51870718e3978cce5ec7af1Js" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">BFS.Clipboard.PasteText("Customer Number: \nCustomer Name: ");</pre><textarea id="code019eae6ef51870718e3978cce5ec7af1" name="code019eae6ef51870718e3978cce5ec7af1" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div><br/>
<br/>
When this pastes, it should look like:<br/>
<br/>
Customer Number: <br/>
Customer Name: <br/>
<br/>
I hope this works for you!
</div>
]]></content:encoded>
</item>
<item>
<title>Pasting a multi line predefined text in 1 action.</title>
<link>https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087</link>
<pubDate>Wed, 01 Nov 2017 14:23:43 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/pasting-a-multi-line-predefined-text-in-1-action/?ID=918fa079-d598-46c0-96a0-a7d97f4f9087</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Code
Copy
Select All
using System;
using System.Collections.Generic;
// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when run from the History Menu
// The returned string will be:
//   - Placed directly on the Clipbo...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code019eae6ef5307422b08bf7e0792079b4" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code019eae6ef5307422b08bf7e0792079b4Js'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code019eae6ef5307422b08bf7e0792079b4Js" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%; min-height:75px;">using System;
using System.Collections.Generic;

// The 'text' parameter will contain the text from the:
//   - Current Clipboard when run by HotKey
//   - History Item when run from the History Menu
// The returned string will be:
//   - Placed directly on the Clipboard
//   - Ignored by ClipboardFusion if it is 'null'
public static class ClipboardFusionHelper
{
public static string ProcessText(string text)
{
// your code goes here
//Opens new page in OneNote
BFS.Input.SendKeys("^({VK_78})");
//Adds title to the Page
BFS.Clipboard.PasteText("Company");
//Sends us to the note field
BFS.Input.SendKeys("{ENTER}");
//Adds 5 separate lines of text separated by a line break
BFS.Clipboard.PasteText("Customer Number: ");
BFS.Input.SendKeys("{ENTER}");
BFS.Clipboard.PasteText("Customer Name: ");
BFS.Input.SendKeys("{ENTER}");
BFS.Clipboard.PasteText("CI: ");
BFS.Input.SendKeys("{ENTER}");
BFS.Clipboard.PasteText("Ticket: ");
BFS.Input.SendKeys("{ENTER}");
BFS.Clipboard.PasteText("Note: ");
return text;
}
}</pre><textarea id="code019eae6ef5307422b08bf7e0792079b4" name="code019eae6ef5307422b08bf7e0792079b4" style="position:absolute; top:0; left:-999999px; width:1px; height:1px;"></textarea></div>
</div></div></div><br/>
The above code shows how I put together the macro.<br/>
This opens a new page in onenote, and adds a title, and a list of items I want to have ready for noting down the calling customers information.<br/>
<br/>
This is a slightly slower process than I would like, as it pastes one line, sends the enter, and pastes the next.<br/>
<br/>
Is there a way for me to have it paste all the 5 lines simultaneously?<br/>
<br/>
And in addition, I would like to add a timestamp of what hour and minute the customer called, in the title of the new page. Is there a code to add this? I found that you can search and only paste time or date from the text you copy, but I haven't found if you can add the current time.
</div>
]]></content:encoded>
</item>
</channel>
</rss>