Advertisement
Guest User

Untitled

a guest
Jun 19th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.05 KB | None | 0 0
  1. class DataDB
  2. {
  3.  
  4. // POSTGRESQL PARAMS
  5. public static string server = "192.168.0.65";
  6. public static string port = "5439";
  7. public static string user = "unam";
  8. public static string database = "unam";
  9. }
  10.  
  11. // POSTGRESQL PARAMS
  12. private static string server = DataDB.server;
  13. private static string port = DataDB.port;
  14. private static string user = DataDB.user;
  15. private static string database = DataDB.database;
  16.  
  17. // POSTGRESQL PARAMS
  18. public static string server { get; set; }
  19. public static string port { get; set; }
  20. public static string password { get; set; }
  21. public static string user { get; set; }
  22. public static string database { get; set; }
  23.  
  24. public static void readData()
  25. {
  26. TextReader readFile;
  27. readFile = new StreamReader("C:\Users\unam\Documents\Hugo\Datos.txt");
  28. server = readFile.ReadLine();
  29. port = readFile.ReadLine();
  30. user = readFile.ReadLine();
  31. database = readFile.ReadLine();
  32.  
  33. readFile.Close();
  34.  
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement