BioImager  5.0.0
A .NET microscopy imaging application based on Bio library. Supports various microscopes by using imported libraries & GUI automation. Supports XInput game controllers to move stage, take images, run ImageJ macros on images or Bio C# scripts.
Loading...
Searching...
No Matches
Setup.cs
Go to the documentation of this file.
1using System;
2using System.Collections.Generic;
3using System.ComponentModel;
4using System.Data;
5using System.Drawing;
6using System.Linq;
7using System.Text;
8using System.Threading.Tasks;
9using System.Windows.Forms;
10
11namespace BioImager
12{
13 public partial class Setup : Form
14 {
15 public Setup()
16 {
17 InitializeComponent();
18 }
19
27 private void okBut_Click(object sender, EventArgs e)
28 {
29 if (imgPathBox.Text != "")
30 {
31 Properties.Settings.Default.AppPath = imgPathBox.Text;
32 }
33 else if(!pythonRadioBut.Checked)
34 return;
35 if (libraryPathBox.Text != "" && libRadioBut.Checked)
36 {
37 Properties.Settings.Default.LibPath = libraryPathBox.Text;
38 }
39 Properties.Settings.Default.Setup = true;
40 DialogResult = DialogResult.OK;
41 Properties.Settings.Default.Save();
42 this.Close();
43 }
44
49 private void cancelBut_Click(object sender, EventArgs e)
50 {
51 DialogResult = DialogResult.Cancel;
52 Close();
53 Application.Exit();
54 }
55
60 private void pythonRadioBut_CheckedChanged(object sender, EventArgs e)
61 {
62 Properties.Settings.Default.PMicroscope = pythonRadioBut.Checked;
63 Properties.Settings.Default.PycroManager = false;
64 }
65
71 private void libRadioBut_CheckedChanged(object sender, EventArgs e)
72 {
73 Properties.Settings.Default.PMicroscope = false;
74 Properties.Settings.Default.PycroManager = false;
75 }
76
84 private void setImagingBut_Click(object sender, EventArgs e)
85 {
86 OpenFileDialog d = new OpenFileDialog();
87 d.Title = "Select Imaging Application Executable";
88 if (d.ShowDialog() != DialogResult.OK)
89 return;
90 imgPathBox.Text = d.FileName;
91 }
92
100 private void setLibraryBut_Click(object sender, EventArgs e)
101 {
102 OpenFileDialog d = new OpenFileDialog();
103 d.Title = "Select Imaging Library";
104 if (d.ShowDialog() != DialogResult.OK)
105 return;
106 libraryPathBox.Text = d.FileName;
107 Properties.Settings.Default.PMicroscope = false;
108 }
109
110 private void micromanRadioBut_CheckedChanged(object sender, EventArgs e)
111 {
112 Properties.Settings.Default.PycroManager = micromanRadioBut.Checked;
113 Properties.Settings.Default.PMicroscope = false;
114 if (micromanRadioBut.Checked)
115 imgPathBox.Text = "C:/Program Files/Micro-Manager-2.0/ImageJ.exe";
116 }
117 }
118}
System.Windows.Forms.Application Application
Definition ImageView.cs:14