@Salem: i always include headers because compiler says, "missing prototype for x()" so i can't forget it :)
Type: Posts; User: gavio
@Salem: i always include headers because compiler says, "missing prototype for x()" so i can't forget it :)
Just for the record... i'm usually using "int main()"... this was just a quick example i was writing.
I have looked at the first one (casting malloc) and could only conclude that it's OK since i included the "stdlib" header (you said it yourself in there :D).
I couldn't find the second one (void...
@Salem: OK, i will. Thank you :)
Omg, i'm so embarrassed right now. Thank you. Resolved.
When i run this, it craches. Does anyone see the problem?
#include <stdlib.h>
struct employee{
int id;
struct employee *next;
};
void add(struct employee **my_struct,int id){
struct...
How does that work?
dumpbin /EXPORTs "example.dll";?? And where do i put it? Can you write an example for me?
Thank you...
@Salem: Yes. It can create and compile DLL projects. I enter the code (the example function from post #1), compile (it compiles) and then i have this 'Entry Point' problem.
@Magos: this doesn't...
Sorry for bumping, but, any1??
Empty project.How should i go about this? Like instead of main()?C (Pelles C 4.0.5).What exactly do you mean with 'dumpbin /exports'?
Is there an example on a simple DLL? I have searched your...
Hello!
I'm trying to create a DLL. This is my code:
//just an example function...
int someFunction(int i){
return i;
}... but here's a problem that i already run into before but never...
Thank you again dwk! ;)
I understood that, but cannot make it work. I have tried "r+" and "a+" but nothing happened. I have made it work with 2 flows ("r" and "w").
This was actually for LaTeX (if you're familiar)... i...
Thank you dwks! How stupid of me... all i needed was 2 FILE flows.
This is what i'm using:
int myChar;
FILE *myFlow;
myFlow=fopen("test.txt","w");
while((myChar=getc(myFlow))!=EOF){
myChar='a'; //for example, i would like to rewrite every character...
Nothing happens... 'c' stays 'c'... even if i use a standard character (for example 'a'). It's not writing into the file. Where am i going wrong?
It's working. myChar=232... However, there's a new problem. I have declared myFlow like this:
FILE *myFlow;
myFlow=fopen("test.txt","r");
//and when i use putc, nothing happens
...
Hello! I was wondering how to define a foreign character? Is there some escape character for that? For example: i'm looping through my file, and when some character equals 'c', i would like to write...