static void Main(string[] args) { ConnectionApi.Configure(); //GetAllNotesTest(); PostNote(); Console.ReadKey(); }
public MultiNotesMainWindow() { InitializeComponent(); ConnectionApi.Configure(); var vm = new MainWindowViewModel(Close); DataContext = vm; MinimizeToTray.Enable(this); WindowStartupLocation = WindowStartupLocation.CenterScreen; }
public MultiNotesLoginWindow() { InitializeComponent(); ConnectionApi.Configure(); var vm = new LoginViewModel(Close); DataContext = vm; // Manually alter window height and width SizeToContent = SizeToContent.Manual; // Automatically resize height relative to content SizeToContent = SizeToContent.Height; WindowStartupLocation = WindowStartupLocation.CenterScreen; }
public async void Register(string email, string password) { ConnectionApi.Configure(); var methods = new UserMethod(ConnectionApi.HttpClient); try { await methods.Register(email, password); } catch (Exception ex) { MessageBox.Show(ex.Message); } var loginWindow = new MultiNotesLoginWindow(); loginWindow.Show(); _closeAction.Invoke(); }
private void Application_Startup(object sender, StartupEventArgs e) { ConnectionApi.Configure(); MakeLoginTask(); }