The replacement delimiters need to be square brackets not curly brackets

This commit is contained in:
larsbrubaker 2014-05-15 14:32:50 -07:00
parent 0aed8d7433
commit 1a7f5416f2
3 changed files with 10 additions and 4 deletions

View file

@ -109,8 +109,14 @@ namespace MatterHackers.MatterControl.SlicerConfiguration
{
foreach (string name in replaceWithSettingsStrings)
{
string thingToReplace = "{" + "{0}".FormatWith(name) + "}";
gcodeWithMacros = gcodeWithMacros.Replace(thingToReplace, ActiveSliceSettings.Instance.GetActiveValue(name));
{
string thingToReplace = "{" + "{0}".FormatWith(name) + "}";
gcodeWithMacros = gcodeWithMacros.Replace(thingToReplace, ActiveSliceSettings.Instance.GetActiveValue(name));
}
{
string thingToReplace = "[" + "{0}".FormatWith(name) + "]";
gcodeWithMacros = gcodeWithMacros.Replace(thingToReplace, ActiveSliceSettings.Instance.GetActiveValue(name));
}
}
return gcodeWithMacros;