PasteSite.Com

Recent Pastes

Sign Up!

PasteSite is open to the public, but with limited features. Register to be able to modify access rights, track your pastes and more...

Change the theme

If you prefer reading light text on a dark background to dark text on a light background, then you might want to try the dark theme.

Banjo's Recent Pastes

"Untitled" (C/C++) view

  1. TinyPicUploader uploader = new TinyPicUploader(); // Create a new TinyPic uploader
  2. uploader.SynchronizationContext = System.Threading.SynchronizationContext.Current; // Tell the uploader to resynchronize events with the current thread
  3. // You need to use the Synchronization Context in WPF and WinForms applications if you don't want to manage the cross thread calls yourself
  4.  
  5. UploadTask task = uploader.CreateUploadTask(filename); // Create an upload task for a file.
  6. task.UploadCompleted += (sender, e) => System.Diagnostics.Process.Start(e.InfoPage.ToString()); // If the upload finishes, open the image in a web browser
  7. task.UploadFailed += (sender, e) => MessageBox.Show(e.Error.ToString()); // If the upload fails, show a message box
  8. task.UploadCanceled += (sender, e) => MessageBox.Show("Upload Canceled"); // If the upload is canceled, show a message box
  9. task.Start(); // Start the upload

"Untitled" (Javascript) view

  1. var filter = /^(("[\w-\s]+")|([\w-]+(?:\.[\w-]+)*)|("[\w-\s]+")([\w-]+(?:\.[\w-]+)*))(@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$)|(@\[?((25[0-5]\.|2[0-4][0-9]\.|1[0-9]{2}\.|[0-9]{1,2}\.))((25[0-5]|2[0-4][0-9]|1[0-9]{2}|[0-9]{1,2})\.){2}(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[0-9]{1,2})\]?$)/i;

"Untitled" (Javascript) view

  1. function createRequestObject() {
  2.     var ro;
  3.     var browser = navigator.appName;
  4.     if(browser == "Microsoft Internet Explorer"){
  5.         ro = new ActiveXObject("Microsoft.XMLHTTP");
  6.     }else{
  7.         ro = new XMLHttpRequest();
  8.     }
  9.     return ro;
  10. }

"Untitled" (Plain Text) view

  1. The type initializer for

"Untitled" (C/C++) view

  1. // Create a new Login Box
  2. Login_Box lb = new Login_Box();
  3.  
  4. // Show the box
  5. DialogResult d = lb.ShowDialog(); // Nothing more happens until the login box is closed
  6.  
  7. // Parse the dialog result if needed.
  8. if(d == DialogResult.Ok)
  9. {
  10.   // The loginw worked, do what I want here..

"Re: #16011" (XML) view

  1. <ResourceDictionary
  2.   xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3.   xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" >
  4.  
  5.   <ResourceDictionary.MergedDictionaries>
  6.     <ResourceDictionary Source="Shared.xaml" />
  7.   </ResourceDictionary.MergedDictionaries>
  8.  
  9.   <!-- Focus Visual -->
  10.  

"Re: #16085" (C/C++) view

  1. #include <iostream>
  2. #include <string>
  3.  
  4. int main() {
  5.   std::string name;
  6.   std::cout << "What is your name?\n";
  7.   std::cin >> name;
  8.   std::cout << "Hello " << name << "!\n" << std::endl;
  9.   return 0;
  10. }

"Untitled" (XML) view

  1. <ResourceDictionary
  2.   xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3.   xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" >
  4.  
  5.   <ResourceDictionary.MergedDictionaries>
  6.     <ResourceDictionary Source="Shared.xaml" />
  7.   </ResourceDictionary.MergedDictionaries>
  8.  
  9.   <!-- Focus Visual -->
  10.  

"Untitled" (XML) view

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <Theme>
  3.   <Normal Border="#1785f8" Thickness="0" Opacity="0.7" Foreground="#637275" Start="#f1f5f6" End="#c9d7da" />
  4.   <Selected Border="#1785f8" Thickness="3" Opacity="1" Foreground="#637275" Start="#f1f5f6" End="#c9d7da" />
  5.   <Hover Border="#1785f8" Thickness="0" Opacity="0.9" Foreground="#637275" Start="#f1f5f6" End="#c9d7da" />
  6. </Theme>

"Untitled" (Plain Text) view

  1. - NickServ: This nickname is registered. Please choose a different nickname, or identify via /msg NickServ identify <password>.
  2. - Closing Link: Banjo[213.229.87.11] destiny.uk.eu.binaryirc.net (Killed (destiny.uk.eu.binaryirc.net (Nick Collision)))
  3. ~ Connection closed

« Page: 1, 2, 3, 4.. »