FXML file has stopped opening with scene builder

1

Until yesterday when I was stirring, I would open a file. So now I can not open my file. The other fxml of the project usually open however the one in specific appears the icon there below that is open but if I click, it does not open any window. Does anyone know what it is?

This is the code for my FXML

<AnchorPane id="AnchorPane" fx:id="painelGeral" focusTraversable="true" 
prefHeight="839.0" prefWidth="884.0" styleClass="mainFxmlClass" 
xmlns="http://javafx.com/javafx/8" xmlns:fx="http://javafx.com/fxml/1" 
fx:controller="exetiquetadora.janelasFXML.FXMLTelaPrincipalController">
    <stylesheets>
        <URL value="@fxml.css" />
    </stylesheets>
   <children>
      <Button fx:id="btnSincroniza" layoutX="8.0" layoutY="97.0" 
mnemonicParsing="false" text="Sincronizar com Excellent Sistemas" />
      <Label layoutX="272.0" layoutY="20.0" text="Impressor de Etiquetas">
         <font>
            <Font size="37.0" />
         </font>
      </Label>
      <Pane fx:id="painelPrincipal" layoutX="14.0" layoutY="155.0" prefHeight="678.0" 
prefWidth="856.0">
         <children>
            <ScrollPane layoutX="25.0" layoutY="88.0" prefHeight="202.0" 
prefWidth="796.0">
               <content>
                  <TableView fx:id="tblResultProdutos" prefHeight="200.0" 
prefWidth="794.0">
                    <columns>
                      <TableColumn fx:id="columnNome" prefWidth="257.0" text="Nome 
Produto" />
                      <TableColumn fx:id="columnVProd" prefWidth="85.0" text="Valor 
Produto" />
                        <TableColumn fx:id="columnCodEAN" minWidth="0.0" 
prefWidth="91.0" text="Cod EAN" />
                        <TableColumn fx:id="columnOBS" prefWidth="97.0" text="OBS" />
                        <TableColumn fx:id="columnCodReduzido" prefWidth="100.0" 
text="Cód.Reduzido" />
                        <TableColumn fx:id="columnTamanho" prefWidth="81.0" 
text="Tamanho" />
                        <TableColumn fx:id="columnCor" prefWidth="81.0" text="Cor" />
                    </columns>
                  </TableView>
               </content>
            </ScrollPane>
            <Button fx:id="btnLimparTabela" layoutX="627.0" layoutY="647.0" 
mnemonicParsing="false" onAction="#limparItens" text="Limpar Itens" />
            <Button fx:id="btnImprimir" layoutX="712.0" layoutY="647.0" 
mnemonicParsing="false" onAction="#imprimir" text="Imprimir" />
            <Button fx:id="btnPesquisar" layoutX="571.0" layoutY="50.0" 
mnemonicParsing="false" onAction="#pesquisarProdutos" text="Pesquisar" />
            <TextField fx:id="txtPesquisar" layoutX="268.0" layoutY="50.0" 
prefHeight="22.0" prefWidth="289.0" />
            <ScrollPane layoutX="23.0" layoutY="469.0" prefHeight="172.0" 
prefWidth="810.0">
               <content>
                  <TableView fx:id="itensToPrint" prefHeight="170.0" 
prefWidth="1040.0">
                    <columns>
                      <TableColumn fx:id="codigoPrint" prefWidth="75.0" text="Código" 
/>
                      <TableColumn fx:id="descricaoPrint" prefWidth="161.0" 
text="Descrição" />
                        <TableColumn fx:id="valorPrint" prefWidth="56.0" text="Valor" 
/>
                        <TableColumn fx:id="qtdePrint" prefWidth="63.0" 
text="Qtde.Etiquetas" />
                        <TableColumn fx:id="empresaPrint" prefWidth="76.0" 
text="Empresa" />
                        <TableColumn fx:id="complementoPrint" prefWidth="89.0" 
text="Complemento" />
                        <TableColumn fx:id="tamanhoPrint" prefWidth="63.0" 
text="Tamanho" />
                        <TableColumn fx:id="codRedPrint" prefWidth="75.0" 
text="Cod.Reduzido" />
                        <TableColumn fx:id="info1Print" prefWidth="70.0" text="Info1" 
/>
                        <TableColumn fx:id="info2Print" prefWidth="71.0" text="Info2" 
/>
                        <TableColumn fx:id="info3Print" prefWidth="83.0" text="Info3" 
/>
                        <TableColumn fx:id="corPrint" prefWidth="75.0" text="Cor" />
                        <TableColumn fx:id="referenciasPrint" prefWidth="75.0" 
text="Referencias" />
                    </columns>
                     <columnResizePolicy>
                        <TableView fx:constant="CONSTRAINED_RESIZE_POLICY" />
                     </columnResizePolicy>
                  </TableView>
               </content>
            </ScrollPane>
            <Button fx:id="addItemToPrint" layoutX="732.0" layoutY="435.0" 
mnemonicParsing="false" onAction="#addToPrint" text="Adicionar Item" />
            <Label layoutX="40.0" layoutY="302.0" text="Qtd. Etiquetas:" />
            <Label fx:id="lblCodBarras" layoutX="40.0" layoutY="412.0" text="Cód. de 
Barras:" />
            <TextField fx:id="txtCodBarras" layoutX="115.0" layoutY="408.0" />
            <Label layoutX="690.0" layoutY="412.0" text="Valor:" />
            <Label layoutX="611.0" layoutY="412.0" text="Cifrão:" />
            <TextField disable="true" layoutX="645.0" layoutY="408.0" prefHeight="22.0" 
prefWidth="26.0" promptText="R$" />
            <TextField fx:id="txtValor" layoutX="719.0" layoutY="408.0" 
prefHeight="22.0" prefWidth="58.0" />
            <Label layoutX="22.0" layoutY="438.0" text="OBS:Inserir textos apenas sem 
acentuação" textFill="RED">
               <font>
                  <Font name="System Bold Italic" size="12.0" />
               </font>
            </Label>
            <Label layoutX="346.0" layoutY="435.0" text="Itens para imprimir" 
textFill="#39ae35">
               <font>
                  <Font name="Bookshelf Symbol 7" size="21.0" />
               </font>
            </Label>
            <TextField fx:id="txtQtd" layoutX="116.0" layoutY="298.0" prefHeight="22.0" 
prefWidth="42.0" promptText="0" />
            <Button fx:id="btnSair" layoutX="775.0" layoutY="647.0" 
mnemonicParsing="false" onAction="#sair" text="Sair" />
            <Separator layoutX="18.0" layoutY="13.0" prefHeight="3.0" prefWidth="796.0" 
/>
            <Separator layoutX="22.0" layoutY="72.0" prefHeight="14.0" 
prefWidth="796.0" />
            <Label fx:id="lblTamanho" layoutX="61.0" layoutY="332.0" text="Tamanho:" />
            <TextField fx:id="txtTamanho" layoutX="115.0" layoutY="328.0" 
prefHeight="22.0" prefWidth="42.0" />
            <Label fx:id="lblInfo1" layoutX="294.0" layoutY="339.0" text="Informação 
1:" />
            <Label fx:id="lblInfo2" layoutX="294.0" layoutY="375.0" text="Informação 
2:" />
            <Label fx:id="lblInfo3" layoutX="294.0" layoutY="412.0" text="Informação 
3:" />
            <TextField fx:id="txtInfo1" layoutX="368.0" layoutY="335.0" />
            <TextField fx:id="txtInfo2" layoutX="368.0" layoutY="371.0" />
            <TextField fx:id="txtInfo3" layoutX="368.0" layoutY="408.0" />
            <Label fx:id="lblEmpresa" layoutX="563.0" layoutY="302.0" text="Nome 
Empresa:" />
            <Label fx:id="lblComplemento" layoutX="559.0" layoutY="339.0" 
text="Complem. Nome:" />
            <Label fx:id="lblProduto" layoutX="601.0" layoutY="375.0" text="Produto:" 
/>
            <TextField fx:id="txtCodReduzido" layoutX="368.0" layoutY="298.0" />
            <Label fx:id="lblCodReduzido" layoutX="291.0" layoutY="302.0" text="Cód. 
Reduzido:" />
            <TextField fx:id="txtEmpresa" layoutX="645.0" layoutY="298.0" />
            <TextField fx:id="txtComplemento" layoutX="645.0" layoutY="335.0" />
            <TextField fx:id="txtProduto" layoutX="645.0" layoutY="371.0" />
            <Label fx:id="lblCor" layoutX="94.0" layoutY="357.0" text="Cor:" />
            <Label fx:id="lblReferencias" layoutX="56.0" layoutY="382.0" 
text="Referencias:" />
            <TextField fx:id="txtCor" layoutX="115.0" layoutY="353.0" />
            <TextField fx:id="txtReferencias" layoutX="115.0" layoutY="382.0" />
            <Label fx:id="lblTamCor" layoutX="255.0" layoutY="357.0" text="(0)" />
            <Label fx:id="lblTamReferencias" layoutX="255.0" layoutY="386.0" text="(0)" 
/>
            <Label layoutX="255.0" layoutY="412.0" text="(13)" />
            <Label fx:id="lblTamInfo3" layoutX="504.0" layoutY="412.0" text="(0)" />
            <Label layoutX="779.0" layoutY="412.0" text="(10)" />
            <Label fx:id="lblTamProduto" layoutX="779.0" layoutY="375.0" text="(0)" />
            <Label fx:id="lblTamComplemento" layoutX="779.0" layoutY="339.0" text="(0)" 
/>
            <Label fx:id="lblTamEmpresa" layoutX="779.0" layoutY="302.0" text="(0)" />
            <Label fx:id="lblTamInfo2" layoutX="504.0" layoutY="375.0" text="(0)" />
            <Label fx:id="lblTamInfo1" layoutX="504.0" layoutY="339.0" text="(0)" />
            <Label fx:id="lblTamCodReduzido" layoutX="504.0" layoutY="302.0" text="(0)" 
/>
            <Label fx:id="lblTamTamanho" layoutX="171.0" layoutY="332.0" text="(02)" />
            <Pane layoutX="38.0" layoutY="24.0" prefHeight="47.0" prefWidth="186.0" 
style="-fx-border-color: black; -fx-background-color: silver;">
               <children>
                  <Label layoutX="14.0" layoutY="7.0" text="Pesquisa por:" />
                  <RadioButton fx:id="rdDescricao" layoutX="13.0" layoutY="27.0" 
mnemonicParsing="false" selected="true" text="Descrição" />
                  <RadioButton fx:id="rdCodigo" layoutX="108.0" layoutY="26.0" 
mnemonicParsing="false" text="Código" />
               </children>
            </Pane>
            <Button fx:id="btnEditar" layoutX="578.0" layoutY="435.0" 
mnemonicParsing="false" onAction="#editarLinha" text="Editar Linha Selecionada" />
         </children>
      </Pane>
      <Label layoutX="800.0" layoutY="60.0" text="Versão 1.0.4.0">
         <font>
            <Font size="12.0" />
         </font></Label>
      <Separator layoutX="8.0" layoutY="122.0" prefHeight="14.0" prefWidth="863.0" />
      <Separator layoutX="8.0" layoutY="77.0" prefHeight="3.0" prefWidth="863.0" />
      <Separator layoutY="11.0" prefHeight="3.0" prefWidth="863.0" />
      <ProgressBar layoutX="233.0" layoutY="99.0" prefHeight="17.0" prefWidth="457.0" 
progress="0.0" />
      <ImageView fitHeight="65.0" fitWidth="223.0" layoutX="8.0" layoutY="16.0" 
pickOnBounds="true" preserveRatio="true">
         <image>
            <Image url="@EX-Logo.jpg" />
         </image>
      </ImageView>
      <Label layoutX="38.0" layoutY="137.0" text="Modelo Etiqueta:" />
      <ComboBox fx:id="cbEtiquetas" layoutX="120.0" layoutY="133.0" prefHeight="22.0" 
prefWidth="146.0" promptText="Selecione um modelo" />
      <Pane layoutX="734.0" layoutY="133.0" prefHeight="22.0" prefWidth="133.0" 
style="-fx-border-color: black; -fx-background-color: silver;">
         <children>
            <Label layoutX="13.0" layoutY="4.0" text="Configurações: F12" 
textFill="#e80c0c">
               <font>
                  <Font name="System Bold" size="11.0" />
               </font>
            </Label>
         </children>
      </Pane>
   </children>
</AnchorPane>
    
asked by anonymous 26.09.2017 / 15:54

2 answers

0

This can happen because of the error in your FXML or a bug in the window. To solve the first situation just remove the code below (here even with the error opened normally, perhaps because of the cache).

<columnResizePolicy>
    <TableView fx:constant="CONSTRAINED_RESIZE_POLICY" />
</columnResizePolicy>

The error that occurs is that this constant is not set to TableView, but it looks like the appearance of it is related to a bug in netbeans . However, there is the second situation that is reported here (credits to author ), it has the following workaround :

  

Windows XP / 7

  • Open the task manager (Ctrl + Alt + Del)
  • Go to the "Applications" tab
  • Right click on the SceneBuilder (yourFile.fxml)
  • Select 'Maximize'
  

Windows 8 +

  • Open the task manager (Ctrl + Alt + Del)
  • Go to the "Processes" tab
  • Click the JavaFX Scene Builder x.x.exe dropdown menu
  • Find the file FXML file that is not opening
  • Right click > Maximize

Bonus:

From what I understand of this error you are trying to block the default action of resizing the columns in the TableView. The bad news is not an easy way to do this, because this function is buggy. Here's how you do it in JavaFX without FXML:

// Coluna 1 com 25% do tamanho total e assim por diante
coluna1.prefWidthProperty().bind(tableview.widthProperty().multiply(0.25));
coluna2.prefWidthProperty().bind(tableview.widthProperty().multiply(0.05));
coluna3.prefWidthProperty().bind(tableview.widthProperty().multiply(0.45));
coluna4.prefWidthProperty().bind(tableview.widthProperty().multiply(0.15));

Basically you associate the total size of the TableView with the size of the columns, given a percentage, this causes the little table to not resize the column. You would have to adapt to use in FXML ( try this >).

    
26.09.2017 / 17:27
0

I had the same problem today and I believe it's a problem in the cache itself. I changed the FXML name and was able to open the file in the Scene Builder, then came back with the original file name and opened normally.

    
15.10.2018 / 17:04