windows-vista

How do I copy the newest file in a directory somewhere else from the command line in windows vista

蓝咒 提交于 2019-12-11 13:59:20
问题 I have a directory of many files in Windows Vista. I'd like in a batch script to be able to pick the newest file and copy it to another location. Any ideas how I do that? 回答1: You can use the for command to invoke a directory listing that is sorted by date, and use it to set an environment variable, if you set the same variable to each file, then it will end up being set to the latest file. put this into a batch file: for /F "delims=" %%I in ('dir /b /a-d /od') do set LATEST=%%I echo "%LATEST

Compiling with Delphi 2009 from a command line under Windows Vista 64-bit

老子叫甜甜 提交于 2019-12-11 09:49:57
问题 Has anyone succeeded to compile a Win32 GUI app with the command line dcc32.exe compiler, under 64-bit Windows Vista, without installing Delphi 2009? On our system it fails, with a message that the DFM files contain unknown 16-bit resources. This is usually an indication that the DFM files cannot be read. It works perfectly on all 32-bit Vista and Windows XPs, that we tried. I am asking, because we want to ensure that we can rebuild our current exe files later, if needed, so even if we all

Write to registry in Windows Vista

萝らか妹 提交于 2019-12-11 07:49:12
问题 I am trying to write to the registry from my application, but when I do I get access denied. Of course, it works if i run the app as Administrator. However, with my applcation, it is not initiated by the user. It start automatically. So, the question is, how do i read/write to my own registry key from the C++ app? Thanks for any help. 回答1: Write to HKEY_CURRENT_USER And check out this posts Vista + VB.NET - Access Denied while writing to HKEY_LOCAL_MACHINE Writing string (REG_SZ) values to

What's going on with the Vista heap?

穿精又带淫゛_ 提交于 2019-12-11 07:22:52
问题 I'm trying to better understand why the Windows Vista heap behaves the way it does. Consider the following very simple program: #include <vector> #define NUM_ALLOCS 10000000 int _tmain(int argc, _TCHAR* argv[]) { for (int iteration=0; iteration<10000; ++iteration) { std::vector<unsigned char *> buffer; buffer.reserve(NUM_ALLOCS); for (int i=0;i<NUM_ALLOCS;++i) { buffer.push_back(new unsigned char); } for (int i=0;i<NUM_ALLOCS;++i) { delete buffer[i]; } } return 0; } Basically this is a loop

Android Studio: Error: module not specified but can't select a module to choose

笑着哭i 提交于 2019-12-11 04:09:17
问题 I'm running Android Studio 3.2.1, 32-bit on Windows Vista with JRE 1.8.0 x86 and JetBrains s.r.o OpenJDK. My default app seems to build fine although Gradle takes some time, but when I run it, it prompts me with an "Edit Configurations..." dialog and then says "Click the + button to create a new configuration based on default settings." from which I select "Android App" on the left, but then where the "Module:" field is I can only select "" so I cannot run my app. The error I get at the

COM object to create a “Open File” dialog under Vista?

浪尽此生 提交于 2019-12-11 02:24:39
问题 I would like to use the Windows Common Dialog "Open File", to get a file from the user under JScript. This used to be possible using "ShowOpen()" on MSCOMDLG.commondialog object but, I can't find an equivalent way to do this that works under Vista. 回答1: Try this: http://www.tech-archive.net/Archive/Scripting/microsoft.public.scripting.vbscript/2007-10/msg00444.html Helps? 回答2: You could probably fake it by using CreateObject("Shell.Application").BrowseForFolder( ... ) and use the BIF

Raw partition access in Windows Vista [closed]

荒凉一梦 提交于 2019-12-11 01:55:34
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . Accessing a raw disk partition in Windows Vista requires kernel mode control, as opposed to for instance WinXP where you can access it from user mode. However, I've heard that when it comes to USB flash memory, a partition can still be accessed from user mode even on Windows Vista. Is this true? Regards /Robert

How to get (programatically) the location of a Windows UAC virtualized file?

喜你入骨 提交于 2019-12-11 01:39:13
问题 I have a 32-bit windows old application (with the C/Win32 source) that creates its data file in the same folder where the executable is. Because the application has no installation program and the user can place the executable wherever he/she wants, the application has a dialog to inform the user where its data is located. But under Microsoft Vista/Seven if the user puts the application in the Program Files or any other system-protected folder the data file gets virtualized and moved to a

Vista Phantom Directory

依然范特西╮ 提交于 2019-12-11 01:32:40
问题 We have a program that the installer checks for the existence of a config file, and if it exists, it doesn't copy that file over (it assumes the user has modified their config file and wants to keep those modifications). Unfortunately, this is a pre-Vista application and it keeps the config file in Program Files. The problem is, if you manually wipe out the directory when it re-installs certain API still thinks that there is a directory there. VB6, for example, and its browse for file dialog