Advertisement
Guest User

Untitled

a guest
Sep 22nd, 2017
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. static Authorize form = new Authorize();
  2. static void Main2(object state)
  3. {
  4. Application.Run((Form)state);
  5. }
  6. static Authorize form = new Authorize();
  7. public static Authorize Create()
  8. {
  9. Thread thread = new Thread(Main2);
  10. thread.SetApartmentState(ApartmentState.STA);
  11. thread.Start(form);
  12. form.FormClosing += Authorize_FormClosing;
  13. return form;
  14. }
  15. public void InitForm()
  16. {
  17. InitializeComponent();
  18. this.FormClosing += Authorize_FormClosing;
  19. }
  20. public Authorize(string Url)
  21. {
  22. InitializeComponent();
  23. AuthCont.AllowNavigation = true;
  24. AuthCont.Navigate(Url);
  25. }
  26. public void NavigateTo(string Url)
  27. {
  28. AuthCont.Navigate(Url);
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement