javaprogrammer1996

method

Sep 10th, 2015
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 1.42 KB | None | 0 0
  1. package application;
  2. import java.net.URL;
  3. import java.util.ResourceBundle;
  4.  
  5. import javafx.application.Application;
  6. import javafx.fxml.FXML;
  7. import javafx.fxml.FXMLLoader;
  8. import javafx.fxml.Initializable;
  9. import javafx.scene.Group;
  10. import javafx.scene.Parent;
  11. import javafx.scene.Scene;
  12. import javafx.scene.control.RadioButton;
  13. import javafx.scene.control.ToggleButton;
  14. import javafx.scene.control.ToggleGroup;
  15. import javafx.stage.Stage;
  16.  
  17.  
  18.  
  19. // Setting up the window
  20. public class MainController extends Application implements Initializable  {
  21.    
  22.      {
  23.  
  24.     RadioButton CallBox1, PutBox1;
  25.     CallBox1=new RadioButton("Call");
  26.     PutBox1=new RadioButton("Put");
  27.     final ToggleGroup group2 = new ToggleGroup();
  28.     CallBox1.setToggleGroup(group2);
  29.     PutBox1.setToggleGroup(group2);
  30.     CallBox1.setSelected(true);
  31.     }
  32.            
  33.    
  34.    
  35.    
  36.  
  37.  
  38.     public void start(Stage primaryStage) throws Exception {
  39.        
  40.  
  41.         Parent root = FXMLLoader.load(getClass().getResource(("/application/fxml.fxml")));
  42.         Scene scene = new Scene(root, 640, 400);
  43.        
  44.         primaryStage.setScene(scene);
  45.         primaryStage.setTitle("Black-Scholes Pricer (European Options) ");
  46.         primaryStage.setResizable(false);
  47.         primaryStage.show();
  48.        
  49.        
  50.  
  51.        
  52.  
  53.        
  54.        
  55.        
  56.     }
  57.    
  58.     public static void main(String[] args) {
  59.         launch(args);
  60.     }
  61.     public void initialize(URL arg0, ResourceBundle arg1) {
  62.          
  63.     }
  64.  
  65.    
  66.    
  67. }
Advertisement
Add Comment
Please, Sign In to add comment