skip to Main Content

Visual Studio Code – my c++ app don't run after i add this code

I add this code to my C++ app but I can't run the app anymore: void setclipbord(const char* szBuffer) { OpenClipboard(NULL); HGLOBAL hClipboardData = GlobalAlloc(GMEM_MOVEABLE, strlen(szBuffer) + 1); char* pchData = (char*)GlobalLock(hClipboardData); strcpy(pchData, szBuffer); GlobalUnlock(hClipboardData); EmptyClipboard(); SetClipboardData(CF_TEXT, hClipboardData); CloseClipboard(); }…

VIEW QUESTION

ConfigurationBuilder().AddJsonFile(path) says file not found but file exists

any hints as to why this throws a "configuration file was not found and is not optional" exception? string relative_path = "../../../../appsettings_global.json"; if (File.Exists(relative_path)) { IConfigurationRoot global_config = new ConfigurationBuilder().AddJsonFile(relative_path, false, true).Build(); global_settings = global_config.GetRequiredSection("Settings").Get<GLOBAL_SETTINGS>(); }

VIEW QUESTION

Asp.net – Experiencing a data binding issue on a Blazor .NET 8 Web App

@page "/login" @using BlazorWebAppNew.Data @inject IJSRuntime JSRuntime @inject UserDataContext dataContext <PageTitle>Login</PageTitle> <div class="container mt-5"> <div class="row justify-content-center"> <div class="col-md-6"> <div class="card"> <div class="card-header"> <h6 class="card-title">Please log in</h6> </div> <div class="card-body"> <EditForm Model="@loginModel" OnValidSubmit="HandleLogin" FormName="LoginForm"> <DataAnnotationsValidator /> <ValidationSummary /> <div class="form-group…

VIEW QUESTION

Ubuntu – Why the program is ending abruptly

I need to solve a transcendental equation in C++ using Octave API, but the program crashes. Maybe there is a problem with indexes? Code: #include <iostream> #include <octave/oct.h> #include <octave/octave.h> #include <octave/parse.h> #include <octave/interpreter.h> int main() { // Define the…

VIEW QUESTION
Back To Top
Search