Questions tagged [windows]

Microsoft's well-known operating system. Use this tag for code reviews where the code is targeted specifically for this platform, when no other more specific tags exist.

Filter by
Sorted by
Tagged with
1
vote
2answers
99 views

a simple implementation of unix2dos for windows

On linux there is the utility called unix2dos which converts UNIX EOLs(\n) to DOS EOLs(\r\n). However on windows there is no such tool so as a result I decided to make one. ...
2
votes
1answer
39 views

A simple C WinAPI program for terminating processes via process image names - follow-up

(See the previous (i.e. first) version of this tool.) After taking into consideration all the advice by Martin R, I ended up with the following tool for terminating all the processes with given ...
5
votes
1answer
67 views

A simple C WinAPI program for terminating processes via process image names

(Also, see the next iteration.) I have this small program for terminating processes via their respective process image names (.exe files): ...
3
votes
1answer
129 views

Simple Windows implementation of the cat command

On Linux there is the cat command which outputs files concatenated but on Windows there exists no such command. As a result I decided to attempt to recreate a ...
4
votes
0answers
54 views

Basic snake game in C

I wanted to learn C and Win32 so I thought the best way to start would be to create a simple game to get familiar with the language, so I made Snake. The games works perfectly except for sometimes ...
5
votes
0answers
85 views

safexl - A Python / pywin32 Excel Application wrapper

Thanks in advance for your interest in my first PyPI project. While there happen to be a number of projects out there to help with creating & consuming Excel workbooks, I was unable to find one ...
4
votes
2answers
79 views

Lowering the CPU usage when capturing and dividing screenshots into blocks using GDI+

I am trying to capture the screen content of each monitor I have and divide each captured bitmap into small blocks (wxh=128x128). I managed to do this using the GDI+ API, but my implementation (on ...
3
votes
2answers
82 views

Random alphanumeric string generator function (C, Windows, bcrypt.h)

The function uses the Windows "Cryptography API: Next Generation" (bcrypt.h)'s BCryptGenRandom function to generate ...
1
vote
0answers
23 views

Wrapper function that returns cached value from WinAPI call [closed]

I am writing myself a little wrapper and I decided to cache values that shouldn't change (often or at all) for returning to the user, I'm coming from the premise that the WinAPI call is more expensive ...
7
votes
1answer
53 views

x64 NASM Assembler: Binary Search

While quarantine I decided to look into the assembly language, as it's quite interesting to see how code works on the lower levels. To challenge myself I made a binary search algorithm. The OS is ...
5
votes
1answer
55 views

Powershell script to verify Linux-generated md5sum file

I'm moving some files from a Linux machine to a Windows machine over a low-speed, possibly buggy experimental communications channel that I want to test. One of the tests is to transfer large numbers ...
1
vote
1answer
70 views

Internally Safe Filesystem

win_xept.hpp - a basic windows api exception ...
0
votes
0answers
52 views

C# class to dump the memory of a process in several formats

I made this because I couldn't find any good C# classes/libraries that allow you to dump the contents of a process' memory into a file or a byte array. I haven't tested this on 32 bit systems but it ...
1
vote
0answers
22 views

Simple header-only thread and mutex for both windows and linux in C

I wanted to get some thread support on windows with very simple headers for a library that I'm working on but it had to work on both Windows and Linux. Since C11 threads are not widely supported, this ...
4
votes
0answers
62 views

C program to sort files based on information within

I have written a C program to sort files (on Windows) into dynamically created subfolders based on information found in their data headers. I am a newb at C, especially memory management. The code ...
-4
votes
2answers
53 views

Returning employee balances

Here is the code for balance retrieval from EMPLOYEES record. Please simplify and improve it accordingly. It is working fine and I have no problem with it but I believe that's not the correct way to ...
4
votes
1answer
52 views

Windows autoclicker with a console interface

I have recently started coding in c++ and have made a simple console application. When executed the program asks the user to position their cursor wherever they want continuous repeating clicks, after ...
3
votes
0answers
87 views

downloading a list of urls

I wrote this quick (lots of googling) and dirty (I hope not too dirty) script to download a URL list with a win32 wget port and save them as files with the url as the name to use as a "poor man's url ...
2
votes
1answer
75 views

Create Word Document in C++

I am new to COM programming in C++ and while this code works welcome suggestions to improve readability/reliability. This creates a blank word document and adds the text Hello, World. ...
1
vote
0answers
34 views

Batch file that executes multiple .msi files

I am attempting to create a batch file that will execute multiple msi files in a particular location on our network. My intention is not to have any user interactions until they are prompted to do a ...
3
votes
0answers
31 views

Instant to-and-from Roman Numeral Conversion

Ⅰ Roman numerals are composed of digits taken from a small set of uppercase characters. Lowercase characters were first used in the Middle Ages. $$I,V,X,L,C,D,M$$ With these digits we can represent ...
2
votes
1answer
75 views

Flash Light Effect Windows Forms Edited

I am having performence issues with image processing task (flash light effect). I used c#, and used couple references (LockBits Method, Extension). The program has bad frame rates. Edited the code, ...
3
votes
1answer
42 views

Key-scanning macro in NASM Win16 against DOSBOX (Intel 8086)

Supports backspacing, but not wrapped backspacing. ...
6
votes
1answer
122 views

Multitasking in NASM Win16 Assembly

Requirements (Installed using Scoop) scoop install nasm dosbox Build (Using NASM) nasm -g tasks.asm -o tasks.com ...
3
votes
0answers
30 views

Retrieving Registry nodes for HKLM

I am using the below code to retrieve nodes and values. It is taking 20 mins to retrieve the nodes and values of HKLM. I'm expecting to reduce the retrieving time ...
4
votes
1answer
150 views

Printing a string in NASM Win16 Assembly

A small script that simply prints a given string. It's an improved snippet that combines some recommendations given in my post on string helper functions. ...
2
votes
1answer
48 views

Retrieving HKLM nodes of Windows10 Registry

I have used below code, code is working fine, also retrieved the data, but there are performance issues. Retrieving the HKLM registry nodes is taking around 6 mins time. Please suggest any solution. <...
6
votes
2answers
197 views

String helper functions in NASM Win16 Assembly

Environment NASM is required to build this program, and DosBox is required to run it. I'd recommend installing these using the Scoop Package Manager. Feel free to ignore install statements for any ...
6
votes
1answer
93 views

Changing the ACL on a folder through Wscript.Shell within VBA

I have working VBA code in excel that changes a network folders permissions. The code uses Wscript.Shell to run icacls commands but there are multiple instances of this command and each time it runs, ...
3
votes
4answers
294 views

Multi-threading slower than expected from single-thread loop [closed]

The following code is an experiment that I ran to play with the advantages of multi-threading in C++. Given a number 10000000000 it calculates how many numbers are ...
2
votes
1answer
49 views

Recursively find files of certain types and log their paths (C++)

I've written a function that takes a list of extensions and recursively finds files of those types, and logs their paths to a text file. Usage example (finding image files in a home directory): <...
4
votes
1answer
173 views

Getting Windows User Info From The Active Directory

I took some boilerplate code that I have been using for determining an active windows user's info to either send emails with their details, or to pass to a error logging class, and encapsulated it in ...
6
votes
2answers
118 views

Duplicate File Finder in python

I just started learning python yesterday, I have prior experience of C++. So I think I am able to get most of it pretty fast. I wrote a duplicate file finder for testing and practicing. Can you guys ...
3
votes
1answer
301 views

Snake Game in C++ with OOP need advice

I wrote a Snake Game in C++ and I have practiced some OOP approaches on windows 7. What I need: advice how to improve code Most important how to made what Snake on ...
0
votes
1answer
291 views

Text-based Tetris game in C++

I am learning C++ and I've written a text-based classic Tetris game using OOP design. I would really appreciate it if someone could take a look at it and review the OOP design and tell me if something ...
3
votes
2answers
142 views

A little C++ program to have timed rounds for a game

I know it could be better, but I’m new to C++, so I don’t know many of the tricks, along with some of the includes that are already obsolete. This program asks for names as input, adds a time for ...
3
votes
0answers
82 views

Batch configuration script for a new computer

I've been working on a script which configures newly imaged computers (power settings, installed apps, etc) This is what I have so far: ...
3
votes
0answers
73 views

SHA256 directory hash

I'm pretty new and I posted on SO earlier because I wanted to make sure my code was right and all that and I got redirected here. So I have this code that I put together (using Example C Program: ...
2
votes
2answers
170 views

Tetris game for Windows improved version

About a month ago I made a Tetris game for Windows. After a helpful review, I improved the code. I want to hear again an opinion about the implementation, how readable the code is, new mistakes or ...
2
votes
1answer
102 views

“Safe” Windows Module API Wrapper

Recently I've been toying around with C# interop and the Vulkan API. Today I discovered the SafeHandle class and decided I'd try to wrap the Windows API calls that ...
5
votes
2answers
106 views

Program to delete directories that do not contain a file

I'm an intern and have an ETL project I'm doing in python. Part of it is to make sure after I move files I delete empty directories. I wrote this code to clean up directories that are empty and in ...
7
votes
1answer
466 views

C++ Windows Directory Watcher

This was a small project I did the other day because I wanted to explore a solution to hot-reload some files in another project. My requirements were: Act in it's own thread Be able to watch ...
2
votes
0answers
48 views

Simple Socket Server in C for Windows

I have taken the code from a tutorial of Microsoft webpage. Of course, the example is for illustration only but I wanted to organize it and make it clear in order to understand it a little more. Here ...
6
votes
1answer
374 views

Snake console game in C++

I reviewed this question to a snake game console implementation: My first C++ game (snake console game) I enjoyed refactoring this code and presenting a solution using more C++ features/classes. I ...
5
votes
2answers
138 views

First C program: records keyboard/mouse and simulates the recording afterwards

This is my first program ever made in C. Before that I programmed just a little bit in C++ (didn't touch OOP so I did only structural programming). This is my second "project" ever made, the first "...
3
votes
0answers
57 views

Multithreaded OpenGL Rendering Pipeline

I've decided to move my rendering code to a separate thread, to help facilitate the move I've created a pipeline system for rendering. With this pipeline I can insert commands into a queue which will ...
3
votes
1answer
51 views

Opening YouTube videos according to chakra cycles

I'm learning how to write code in Python. This code makes an .ini that saves different cycles adding one new operation to the previous cycle. It starts at 1;1, saves that it has run 1 cycle and will ...
13
votes
1answer
579 views

Windows keylogger in C++

Windows keylogger in C++ Known issues: Not implementing rule of five Having to use hack to use member variables, out_, in static method Pressing caps-lock won't ...
5
votes
1answer
414 views

Point distance program written without a framework

I have been developing a cross-platform game based on open C libraries (mainly glfw) with a direct focus on Windows development. The beginning of my programming career taught me familiarity in ...
7
votes
1answer
514 views

Tetris game for Windows

I'm a student and this is my first application/project that I made and finished today in C++ using OOP and I want to hear your opinions and suggestions, what I did wrong, what I did good, what should ...

1
2 3 4 5 6