Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

338 lines
5.5 KiB

  1. #if !defined(__PPERRMAP_H__)
  2. #define __PPERRMAP_H__
  3. #pragma once
  4. //-----------------------------------------------------------------------------
  5. //
  6. // File: pperrmap.h
  7. //
  8. // Passport error code definitions.
  9. //
  10. //-----------------------------------------------------------------------------
  11. #include <pperr.h>
  12. #include <pperrres.h>
  13. struct PPERR_MAP
  14. {
  15. HRESULT hr;
  16. DWORD dwResourceID;
  17. LPCWSTR cwzXMLCode;
  18. };
  19. static PPERR_MAP sgProfileErrMap[] =
  20. {
  21. { PP_E_NAME_BLANK,
  22. IDS_E_NAME_BLANK,
  23. L"f2a"
  24. },
  25. { PP_E_INVALID_PHONENUMBER,
  26. // IDS_E_NAME_TOO_SHORT,
  27. IDS_E_INVALID_PHONENUMBER,
  28. L"f3c"
  29. },
  30. { PP_E_NAME_TOO_LONG,
  31. IDS_E_NAME_TOO_LONG,
  32. L"f3d"
  33. },
  34. { PP_E_NAME_INVALID,
  35. IDS_E_NAME_INVALID,
  36. L"f3"
  37. },
  38. { PP_E_MEMBER_EXIST,
  39. IDS_E_NAME_EXIST,
  40. L"f3"
  41. },
  42. { PP_E_PASSWORD_BLANK,
  43. IDS_E_PASSWORD_BLANK,
  44. L"f2b"
  45. },
  46. { PP_E_PASSWORD_TOO_SHORT,
  47. IDS_E_PASSWORD_TOO_SHORT,
  48. L"f5"
  49. },
  50. { PP_E_PASSWORD_TOO_LONG,
  51. IDS_E_PASSWORD_TOO_LONG,
  52. L"f5c"
  53. },
  54. { PP_E_PASSWORD_CONTAINS_MEMBERNAME,
  55. IDS_E_PASSWORD_CONTAINS_MEMBERNAME,
  56. L"f5a"
  57. },
  58. { PP_E_PASSWORD_INVALID,
  59. IDS_E_PASSWORD_INVALID,
  60. L"f5b"
  61. },
  62. { PP_E_PASSWORD_MISMATCH,
  63. IDS_E_PASSWORD_MISMATCH,
  64. L""
  65. },
  66. { PP_E_SECRETQA_NOQUESTION,
  67. IDS_E_SECRETQA,
  68. L"f2c"
  69. },
  70. { PP_E_SECRETQA_NOANSWER,
  71. IDS_E_SECRETQA,
  72. L"f2c"
  73. },
  74. { PP_E_SECRETQA_NOMATCH,
  75. IDS_E_SECRETQA_NOMATCH,
  76. L"f2c"
  77. },
  78. { PP_E_SECRETQA_DUPLICATE_Q,
  79. IDS_E_SECRETQA_DUPLICATE_Q,
  80. L"f2c"
  81. },
  82. { PP_E_SECRETQA_DUPLICATE_A,
  83. IDS_E_SECRETQA_DUPLICATE_A,
  84. L""
  85. },
  86. { PP_E_PIN_BLANK,
  87. IDS_E_PIN_BLANK,
  88. L""
  89. },
  90. { PP_E_PIN_TOO_SHORT,
  91. IDS_E_PIN_TOO_SHORT,
  92. L""
  93. },
  94. { PP_E_PIN_TOO_LONG,
  95. IDS_E_PIN_TOO_LONG,
  96. L""
  97. },
  98. { PP_E_PIN_CONTAINS_MEMBERNAME,
  99. IDS_E_PIN_CONTAINS_MEMBERNAME,
  100. L""
  101. },
  102. { PP_E_PIN_INVALID,
  103. IDS_E_PIN_INVALID,
  104. L""
  105. },
  106. { PP_E_PIN_MISMATCH,
  107. IDS_E_PIN_MISMATCH,
  108. L""
  109. },
  110. { PP_E_LOCATION_INVALID_COUNTRY,
  111. IDS_E_LOCATION_INVALID_COUNTRY,
  112. L"f7b"
  113. },
  114. { PP_E_LOCATION_INVALID_REGION,
  115. IDS_E_LOCATION_INVALID_REGION,
  116. L"f7a"
  117. },
  118. { PP_E_LOCATION_INVALID_POSTALCODECHARS,
  119. IDS_E_LOCATION_INVALID_POSTALCODECHARS,
  120. L"f7d"
  121. },
  122. { PP_E_LOCATION_INVALID_POSTALCODE,
  123. IDS_E_LOCATION_INVALID_POSTALCODE,
  124. L"f7c"
  125. },
  126. { PP_E_EMAIL_BLANK,
  127. IDS_E_EMAIL_BLANK,
  128. L"f7f"
  129. },
  130. { PP_E_EMAIL_INVALID,
  131. IDS_E_EMAIL_INVALID,
  132. L"f7g"
  133. },
  134. { PP_E_EMAIL_RIGHT_TOO_LONG,
  135. IDS_E_EMAIL_RIGHT_TOO_LONG,
  136. L"f7g"
  137. },
  138. { PP_E_EMAIL_INVALID_CHARS,
  139. IDS_E_EMAIL_INVALID_CHARS,
  140. L"f7h"
  141. },
  142. { PP_E_EMAIL_INCOMPLETE,
  143. IDS_E_EMAIL_INCOMPLETE,
  144. L"f7g"
  145. },
  146. { PP_E_EMAIL_MEMBER_EXIST,
  147. IDS_E_EMAIL_MEMBER_EXIST,
  148. L"f7"
  149. },
  150. { PP_E_EMAIL_MANAGED,
  151. IDS_E_EMAIL_MANAGED,
  152. L"f7h"
  153. },
  154. { PP_E_GENDER_BLANK,
  155. IDS_E_GENDER,
  156. L"f8"
  157. },
  158. { PP_E_GENDER_INVALID,
  159. IDS_E_GENDER,
  160. L"f8"
  161. },
  162. { PP_E_BIRTHDATE_NOTENTERED,
  163. IDS_E_BIRTHDATE,
  164. L"f9"
  165. },
  166. { PP_E_BIRTHYEAR_INVALID_CHARS,
  167. IDS_E_BIRTHDATE,
  168. L"f9"
  169. },
  170. { PP_E_BIRTHYEAR_NOT_4DIGIT,
  171. IDS_E_BIRTHDATE,
  172. L"f9"
  173. },
  174. { PP_E_BIRTHYEAR_TOO_LOW,
  175. IDS_E_BIRTHDATE,
  176. L"f9"
  177. },
  178. { PP_E_BIRTHYEAR_MISSING,
  179. IDS_E_BIRTHDATE,
  180. L"f9"
  181. },
  182. { PP_E_BIRTHMONTH_MISSING,
  183. IDS_E_BIRTHDATE,
  184. L"f9"
  185. },
  186. { PP_E_BIRTHMONTH_INVALID,
  187. IDS_E_BIRTHDATE,
  188. L"f9"
  189. },
  190. { PP_E_BIRTHDAY_MISSING,
  191. IDS_E_BIRTHDATE,
  192. L"f9"
  193. },
  194. { PP_E_BIRTHDAY_INVALID,
  195. IDS_E_BIRTHDATE,
  196. L"f9"
  197. },
  198. { PP_E_BIRTHDATE_IN_FUTURE,
  199. IDS_E_BIRTHDATE,
  200. L"f9"
  201. },
  202. { PP_E_FIRSTNAME_BLANK,
  203. IDS_E_FIRSTNAME_BLANK,
  204. L"fb1"
  205. },
  206. { PP_E_LASTNAME_BLANK,
  207. IDS_E_LASTNAME_BLANK,
  208. L"fb2"
  209. },
  210. { PP_E_NICKNAME_BLANK,
  211. IDS_E_NICKNAME_BLANK,
  212. L"fb3"
  213. },
  214. { PP_E_OCCUPATION_BLANK,
  215. IDS_E_OCCUPATION_BLANK,
  216. L"fb3"
  217. },
  218. { PP_E_TIMEZONE_BLANK,
  219. IDS_E_TIMEZONE_BLANK,
  220. L"fb3"
  221. },
  222. { PP_E_EXTERNALFIELD_BLANK,
  223. IDS_E_REQUIREDEXTERNAL_BLANK,
  224. L""
  225. },
  226. { PP_E_INVALID_PHONENUMBER,
  227. IDS_E_INVALID_PHONENUMBER,
  228. L""
  229. },
  230. {
  231. PP_E_PHONENUMBER_EXIST,
  232. IDS_E_PHONENUMBER_EXIST,
  233. L""
  234. },
  235. {
  236. PP_E_MISSING_PHONENUM,
  237. IDS_E_MISSING_PHONENUM,
  238. L""
  239. }
  240. };
  241. struct PPHELP_MAP
  242. {
  243. PCSTR szField;
  244. DWORD dwResourceID;
  245. };
  246. static PPHELP_MAP sgProfileHelpMap[] =
  247. {
  248. { "Email",
  249. IDS_H_EMAIL
  250. },
  251. { "EmailAsName",
  252. IDS_H_EMAIL_AS_NAME
  253. },
  254. { "Password",
  255. IDS_H_PASSWORD
  256. },
  257. { "SecretQuestion",
  258. IDS_H_SQA
  259. },
  260. { "SignInName",
  261. IDS_H_NAME
  262. },
  263. };
  264. LPCWSTR ProfileHR2XMLCode(HRESULT hr);
  265. ULONG ProfileHR2ResID(HRESULT hr);
  266. ULONG ProfileField2HelpResID(LPSTR szField);
  267. #endif //#if !defined(__PPERRMAP_H__)