I am attempting to get a value from the registry in order to complete a print function using crystal reports.
But it errors out when I do the path because my registry path isn’t working properly.
Values- Global.gAPPNAME = "TEST" Global.gAPPSECTION = "STARTUP"
Global.gREPORTDIR = Registry.GetValue(Global.gAPPNAME, Global.gAPPSECTION, "REPORTDIR").ToString();
When it hits the Global.gREPORTDIR line I get the error – “registry key name must start with a valid base key name”
I am new to this and I was wondering whether this is something that can be fixed with code or something I need to find within the actual computer to find the correct path. Any advice would help. Thanks.
You need to specify a valid root name: