[NET] Move ACCOUNTS command syntax and help text into a message table.
[reactos.git] / base / applications / network / net / main.c
index 3463720..883ee2e 100644 (file)
@@ -145,6 +145,30 @@ PrintErrorMessage(
 }
 
 
+VOID
+PrintNetMessage(
+    DWORD dwMessage)
+{
+    PWSTR pBuffer;
+
+    FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER |
+                   FORMAT_MESSAGE_FROM_HMODULE |
+                   FORMAT_MESSAGE_IGNORE_INSERTS,
+                   GetModuleHandleW(NULL),
+                   dwMessage,
+                   LANG_USER_DEFAULT,
+                   (LPWSTR)&pBuffer,
+                   0,
+                   NULL);
+    if (pBuffer)
+    {
+        ConPrintf(StdOut, L"%s\n", pBuffer);
+        LocalFree(pBuffer);
+        pBuffer = NULL;
+    }
+}
+
+
 VOID
 ReadFromConsole(
     LPWSTR lpInput,