func main() { chave := `BDS.PasFile\shell\Calcular métricas\Command` v, err := gowin.GetReg("HKCR", chave, "") //err := gowin.WriteStringReg("HKCR", `BDS.PasFile\shell\Metric\Command`, "", `c:\projetos\go\auditoria-e-metricas\client\clientAudit.exe -arquivo=%1 -browser`) if err != nil { gowin.WriteStringReg("HKCR", chave, "", `c:\projetos\go\auditoria-e-metricas\client\clientAudit.exe -arquivo=%1 -browser`) } }
func GetPageSetup(regName string) (val string) { val, err := gowin.GetReg("HKCU", `Software\Microsoft\Internet Explorer\PageSetup`, regName) if err != nil { log.Println(err) } return }
func getWInstalDate() string { val, _ := gowin.GetReg("HKLM", `Software\Microsoft\Windows NT\CurrentVersion`, "InstallDate") return val }
func getOS() string { val, _ := gowin.GetReg("HKLM", `Software\Microsoft\Windows NT\CurrentVersion`, "ProductName") return val }