#134238 java.io.FileNotFoundException: Sample databases not created. Restart NetBeans or create the folder not found. C:\Documents and Settings\gaweraj\.netbeans-derby
1.1 --- a/visualweb.dataconnectivity/src/org/netbeans/modules/visualweb/dataconnectivity/utils/SampleDatabaseCreator.java Thu May 15 01:17:30 2008 +0200
1.2 +++ b/visualweb.dataconnectivity/src/org/netbeans/modules/visualweb/dataconnectivity/utils/SampleDatabaseCreator.java Sun May 18 16:38:49 2008 -0700
1.3 @@ -117,13 +117,13 @@
1.4 FileObject systemHomeFO = FileUtil.toFileObject(systemHomeFile);
1.5 // Partial fix for Issue 121195. If toFileObject can't find the file on disk, it returns null
1.6 if (systemHomeFO == null) {
1.7 - LOGGER.log(Level.WARNING, org.openide.util.NbBundle.getMessage(SampleDatabaseCreator.class, "MSG_DERBY_SYSTEM_FOLDER_NOT_FOUND")); // NOI18N
1.8 - throw new FileNotFoundException(org.openide.util.NbBundle.getMessage(SampleDatabaseCreator.class, "MSG_DERBY_SYSTEM_FOLDER_NOT_FOUND") + systemHomeFile.getCanonicalPath()); // NOI18N
1.9 - }
1.10 - FileObject sampleFO = systemHomeFO.getFileObject(databaseName); // NOI18N
1.11 - if (sampleFO == null) {
1.12 - sampleFO = systemHomeFO.createFolder(databaseName);
1.13 - this.extractZip(sourceFO, sampleFO);
1.14 + LOGGER.log(Level.WARNING, org.openide.util.NbBundle.getMessage(SampleDatabaseCreator.class, "MSG_DERBY_SYSTEM_FOLDER_NOT_FOUND")); // NOI18N
1.15 + } else {
1.16 + FileObject sampleFO = systemHomeFO.getFileObject(databaseName); // NOI18N
1.17 + if (sampleFO == null) {
1.18 + sampleFO = systemHomeFO.createFolder(databaseName);
1.19 + extractZip(sourceFO, sampleFO);
1.20 + }
1.21 }
1.22 }
1.23