Questions involving programming on Microsoft Windows technology, including its API.

learn more… | top users | synonyms (1)

0
votes
0answers
14 views

Is there a cross-platform way to execute a Python3 script fullscreen?

I'm currently developing a small CLI game in Python for practice. While I can set the shell width and height quite easily, there are lots of different screen sizes in use right now, and I would like ...
0
votes
1answer
54 views

General guidelines for architecturing a plugin based application

Our application is composed of a main webapp and a handful of windows services that perform a variety of jobs that feed, sanitize and optimize that webapp. In order to ease the task of maintaining ...
0
votes
1answer
74 views

Are there system calls like posix in assembly level using int number for windows

I want to write assembly program using windows syscall Interrupt number , so in order to use system call in assembly level using int of sys call, In windows are there kernel calls like posix ...
0
votes
0answers
74 views

How to detect global keyboard hook

It's incredibly easy to write Key-loggers in many languages. It makes me a little nervous because these small, unknown viruses won't get detected by most(read: all) antivirus'. I'm curious how to ...
-4
votes
0answers
92 views

High performance Inter Process Communication (IPC)?

Apologies if this question is "off-topic", I hope it's not... I'm looking for an IPC technology that is capable of communicating to processes on other machines, as well as on the same machine, with ...
2
votes
3answers
200 views

Why would anyone want to build a file system for windows? [closed]

I saw an ad on StackOverflow today for a project called WinFsp. The site mentions the following features: Allows for easy development of file systems in user mode. There are no restrictions on what ...
1
vote
1answer
30 views

How does TranslateMessage help main window of launched process come to foreground?

This question on StackOverflow presents a minimal Win32 program written in C which launches some processes (Notepad and Calc) using CreateProcess. The OP's issue is that the windows of these ...
1
vote
1answer
27 views

Windows Failover Clustering from a Programmer's perspective

I have a number of custom 'server' applications that run on Windows, and I want a way of improving their 'availability' without significantly recoding any client-side (or, ideally, server-side) code. ...
14
votes
3answers
276 views

Supporting development for older OS

I am maintaining a large portion of legacy code, written in C. This code was initially written to be comiled against Windows 3 for Workgroups, and later a version for NT was created. This legacy ...
2
votes
2answers
343 views

Could someone write an opensource version of the Windows API?

I am wondering if it is both possible and how one would write an opensource version of the Windows API. What I mean by this is, say you #include <Windows.h> in your C++ application. Then you ...
1
vote
3answers
153 views

Use case for async/await?

Background Most of the applications that I write are hour long sequential tests for electronic equipment. The equipment under test has a specification that is a state-machine that looks like... Get ...
1
vote
2answers
113 views

Catching exceptions from child process

I am looking for any info. (I know some C++ with win32 and C#) The Idea: The idea is to help a program with missing files load. In the end I wanted to see if I could have my program launch a simple ...
0
votes
1answer
81 views

When should I consider using a string table resource over a string constant in my Win32 application?

I've written a fair bit of Win32 desktop apps as hobby projects throughout my career but I've never used resources of the type string table in any of them; usually I either hard-code strings or build ...
2
votes
1answer
34 views

What's a good strategy to go about registering 2-step hotkeys?

User32.dll exposes a RegisterHotKey function, to register, well, hotkeys: [DllImport("user32.dll", SetLastError = true)] [return: MarshalAs(UnmanagedType.Bool)] public static extern bool ...
2
votes
2answers
97 views

Multiple windows

A while back I got into a discussion with a classmate about whether our application should use multiple JFrames, or windows. I'm a linux-user, and said yes. He's a windows-user, and said no. When ...
1
vote
0answers
79 views

Centralized management of app.config parts for self-hosted .NET services

What will be the best way to handle these scenarios, if they are not one-time, but regular: Self-hosted services on quite a bunch of machines are needed to be reconfigured to a different database in ...
4
votes
1answer
286 views

A manual and automated CSV file upload solution for a website

Problem I run a website which has a requirement for a new feature - to enable users to upload CSV files into the website. The users will only ever need to upload 1 CSV file at a time, and only 1 or 2 ...
2
votes
3answers
179 views

When does gcc not work on Windows [closed]

Everyone (who knows C) always tells me to be careful when using gcc to compile on Windows, yet they never actually tell me what the compatibility issues are. I'm left to believe that gcc is just 'not ...
2
votes
0answers
168 views

Speed: Named Shared Memory vs Memory Mapped File vs Normal Memory

Let's say I have a server, where clients who connect are constantly updating their inventory. I could simply save the changes in to the database after an item has been updated, or I could update the ...
2
votes
0answers
69 views

ODBC 3 Multiple Statements vs Multiple Connections

So right now I have a single thread to handle all the requests for the database. Let's say I have 400 requests per second for logins / logouts / other stuff, and 400 requests per second which are only ...
3
votes
1answer
128 views

Effect of demoting copy-on-write page to read-write on other processes

The Windows OS tries to conserve physical memory usage by allowing DLLs loaded in their base (desired) address in different processes to use the same physical pages with copy-on-write semantics; this ...
2
votes
0answers
50 views

Designing a web based smart card publisher

I'm working on an application that's supposed to have a web based GUI where you can insert some data. That data will be saved in persistent storage and a hex number generated and stored alongside. ...
1
vote
1answer
96 views

What's the historical reason of including DOS-stub in PE images?

I have been wondering this question recently. Why does PE images have to be executable in MS-DOS? I've read on the topic and most of the answers I've seen simply explain it with compatibility. But ...
-1
votes
2answers
224 views

Creating an ASP.Net MVC web application that can work on different operating systems

I have been developing and deploying many ASP.Net MVC web applications under Windows Server 2008 R2 & Windows Server 2012 R2, and I used IIS 7 & IIS 8. At the same time I know that I can ...
-1
votes
1answer
87 views

.net Windows app in a web page [closed]

I am developing a feature related to Microsoft Outlook which has support only for Windows library. However, I have to put this into a web page for the users. In the process of consuming the windows ...
2
votes
0answers
123 views

How to replace or manipulate the Microsoft Desktop Window Manager (DWM)? [closed]

I'm in the midst of deciding which platform to use to implement a new kind of display server / window manager. It seems that it isn't possible to replace the DWM on Windows systems according to MSDN ...
3
votes
1answer
140 views

How to safely and cheaply delete a directory's contents that are constantly being deleted/overwritten

I'm coding something that will check a specific static location's directory, and if it exists, and a certain process has not run in n minutes, it deletes that directory's files and all sub-directory ...
0
votes
1answer
133 views

Why does the Windows Clipboard require an STA thread?

To copy something to the clipboard in Windows (at least in .NET as far as I know) it has to be done on a separate thread that is in STA Mode. One example I have used is this. Thread thread = new ...
1
vote
1answer
70 views

windows users vs. custom [closed]

My application needs to support a "shift change" scenario. Essentially, a person is managing some assets. At the shift change, the person that was there leaves right as the replacement signs in. The ...
-1
votes
1answer
127 views

Is it safe to execute the “regedit” command on Windows? [closed]

I'm writing a Java application, I need to create a URI Scheme. I've seen a library creating a URI Scheme using the "regedit" command on Windows. Is it safe to execute "regedit" for this task? Is ...
3
votes
1answer
56 views

Is there a convention for where to store crash-recovery files?

I work on an application where we have the potential to attempt a file save in the top-level exception handler. The intention would be save a file which can then be sent into the support team, ...
1
vote
0answers
155 views

MVVM viewmodel to view correlation in adaptive UI

I am making an mvvm application for the uwp platform and I am looking for advice on the following matter. Take for example the windows 10 e-mail application, which when full screen displays both the ...
0
votes
0answers
35 views

Looking for an elegant solution to monitor and start an application in non-administrator user login in Windows

I would to get some suggestions or idea about how to tackle this problem. Background I need to run an application on a Windows serve. The application has a dependency on MS Office and it interacts ...
13
votes
4answers
758 views

Should I deploy 32-bit only or both 32- and 64-bit versions for Windows?

I have a cross-platform application written in a compiled language. For Linux it is customary to have both amd64 and i386 builds available to user, so user can choose version, suitable for its ...
0
votes
1answer
78 views

Testing a windows game application against older versions of windows

If I were to build a game using Visual Studio 2015 and (Most likely) SDL2, I think I'm right in assuming that in order for that game to run, the user's target windows version needs to have Visual C++ ...
0
votes
0answers
73 views

A callback for when data is received?

So, my understanding is that the Kernel could receive TCP at any time, and that generally a C program asks the Kernel synchronously/asynchronously if it has data available. Would it be possible for a ...
0
votes
1answer
570 views

Best approach to write windows service

We got a situation where we need to write a windows service using c#, the service need to be install on a particular -single- server. Also service need to communicate with a DB to access certain table ...
4
votes
1answer
4k views

Can I write a cross-platform application (Mac and Windows) using C#? [closed]

I see lots of old information on this question, and lots of articles flying around the Interwebs, but I can't tell quite where things are at. Basically, I want to write C# code that I can then ...
26
votes
5answers
4k views

Why don't Windows/Linux use relational Databases (RDBMS)?

Why don't Windows/Linux use relational databases (RDBMS)? I know they use file systems to store all data but don't you think it is more efficient to use databases like we use in web sites/web apps? ...
3
votes
1answer
312 views

Decrypt data on any Windows computer by same user

I have a license system which currently locks licenses to a physical computer using CryptProtectData (with CRYPTPROTECT_LOCAL_MACHINE) and CryptUnprotectData. This is of course not the entire license ...
-1
votes
1answer
185 views

How to know if an app is launched in windows service application [closed]

I'm trying to write a program which waits for a specific app (matlab in my case) to launch and does stuff when the app launches. I see that I had to write a windows service application and managed ...
0
votes
3answers
142 views

What is the explication for the difference execution time for the same instruction?

As you know when we run instruction in our code like long a = b; we will not have the same ticks each to be executed. first exeution it take 2ticks; second exeution it take 3ticks; third exeution it ...
1
vote
3answers
323 views

How to test Windows .NET TCP program handling of connection failure [closed]

I've written my own C# TCP communications module (using SocketAsyncEventArgs, although that's presumably irrelevant). My module runs at both ends of the connection, client and server. As part of the ...
4
votes
4answers
878 views

Is it the standard accepted practice to install software using VBScript? [closed]

Consider the following requirements Windows software which communicates with a web application using basic authentication The software is an MSI package The software requires a token to be placed in ...
1
vote
1answer
420 views

Use of FindWindow and window handles within a Windows service

I've got a third-party vendor who is installing a series of Windows services to a (Windows 2008 R2) server in my control. Whilst attempting to run each service under its own least-privilege account, ...
3
votes
1answer
99 views

Are Secure Desktop and separate process enough for hiding sensitive information in RAM?

In my program, I have an encrypted database on the file system with a password. It is decrypted in RAM, and the sensitive data get spread out too much in RAM for mistake to be auditable easily enough. ...
-1
votes
1answer
297 views

Longest x86 Instruction

I read the recent article "Longest x86 Instruction" http://blog.onlinedisassembler.com/blog/?p=23 I attempted to reproduce the curious disassembly issue on a Win7x86 development platform using masm ...
0
votes
1answer
107 views

Windows Firewall single rule with multiple IP addresses vs multiple rules with single IP address [closed]

I've tried finding some resources to help me on my dilemma, but wasn't successful in my approach. So here goes: I am implementing an automated firewall manager for Windows Firewall which will ban ...
7
votes
2answers
361 views

What's the best way to handle Windows API errors in response to system messages or when I have nowhere to return them to?

This is going to be a really stupid question and I hope it's fine for Stack Exchange at all, let alone just this part of it... Right now, my custom Table control uses panic() functions that print an ...
2
votes
1answer
546 views

How much physical memory is consumed by the stack of a .NET thread?

In Stephen Cleary's article in MSDN magazine "Introduction to Async/Await on ASP.NET" he says that "every thread pool thread on a modern OS has a 1MB stack." (modern OS == Windows 7/8 for this ...