#include <windows.h>
#include <stdio.h>
#include <conio.h>
#include <tchar.h>
Go to the source code of this file.
◆ APP_ONLY
◆ SHOW_ALL
◆ UPD_ONLY
◆ _tmain()
Definition at line 201 of file appwiz.c.
202{
205
207
209 {
211 return 0;
212 }
213
215 {
217 return 0;
218 }
219
221 {
222 if (
argc < 3)
goto ShowAll;
224 {
225ShowAll:
228
229 iNumber =
atoi(Char);
230
231 if (iNumber == 0) return 0;
233 }
235 {
237
239
240 iNumber =
atoi(Char);
241
242 if (iNumber == 0) return 0;
244 }
246 {
248
250
251 iNumber =
atoi(Char);
252
253 if (iNumber == 0) return 0;
255 }
256
257 return 0;
258 }
259
260 return 0;
261}
_Check_return_ _CRTIMP int __cdecl scanf(_In_z_ _Scanf_format_string_ const char *_Format,...)
_Check_return_ int __cdecl atoi(_In_z_ const char *_Str)
int ShowAppList(DWORD dwMode, INT iItem)
◆ CallUninstall()
Definition at line 51 of file appwiz.c.
52{
57
61
63 {
65
66 for (;;)
67 {
70 {
72 {
75 }
76 }
78 break;
79 }
81 }
82}
TW_UINT32 TW_UINT16 TW_UINT16 MSG
BOOL WINAPI TranslateMessage(_In_ const MSG *)
DWORD WINAPI MsgWaitForMultipleObjects(_In_ DWORD nCount, _In_reads_opt_(nCount) CONST HANDLE *pHandles, _In_ BOOL fWaitAll, _In_ DWORD dwMilliseconds, _In_ DWORD dwWakeMask)
Referenced by ShowAppList().
◆ PrintHelp()
Definition at line 21 of file appwiz.c.
22{
24APPWIZ [/? /l] [/all /app /upd]\n\
25 /?\t Help\n\
26 /l\t Show list\n\
27 /all\t Show programs and updates\n\
28 /app\t Show programs only\n\
29 /upd\t Show updates only\n"));
31}
Referenced by _tmain(), AssocQ(), and wmain().
◆ RunGUIAppWiz()
Definition at line 34 of file appwiz.c.
35{
37
39 shInputDll.
cbSize =
sizeof(shInputDll);
42 shInputDll.
lpFile =
_T(
"RunDll32.exe");
43 shInputDll.
lpParameters =
_T(
"shell32.dll,Control_RunDLL appwiz.cpl");
44
46 {
48 }
49}
Referenced by _tmain().
◆ ShowAppList()
Definition at line 91 of file appwiz.c.
92{
104
106 _T(
"Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall"),
108 {
109 printf(
_T(
"ERROR: Can not open Uninstall key. Press any key for continue...\n"));
111 return 0;
112 }
113
116
119 {
121 {
124
128 {
129 bIsSystemComponent = (dwValue == 0x1);
130 }
131 else
132 {
133 bIsSystemComponent =
FALSE;
134 }
135
138
148 {
149 if (!bIsSystemComponent)
150 {
152 {
153 if (iItem == -1)
154 {
155 wsprintf(szOutBuf,
_T(
" %d \t %s\n"), iCount, szDisplayName);
158 }
159 else
160 {
163
166 {
168 }
169 }
170 iCount++;
172 }
173 }
174 }
175 }
176
178 {
180 }
181 else
182 {
185 }
186
188 iIndex++;
189 }
190
193
195 printf(
"\n\nPlease enter application/update number and press ENTER for uninstall\nor press any key for Exit...\n");
196
197 return 1;
198}
HANDLE WINAPI GetStdHandle(IN DWORD nStdHandle)
BOOL WINAPI SetConsoleTextAttribute(IN HANDLE hConsoleOutput, IN WORD wAttributes)
#define FOREGROUND_INTENSITY
#define RegCloseKey(hKey)
void CallUninstall(LPTSTR szUninstallString)
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
static const WCHAR szName[]
#define STD_OUTPUT_HANDLE
#define HKEY_LOCAL_MACHINE
Referenced by _tmain().