Advertisement
Guest User

C#: Make and use DLL

a guest
Jul 10th, 2014
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.05 KB | None | 0 0
  1. //MAKING DLL
  2.  
  3. using System;
  4. using System.Collections.Generic;
  5. using System.Linq;
  6. using System.Text;
  7.  
  8. namespace MakeMyDLL
  9. {
  10.     public class graphics //REMEMBER THIS CLASS NAME
  11.     {
  12.         public string Makemydll()
  13.         {
  14.             return ("made my dll");
  15.  
  16.         }
  17.     }
  18. }
  19.  
  20. //USING DLL
  21. using System;
  22. using System.Collections.Generic;
  23. using System.ComponentModel;
  24. using System.Data;
  25. using System.Drawing;
  26. using System.Linq;
  27. using System.Text;
  28. using System.Windows.Forms;
  29. using MakeMyDLL;
  30.  
  31.  
  32. namespace UsingDLL
  33. {
  34.     public partial class Form1 : Form
  35.     {
  36.         public Form1()
  37.         {
  38.             InitializeComponent();
  39.         }
  40.  
  41.  
  42.  
  43.         private void btnDraw_Click(object sender, EventArgs e)
  44.         {
  45.             MakeMyDLL.graphics ob = new MakeMyDLL.graphics();
  46.             string ans = ob.Makemydll();
  47.             MessageBox.Show(ans);
  48.         }
  49.  
  50.      
  51.  
  52.      
  53.  
  54.         private void btnDraw_MouseHover_1(object sender, EventArgs e)
  55.         {
  56.             label1.Text = "hey";
  57.         }
  58.  
  59.    
  60.  
  61.     }
  62. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement