1
vote
1answer
49 views

Mixed programming failed in release but succeeded in debug

In my compiler a function named "func" will be renamed as _FUNC@* after compiling in fortran. And if a c code use _stdcall calling convention, then the function name, e.g. Ab, will be renamed as ...
0
votes
2answers
37 views

_splitpath_s: wrong argument type?

Given the following piece of code: #include <stdlib.h> int _tmain(int argc, _TCHAR* argv[]) { char drive[_MAX_DRIVE]; char dir[_MAX_DIR]; char fname[_MAX_FNAME]; char ...
0
votes
1answer
30 views

Writing a text in a QPixmap

I'm having what is follow: QLabel* label_PM= new QLabel(this); QPixmap PM ("C:/PM.jpg"); label_PM->setPixmap(PM); I would like to insert to the PM a text like what is done in OpenCV cv::putText. ...
-3
votes
0answers
35 views

I want to convert pbm file to bmp file in C program [closed]

#include<stdio.h> #include<cstdlib> #include<stdlib.h> #include <iostream> #include<fstream> #include <string.h> #include<string> #include<conio.h> ...
0
votes
2answers
56 views

Use variables defined in a different source file

i want to get a value from another cpp file for example this one is in fileone.cpp : for (int i = 0; i < NSIZE(facerects); i++) { DetPar detpar; detpar.x = facerect->x + ...
-1
votes
3answers
72 views

How to save this struct to file in C? [closed]

I have no idea how to save this struct to file. I use it as a dynamic structure in my program - a linked list of a linked list. typedef struct productStruct { int id; char *name; double ...
0
votes
1answer
25 views

UDP with another software error

I am using IPG CarMaker and am trying to export the data to another machine using UDP, real time. I am referring to ...
0
votes
5answers
58 views

Pointer to char

Here's a snippet: void addproductInterface(Tsklep **head){ char* name = (char*)malloc(sizeof(char)*100); double price; do{ printf("Name: "); scanf("%s[^\n]", name); ...
-1
votes
1answer
72 views

C and C++ with ethernet in real time [closed]

I have two different software on two different machines. Software A runs real time and can be tailored with in C language. Software B is also real time and I can use C++ over here. What I need to do ...
0
votes
2answers
35 views

Run-Time Check Failure #2 - Stack around the variable 'name' was corrupted

I've got an interface function in my application: void addShopToList(Tshp **shpHead){ char* name; Tshp *newshp = NULL; system("cls"); printf("Name: "); scanf("%s[^\n]", ...
1
vote
1answer
56 views

C - weird syntax error

I'm writing an application in ANSI C (Visual Studio 2010) my library looks like this: #include <stdio.h> #include <stdlib.h> #ifndef _MYLIB_ #define _MYLIB_ typedef enum {false, true} ...
1
vote
1answer
49 views
+50

Visual Studio : Unresolved external symbols after adding new DLL APIs

In a Visual Studio 2010 solution, I have 2 projects: Project A which is a dll project Project B which is an executable project and depends on project A (configured through the solution project ...
1
vote
1answer
54 views

What to use : Ipl? or Mat? [closed]

I really don't know what to use for the next projects: IplImage? or Cv::Mat? Knowing that I want : a better performance considerable speed response regarding the different tools to use ...
-2
votes
1answer
37 views

some extra characters get added to the argument passed to the function

I am calling a function parse_consol(definition1); where the definition i.e the argument passed is of char* type and is absolute path of the xml file. when i check the (by debugging) the value being ...
5
votes
2answers
121 views

Unhandled exception at an if statement in C code

I am using Visual Studio 2010 and in the following code snippet there occurs an exception at the if statement after fseek. int load_filenew(char *filename, char **buffer) { int size = 0; FILE ...
0
votes
0answers
54 views

regex.h causes exception in VisualStudio 2010

I wanted to show my students how to use regular expresions. As they are learn programming in C, I thought it would be the best to use regex.h from GnuWin32 ...
0
votes
1answer
28 views

Visual Studio 2010 linker [C]

I read, that the best way to place functions is to create .h file with function prototypes, some .c file with those functions (including their bodies) and normal .c file with main(). This is how my ...
1
vote
0answers
67 views

Visual Studios 2010: 'File location'.exe is not recognized as internal or external command… (C program)

My Thermo professor assigned our class a computational project in which we have to calculate some thermodynamic functions. He provided us with some code to work off of which is a program that ...
0
votes
2answers
68 views

How to show more than 50 push buttons on a window?

I have created a Window and then, created 50 buttons on this Window but I can only see 10 buttons on my window. Rest are out of view since I am not able to scroll the window down. I have added auto ...
0
votes
0answers
38 views

How to add automatic scrolling bar to a window when number of buttons exceeds window size. (winapi)

I have created a window and added almost 50 buttons to it. But the problem is that I can only see a few of those buttons as my window does not scroll up/down or left/right to show me the remaining ...
1
vote
1answer
88 views

C VS2010 - Heap corruption freeing array of pointer on struct

Hello world (hi people), First, I'd say this is my first post, so please be clement. As the title says, I've a heap corruption when I wants to free my object(s). I passed a couple of hours trying to ...
-2
votes
2answers
57 views

Modifying single structure member

How to edit a single member of a struct? For example I want to change entity.name from foo to foobar. Part of the code: void editing1(int cnt, int qq) { Entity z; char tempc[255]; int ...
0
votes
3answers
68 views

Error C2371: 'eb': redefinition; different basic types - why? [C]

I have the following code: #include <stdio.h> #include <stdlib.h> // helping void sortint(int numbers[], int array_size) { int i, j, temp; for (i = (array_size - 1); i > 0; i--) ...
0
votes
1answer
155 views

Visual Studio 2010 Cannot Open VC++ Include Files

really struggling with a Visual Studio issue here. I get a bunch of errors from Visual Studio after having re-installed it, about it not being able to find VC++ libraries: Error 1 error C1083: ...
0
votes
0answers
36 views

decNumber C library Visual Studio 2010 Compile error

I am getting errors compiling the decNumber C library in Visual Studio 2010 in Windows 7 64 -bit PC. I already tried the solutions offered at this post: decNumber library - compile issues but did ...
1
vote
1answer
42 views

Multiple CreateFileA calls return same File Handle

I have a routine to open COM Ports using CreateFileA. The function is created as a DLL and I have an EXE(using VS2010) to make calls to open different COM Ports. An observation is that if I use the ...
0
votes
1answer
103 views

Unable to build my code using Microsoft Visual Studio 2010

I'm using Microsoft Visual Studio 2010. It was going fine until this morning when I try to build my code. It gave me this weird error: C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Platforms ...
1
vote
1answer
53 views

error A2022: instruction operands must be the same size

Hey so I am getting this error when I run this code: 1>------ Build started: Project: Project, Configuration: Debug Win32 ------ 1> Assembling [Inputs]... 1>assign2.asm(32): error A2022: ...
0
votes
1answer
30 views

Visual Studio 2010 C project - Install as service

I have a program built in Visual Studio 2010. The project has an installer, which was built using the "Setup Project" template of Visual Studio. It works when I want to install my program as a program ...
1
vote
3answers
40 views

Linked list - access violation… Where?

I'm trying to implement a linked list in C: #include <stdio.h> #include <stdlib.h> typedef struct el{ int number; struct el *next; } linkedlist; linkedlist* newel(){ ...
1
vote
3answers
145 views

Why does main have an int in front of it and why could my Professor be excluding it? [duplicate]

So in my professor's slides he simply gives examples like: main() {... } Right? But when I put this in visual studio it gives an error and it works when I put int in front of main. Why would my ...
0
votes
1answer
69 views

How to get same result in C or C++ same as toLowerCase in Java or string.lower() in Python?

I need a C or C++ function(or library) which works like String.toLowerCase() in Java. I know that I can use tolower() for English, but what I need is a function (or library) can cover global ...
0
votes
2answers
57 views

Bubble sort not working at all, if statement not executing

I'm working on a program which is going to be used to sort students test scores and eventually retrieve the mean, median, and the mode of the scores. For some strange reason my bubble sort is not ...
1
vote
2answers
49 views

Freeing the memory - two dimensional array

I use Visual C++ 2010 and I'm trying to use free() with two dimensional array: #include <stdio.h> #include <stdlib.h> #define SIZE 8 int main(){ int **matrix = ...
0
votes
1answer
83 views

CUDA “Unknown error” for unknown reasons [duplicate]

In my current project, a call to cudaGetLastError() is returning unknown error and I don't know why. The code compiles just fine, but it is not behaving how I would like it to. Below is a brief, not ...
1
vote
1answer
78 views

Visual Studio 2010 project file filters

I have a complex C/C++ bunch of applications that I'm working on which is supposed to also be platform independent. So far, is UNIX/Windows compatible and it runs fine. However, maintaing this monster ...
1
vote
0answers
109 views

Using K&R-style C functions in C++ code

I'm trying to use oncrpc-windows project in my VC++ project in VS2010. The oncrpc exports functions in svc.h files without any arguments, but in fact the functions have arguments. For example, the ...
0
votes
1answer
132 views

getch() is working without conio.h - how is that possible? [duplicate]

I started using Visual Studio 2010 (c++) to code in C. #include <stdio.h> #include <stdlib.h> int main(){ printf("test"); getch(); return 0; } this code works, even without ...
0
votes
2answers
95 views

dereference triple pointer

struct integer3_1 { int value3; }; typedef struct integer3_1* intPtr; struct integer3{ intPtr* vPtr; }; typedef struct integer3* intpointer3; int main() { int value = 5; ...
0
votes
1answer
51 views

pointer & dereference

#include <stdio.h> #include <stdlib.h> struct integer2{ int* valuePtr; struct integer2* next; }; typedef struct integer2* intpointer2; int main() { int value2 = 5; ...
1
vote
2answers
61 views

C code from gcc to Visual Studio Express 2010

I'm trying to move some code I have written and compiled succesfully with gcc under Visual Studio Express 2010. I have the following header file. #ifndef _SYMTAB_H_ #define _SYMTAB_H_ #define NHASH ...
5
votes
1answer
228 views

Efficiency between pointer and array(less assembly instructions doesn't take less time) [duplicate]

Some people said: "Any operation that can be achieved by array subscripting can also be done with pointers. The pointer version will in general be faster". I doubt about the outcome of the above, so ...
0
votes
3answers
54 views

accessing the array inside array of structures

I have a structure as follows struct a { char* ap; char* inputs[10]; int e; }; then I have created an array of this structure like struct a list [100]; now i want to fille the array ...
3
votes
1answer
109 views

Strange /fp Floating Point Model flag behavior

I was examining some code which uses the /fp:precise and /fp:fast flags. According to the MSDN documentation for /fp:precise: With /fp:precise on x86 processors, the compiler will perform ...
0
votes
1answer
65 views

visual studio command prompt is closing [closed]

i want to run visual studio(2010 or 2012) command prompt on windows8 x64. but when i click on that(C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\vcvarsall.bat) opening for few seconds and ...
0
votes
0answers
73 views

OpenCV crashing with error on ntdll.dll

I work with OpenCV 2.2. The code below crashes in Visual Studio 2010 with an error: message d'erreur: Exception non gérée ntdll.dll In English: error message: Exception not handled ntdll.dll ...
1
vote
2answers
92 views

How do i write a static ansi-c library using visual studio 2010

When I write and compile a lib file in VS2010 I am missing something. I somehow do not mark them correctly for export. The console command dumpbin.exe -headers mylib.lib > stackoverflow.txt ...
0
votes
1answer
120 views

Getting credis to work in a C++ solution

I'm working on a C++ project where I must connect to redis database. I'm trying to get the credis code to work but when I compile it I get these sets of errors 1>c:\c++redis\credis.c(728): warning ...
0
votes
1answer
106 views

error C2065: 'cp' : undeclared identifier [closed]

I am a new to C, I found this tutorial about string and arrays on the internet, and tried to do the program. They are using eclipse and I am using Visual Studio 2010...please help and explain. I am ...
0
votes
3answers
780 views

error C2143: syntax error : missing ';' before 'type'

I am new to programming C.. please tell me what is wrong with this program, and why I am getting this error: error C2143: syntax error : missing ';' before 'type'.... extern void func(); int ...

1 2 3 4 5 10
15 30 50 per page