You need to sign in to do that
Don't have an account?
tomasdd
Salesforce deployment logs in netbeans
Hi,
I've a problem with retrieve deployment/validation logs from salesforce in my java application.
When I click deploy button process of deployment is start but I can not see any details in my textArea field.
Anyone know how can I get these logs and put them into textArea field?
I would like to have logs like below when I click the deploy button:
Here is the code of deployButton:
String selectedOrg = orgSelectName.getSelectedItem().toString(); String pathDesktopBuildOrg = System.getProperty("user.home") + "/Desktop/Deployment/" + selectedOrg + "/build.xml"; if (orgSelectName.getSelectedIndex() == 0){ JOptionPane.showMessageDialog(null, "Select org !"); buttonGroup2.clearSelection(); }else if (!noTestRun.isSelected() && !runLocalTests.isSelected() && !runAllTestsInOrg.isSelected()){ JOptionPane.showMessageDialog(null, "Select target !"); buttonGroup2.clearSelection(); }else { if (noTestRun.isSelected()) { File buildFile = new File(pathDesktopBuildOrg); Project antProject = new Project(); antProject.setUserProperty("ant.file", buildFile.getAbsolutePath()); antProject.init(); ProjectHelper helper = ProjectHelper.getProjectHelper(); antProject.addReference("ant.ProjectHelper", helper); helper.parse(antProject, buildFile); String targetNoTestRun = "deployCodeWithoutTests"; antProject.executeTarget(targetNoTestRun); buttonGroup2.clearSelection(); } else if (runLocalTests.isSelected()) { File buildFile = new File(pathDesktopBuildOrg); Project antProject = new Project(); antProject.setUserProperty("ant.file", buildFile.getAbsolutePath()); antProject.init(); ProjectHelper helper = ProjectHelper.getProjectHelper(); antProject.addReference("ant.ProjectHelper", helper); helper.parse(antProject, buildFile); String targetNoTestRun = "deployCode"; antProject.executeTarget(targetNoTestRun); buttonGroup2.clearSelection(); } else if (runAllTestsInOrg.isSelected()) { File buildFile = new File(pathDesktopBuildOrg); Project antProject = new Project(); antProject.setUserProperty("ant.file", buildFile.getAbsolutePath()); antProject.init(); ProjectHelper helper = ProjectHelper.getProjectHelper(); antProject.addReference("ant.ProjectHelper", helper); helper.parse(antProject, buildFile); String targetNoTestRun = "DeployCodeWithAllTests"; antProject.executeTarget(targetNoTestRun); buttonGroup2.clearSelection(); } }