diff --git a/DDG4/plugins/Geant4GDMLWriteAction.cpp b/DDG4/plugins/Geant4GDMLWriteAction.cpp
index 9fab41ad496ed306b0a6e42be078d25fe7348d10..5fb30f097f11e6377d3bd6f618a38b6e00dfd877 100644
--- a/DDG4/plugins/Geant4GDMLWriteAction.cpp
+++ b/DDG4/plugins/Geant4GDMLWriteAction.cpp
@@ -144,7 +144,7 @@ void Geant4GDMLWriteAction::writeGDML()   {
   unique_ptr<G4GDMLParser> parser(new G4GDMLParser());
   parser->SetRegionExport(m_exportRegions != 0);
   parser->SetEnergyCutsExport(m_exportEnergyCuts != 0);
-#if G4VERSION_NUMBER>=1020
+#if G4VERSION_NUMBER>=1030
   parser->SetSDExport(m_exportSensitiveDetectors != 0);
 #endif
   info("+++ Writing GDML file: %s", m_output.c_str());