windows

Is there a standard DateTime string representation that is valid as a Windows file name and can be parsed using DateTime.Parse?

As part of a simple backup process, I would like to save files with the name indicating the date and time of the backup. Right now I am using yyyyMMddTHHmmss, i.e. "20100601T115720". I would like to be able to parse those dates back to allow clean up of files older than a certain date. (The backup date time is not necessary the same as t...

Socket.Close doesn't really close tcp socket? (c#)

It seems that using socket.Close() for a tcp socket, doesn't fully close the socket. In the following example I'm trying to connect to example.com at port 9999, which is not opened, and after a short-timeout, I'm trying to close the socket. for (int i = 0; i < 200; i++) { Socket sock = new Socket(AddressFamily.InterNetwork, Sock...

Creating roaming user profiles programmatically on Windows 2008

Problem: Logon and load profile via LoadUserProfile API for a roaming user is not creating proper profile. This only happens under Windows 2008 (UAC off and on). Login using standard windows logon works correctly and same code works correctly on Windows 2003. Logs: http://drop.io/6t2b3f3 ETL of user profile service created via com...

how to create hidden web site on IIS

I need to hide web sites on the IIS 6.0. My target is to configure some user don't show and don't administrate some web sites. For example: User1 (Group: Administrator) user only show and configure website1 User2 (Group: Other group) user only show and configure website2 How to create hidden web sites on IIS? ...

Is there a catalog of all UI widgets and their names, platforms and languages?

I was looking at the Firefox Add-ons Manager UI (pictured below) and really liked the expandable list used to show settings or properties for each add-on. I liked it enough to want to include something similar in one of my applications. The problem is, I don't know, exactly what the control is called (it doesn't seem to be "expanda...

Is there a lightweight, programmable Sandbox API for the Windows platform?

To run untrusted code at home I use a VMWare virtual machine. I want to find an alternate lightweight sandbox API for running untrusted applications, without the overhead of installing VMWare, or any other kind of end-user virtualization tool like that. (Edit: I don't want it to host an OS - I want it to run untrusted apps). Ideally the...

Creating a menu button in Windows

Microsoft's User Experience Interaction Guidelines give some UI guidelines for when to use a menu button: How do I create one of these menu buttons? I've found information on how to create a split button in Vista and above how to create a toolbar button with a dropdown menu how to create a regular pushbutton and manually wire up a...

How to write a service with Visual C++ Express 2008?

The express editions of Visual C++ lack a template for creating Windows services. However, I heard somewhere that it could still be done. How would I go about doing this? ...

Get the logged in Windows user name associated with a desktop

Hello I wish to enumerate all desktops in a system and get the logged in user name for that desktop. So far I have the following code snippit as an example of obtaining a HDESK handle and trying to determine the user name associated with it (if any), but the call to LookupAccountSid fails with ERROR_NONE_MAPPED ("No mapping between acco...

SWT No More Handles

Windows XP has the limit 10000 user handles for each process and total 32000 for each desktop session. However, when I run 4 or 5 SWT process, each consuming no more than 2000 user handles, the SWT No More handles exception will always be threw. Does anyone know why? ...

mod_mono configuration in window for apache web server

hi, how shall i configure the mod_module in apache web server on windows. sameer. ...

How to Connect With Microsoft Localization Center

Windows uses an invalid codepage for keyboard layout in my language, I'm wonderf if there is a way to connect with Microsoft Windows Localization Center and give them the right keyboard layout to put in windows, I try this in Windows blog (by commenting) and e-mailing with some good guy that I knew but no feedback received. I'm still w...

Getting Coverage for Windows Explorer Context Menu Application!

I have an application which runs using the context menu of windows explorer. I create an ATL based DLL and register it to Windows Registry under HKCR\AllFileSystemObjects\ShellEx\ContextMenuHandlers. I am able to run my application. I want coverage for my code present in the DLL which is being registered in the registry. I am currently ...

compiling the web app in monodevelop

hi, i installed the mono develop and mono 2.6 on windows, when i compile the app im getting this exception. can any on help me to solve the issue, Registering application: Host: any Port: any Virtual path: / Physical path: C:\Documents and Settings\sameer\My Documents\Projects\testMonoWeb\testMonoWeb\ pp11:Mono...

Determine which process (b)locks a file, programmatically (under Windows >= XP)

How to programmatically determine from a process P, which other process P' has a lock on a file, that prevents P from recreating that file ? I know there are tools to do that, but how do they achieve that ? (Context: a batch program that runs overnight fails because of a locked file. Running an admin tool the next day may be too late t...

powershell character problem

Hi, I am running the following command. ([xml](new-object net.webclient).DownloadString( "http://blogs.msdn.com/powershell/rss.aspx" )).rss.channel.item | format-table title,link The answer shows me that one rss items has the text "You Don’t Have to Be An Administrator to Run Remote PowerShell Commands" So, the question is; why the...

For Loop Not Working in Makefile: "i was unexpected at this time"

I have a very simple makefile: all: @for i in 1 2 3;\ do \ echo "i: $$i";\ done And yet when I run this, I got a "i was unexpected at this time" error. Any idea why this is the case? I am running on Windows XP. What's the Windows equivalent for the above script? ...

Error when install python mysql module on windows?

When i try to install mysql on windows i get this error MySQL-python-0.9.2>python setup.py build running build running build_py running build_ext building '_mysql' extension error: Unable to find vcvarsall.bat ...

Is it possible to get the Windows logon name with site running asp.net forms authentication?

Hi I have a website with a large user base configured with asp.net 2.0 forms authentication. Before the user logs in via forms authentication is it possible to retrieve the windows login name/user account name on the machine they are using? Many thanks ...

Automatic update solutions for a Win32 application?

We've got a desktop product, made up of a Win32 service, a notification icon application and associated DLL files. I've been tasked to look at making it auto-update. We could write our own updater, but before we do that, I'd like to see what else is out there. Are there any commercial systems (similar to Windows Update, I guess) that we...