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

learn more… | top users | synonyms (1)

-4
votes
1answer
37 views

C++ how export variable from a dynamic library? [on hold]

I have an API class: API.hpp (public API) class math { static __declspec(dllexport) double Pi; static __declspec(dllexport) double Sum(double x, double y); }; Dll.cpp (test.dll) ...
0
votes
3answers
38 views

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

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 ...
5
votes
1answer
121 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 ...
4
votes
4answers
692 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
51 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, ...
1
vote
0answers
62 views

Use of SAL annotations for C++ [closed]

Code analysis tool for visual studio is able to detect some kinds of errors statically if you annotate functions with SAL We used it at first in windows driver when code was mostly C code, and where ...
3
votes
0answers
60 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. ...
0
votes
1answer
124 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 ...
1
vote
5answers
361 views

When programming for a new platform, do you change the keyboard mapping to what you're familiar with? [closed]

I've been a Windows programmer for a decade or more now, and I'm currently doing my first ever Macintosh project. One of the things that is driving me bonkers is how the keyboard maps differently. ...
0
votes
0answers
32 views

Using .hta file to read registry values to create checklist

Internally in the company I work for we use ActiveX to do some browser automation to help save time on repetitive tasks. There are times where profiles are messed up or re-imaging happens and it ...
0
votes
1answer
35 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 ...
2
votes
1answer
130 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 ...
3
votes
2answers
599 views

Where Should I Put Configuration Files?

I'm creating a project that I want to be able to distribute across platforms. I'm writing in Java and AWT which already gives me a pretty large range of devices, but I'm mostly interested in Windows ...
3
votes
1answer
1k views

Windows Console App vs Service

My Situation I work for a company that builds software for many other companies. When I learned installers weren't built-in with VS2012, I was curious how to deploy. So far, I have just been dropping ...
0
votes
1answer
185 views

Simple unicode application?

I want to create simple language learning applications to help friends in learning languages. A simple Java console application would do the trick, but the Windows console does not seem to handle ...
0
votes
3answers
272 views

How can I configure my programming environment to enable rapid switching between projects?

It often happens that I develop multiple different projects at once, so I need a solution to switch from one environment to another. I have created batch files to do the job but as this thing grows, ...
32
votes
3answers
5k views

Is address 0000000C a special address?

When programming sometimes things break. You made a mistake and your program tries to read from a wrong address. One thing that stands out to me that often those exceptions are like : Access ...
1
vote
2answers
242 views

Is there actually an advantage to using Win API calls for file access?

I remember coding file access using the Win API about 15 years ago. It was much faster than using the FileStream of my language at the time (Delphi). I spent a while today experimenting in C# under ...
1
vote
0answers
58 views

Curiosity: Unassembled asm in Windows Bootloader

I found this little gem waiting for me in the Windows (10/TP) bootmgr located on the first 300+- MB partition. Can anyone explain to me what it does? Is there an assembler hidden somewhere? These all ...
1
vote
0answers
115 views

Requesting information regarding the use of MUI vs. the use of GetText for i18n/L10n of Windows desktop applications

I have spent the past two days investigating which technology I will use to support translations of text strings (as part of an overall internationalization migration) for an archaic (VC6) Windows ...
2
votes
1answer
331 views

Modern.IE VM license

Microsoft provides some VMs for testing purposes (advertised on StackOverflow) and I'm trying to understand the license terms. The one I don't really understand is 1.b. You may use the ...
3
votes
3answers
172 views

Why is Win32 API's WM_MOVE being called while dragging the window?

I have two callbacks for WM_MOVE and WM_MOVING. Oddly enough, WM_MOVE is being called while dragging the window. I expected WM_MOVE to be called only when I'm done dragging the window. MSDN says that ...
2
votes
1answer
221 views

Most efficient/cleanest way to Kill a recursive thread safely

I have a number of worker threads which all perform a flood-fill task on different regions of a bitmap. They all make calls to a recursive sub-routine with different parameters(coordinates). Fyi, I am ...
1
vote
3answers
95 views

Concepts used for cross platform development [closed]

Could someone help me to understand how do developers create software that run on windows, linux, and Mac OS X? I am just starting out and have come to the conclusion that I am at a loss for terms to ...
2
votes
3answers
185 views

How to deal with Windows .NET configuration files

We use the normal app.config file for the configuration of the application. Although it works for now it has some pretty significant drawbacks: Upgrading an application with a modified app.config is ...
0
votes
1answer
672 views

Detect or Prevent Screen Capture Applications

I am building an app that displays very sensitive information and as such, I want to be able to either Disable the ability to capture the screen Redact the portion of my app that is on the screen ...
1
vote
2answers
113 views

Program Compatibility - OS That Can Run Anything? [closed]

I know that programs that are built on one OS won't work on another, like a Windows program on a Linux distribution, and that there are programs that translate those system calls into system calls ...
12
votes
3answers
24k views

Windows Phone 8 development on Windows 7 - is it or will be possible? [closed]

I was trying to install Windows Phone 8 SDK on my Windows 7 machine and it hit me with the 'supported only on Windows 8' message. I actually wanted to develop Phone 7.5 apps on Visual Studio 2012, ...
2
votes
3answers
93 views

Smart fallback for line endings in code files? [closed]

What do you recommend as a default fallback for line endings if the operating system cannot be determined? Example Mac OS up to version 9 uses carriage returns (\r) for line endings. Unix-like ...
4
votes
3answers
524 views

How to securely implement Roles in a Windows Form application?

As an ISV, what is considered best practice for implementing Application Role based security? In other words, only allow users to access certain features in the application based on what Roles they ...
-1
votes
1answer
146 views

Calling another program from a Windows Service

Problem: I am working on a service which will do some automated processing at a configurable time each night. It does some communication over the internet, formats some information, and creates a ...
31
votes
6answers
4k views

Do we need to test 32-bit software in 64-bit Windows?

I'm working in a software development team as software developer. I've been working on the same project for three years now. The software is a 32-bit desktop based C# application in .NET 4. Our target ...
27
votes
8answers
5k views

Why don't developers make installation wizards on linux? [closed]

I'm sure it's not about laziness or anything like that but I fail to understand why developers of even mainly consumer facing apps don't make any sort of installation wizard where you go ...
1
vote
0answers
218 views

Is this Auto-Updating strategy for a program in C++ compiled with mingw32 for Windows correct?

I 've been thinking a lot on auto-updating, but wanted to check with you guys if you see any anti-patterns in my proposal: Context I'm coding a game in C++ and SDL, compiled in an Ubuntu (host) for ...
34
votes
7answers
5k views

Why don't developers make installation automatic on windows? [closed]

This is the inverse to "Why don't developers make installation wizards on linux?", which is interesting, but made me think "Automatic instalation is the natural way. Why do they use wizards?". So ...
1
vote
0answers
95 views

API for accessing CTS and DSR signals of serial port

I'm trying to improve another abstraction of the serial port. The project involved often needs to check one of the single control signals CTS and DSR. This is currently done by a call to ...
3
votes
5answers
284 views

Converting our Windows Software to the web [closed]

We're looking at converting a software package from Windows over to the browser. It's a back office system consisting of Ledgers, Stock Control, Order Processing, etc and it's written in a legacy ...
1
vote
1answer
111 views

How do newly-created programming languages use Windows API features?

WinAPI is focused primarily on the C family, but how do new programming languages use those features without creating their own runtime/interpreter type thing? Do they hook directly into the DLL ...
1
vote
1answer
212 views

How should a GUI application written in WinAPI be structured and organized? [closed]

I've done an extensive amount of GUI programming in Winforms and WPF using C#, and a tiny bit in C++ using MFC. I'm building a personal project using WinAPI mainly to gain a deeper knowledge in ...
2
votes
1answer
121 views

Drawing a custom rendered control in Windows - resizing

Some background: in order to learn GUI programming and drawing in Windows I'm starting to create my own GUI toolkit in Windows (so this is a didactic exercise, please don't suggest "use Qt" or "use ...
3
votes
1answer
143 views

How to fix legacy code that uses <string.h> unsafely?

We've got a bunch of legacy code, written in straight C (some of which is K&R!), which for many, many years has been compiled using Visual C 6.0 (circa 1998) on an XP machine. We realize this is ...
-2
votes
2answers
65 views

Know executables files launched/loaded by an executable file [closed]

I would like to know any executable files launched or loaded by an executable file (if possible without running it,if it is not possible i don't want any change in the system). For example i have ...
0
votes
4answers
4k views

Should Android development be done on Windows or OSX? Is there any difference? [closed]

I have the option to install the Android SDK on Windows or OSX. Which platform provides a better (easier) development experience? To keep this constructive, I'm looking for any difference that ...
0
votes
2answers
548 views

how to approach pharmacy software project [closed]

I would like to complete a pharmacy software proof concept. But I have a few questions I do not know. Physician information In order to refill or dispense a new RX the software needs to have access ...
0
votes
4answers
1k views

Webcam software for both Windows and Linux – possible? [closed]

my visually impaired sister uses a webcam with DIY stand as a digital magnifier to read printed texts. We wanted to initiate a project to create a software - in fact only a modified webcam viewer ...
0
votes
1answer
124 views

Need advise for porting linux script to Win command line [closed]

I am creating app(script) that is used similar to RSS reader for specific webpage that doesn't have RSS. So my app downloads that html page in defined intervals, checks new items and parses them into ...
11
votes
2answers
724 views

How to divide work to a network of computers?

Imagine a scenario as follows: Lets say you have a central computer which generates a lot of data. This data must go through some processing, which unfortunately takes longer than to generate. In ...
1
vote
2answers
6k views

How can a website look different in safari Windows and Safari mac?

I have a website. I've been testing crossbrowser on my windows PC, and it looks good in all browsers, but on Mac in Safari it looks like the CSS is not getting interpreted right, or there is a ...
1
vote
0answers
933 views

Accessing a 32-bit DLL from a 64-bit process

I'm aware that it's not possible to load a 32-bit DLL into a 64-bit process. The DLL in question is a ODBC driver which is no longer supported (although it works fine) and no 64-bit version of it ...
-1
votes
1answer
193 views

How to determine what throws an exception [closed]

Whenever I encounter crashes, the exact type of the exception usually already gives enough info to easily find the culprit. FileNotFoundException will hardly occur while using sockets. Now recently ...