windows

Install software on a remote machine?

Hey SO Gus, This might seem like a dump question, but my complete ignorance with VbScript is giving me no chance to try to work it out.In short, a system administrator friend of mine, asked me to write him a script that should allow him to enter a remote machine name, a domain credentials, and an MSI package that will be installed on t...

Can a Windows Server 2003 32-bit machine application work for a Windows Server 2008 64-bit machine?

I am using a Windows Server 2003 32-bit machine. Using that machine I have created a COM component and consumed it in another application and have an EXE file. Now I copy that EXE to another machine installed with Windows Server 2008, 64-bit. And when I try to run that EXE it shows something like "Debug Error: This application needs r...

getaddrinfo returns always 11001 (host not found)

Although the searched FQDN appears in etc\hosts file. Any idea? Thanks a lot! ...

Publish option disabled in win Vista after converting a website to web application

I have converted a web site to a webapplication. In windows Vista, the option of publish is no more available. Any idea how to solve this problem. ...

JNI Call to Authenticate user using LogonUser?

Hey Folks, C++ noob here wonding how i can authenticate a Windows User via Java servlet. Here is the code i have put together to take in a JNI call from my java servlet with the user's username domain and password: #include <stdio.h> #include <string.h> #include <sys/stat.h> #include <stdlib.h> #include "Validate.h" JNIEXPORT j...

How to get rid of Checkstyle Message 'File does not end with a newline.'

I'm working with a maven (jar) Project in Netbeans(Windows), which creates Checkstyle Reports with the maven checkstyle Plugin. No Matter what i do, i always get the message: File does not end with a newline. for Java Class Files. What can i do/configure in either Netbeans (Formatter) or for the checkstyle plugin to get rid of the Mess...

How can I take a screenshot and save it as JPEG on Windows?

I'm trying to find a (somewhat) easy way to take a screenshot on window and save the resulting HBITMAP as a JPEG. The tricky part here is that since the code is in C I can't use GDI+ and since the code is a module for a bigger program I can't neither use an external lib (like libjpeg). This code takes a screenshot and returns a HBITMAP....

How do I add the NULL device to Windows XP Embedded?

Windows XP Embedded is missing the NULL or "NUL" device. For one thing, Visual Studio seems to require it and trying to build a project aborts with a PRJ0015 error. Anyone know how to configure an XPe image to include support for the NUL device? ...

how to store hostname in a variable in a .bat file

I would like to convert this /bin/sh syntax into a widely compatible windows batch script: host=`hostname` echo ${host} How to do this so that it'll work on any Vista, WinXP, Win2k machine? To clarify: I would then like to go on in the program and use the hostname as stored in the variable host. In other words, the larger goal of th...

Run batch file in Windows Installer Commit

I am having no success in modifying a Windows Installer MSI to run a batch file after the primary output has been installed. I have searched for this and found many suggestions, but nothing that works. Add a Custom Action Custom actions can only be executable files. A batch file is not executable. Create a Windows Scripting Host execu...

How to build workspace from DDK examples

Hi All, I am new to win32 programming and also to driver programing. I have installed windows DDK on my system and have got some examples with the DDK but those examples dont have dsw file, i wanted to know how can i create .dsw file so that i can open that workspace in VC6 please help me in this regard. Thanks in advance ...

Running mongrel_rails cluster::start on Windows

I have managed to get mongrel_cluster running on my Windows server (v 1.0.5) ok, but I am having trouble trying to get it to spawning all of the (4) mongrel instances. It launches the first one ok, but then does no more. That one instance serves just fine, but the others are not launched. I assume that this is becasue of: "** WARNING...

Passenger on Windows

Is there anyway to get PAssenger running on a Windows machine? It doesnt appear so, but it seems like many Stackoverflow'ers have use passenger a lot and I was wondering if its possible. ...

SetProcessShutdownParameters for windows services (Windows XP)

I have a few (arbitrary) windows services that I would like to stop down in a specific order on shutdown (e.g., stop A, then stop B, then stop C). I know that service dependencies aren't respected in Windows XP (they are in Vista), but various Internet'ing indicates that the shutdown order may respect the priorities set by SetProcessShu...

Windows Service vs Windows Application - Best Practice

When should I go for a Windows Service and when should I go for a "Background Application" that runs in the notification area? If I'm not wrong, my design decision would be, any app that needs to be running before the user logins to the computer should be a service. For everything else use a background app. Is my decision right? Moreov...

Reliable File.renameTo() alternative on Windows?

Java's File.renameTo() is problematic, especially on Windows, it seems. As the API documentation says, Many aspects of the behavior of this method are inherently platform-dependent: The rename operation might not be able to move a file from one filesystem to another, it might not be atomic, and it might not succeed if a f...

Possible to disable a hook made with SetWindowsHookEx run-time?

Hello. If an application (mine, or in an external process, for example) called SetWindowsHookEx, would it be possible for me to unhook the hook? Remember that it wasn't me who made the hook first place, so I don't have any kind of variables or pointers to the original hooks. ...

What is the easiest way to call a Windows kernel function from Java?

While searching for how to do this, I found some vague discussion about different options, like JNI vs JNA, but not much in the way of concrete examples. Context: if Java's File.renameTo() cannot do it's job (for whatever reason; it is a little problematic), I'd like to fall back to directly using this native Windows function, which is ...

Including required DLLs into a windows project solves a perceived problem?

We have recently decided to start shipping the versions of some of the DLL files that a product requires with the product itself. This is to guard against the situation where (for example) the MVC DLL file is updated on the server to which the software is deployed and the product fails to work as it was written against the now previous ...

How to keep a Python script output window open?

I have just started with Python. When I execute a python script file on Windows, the output window appears but instantaneously goes away. I need it to stay there so I can analyze my output. How can I keep it open? ...