Go Back   FlashFXP Forums > >

Programming Need help with C/C++/Delphi? Ask here and make us all laugh.

Closed Thread
 
Thread Tools Rate Thread Display Modes
Old 07-02-2004, 09:35 AM   #1
apusnaias
Junior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 21
Default [C] Basic example

Hello,

I just want to try to program a very basic little C module to attach to the eggdrop.

Please can someone give a little example, just to do smthing like this :

when i do "!test message" on the irc chan, a TCL script call a test.exe program which is written in C with "!test meassage" in parameter,the program do smthing with, and the program return to the channel smthing like "nick say bla bla".

Can someone write me thr TCL script, and the part of C program to return smthing plz ?

I hope my msg is clear

THx in advance.
apusnaias is offline  
Old 07-02-2004, 01:32 PM   #2
FTPServerTools
Senior Member
FlashFXP Beta Tester
ioFTPD Scripter
 
Join Date: Sep 2002
Posts: 543
Default

Code:
#include <stdio.h>
#include <stdlib.h>
void main(int argc, char *argv[])
{
  int i;
  for (i=0;i<argc;i++)
    printf("Arg[%d]=s\n",i,argv[i]);
}
compile as mytool.exe

In tcl:
set reply [exec -- "c:/mytools/mytool.exe"]
FTPServerTools is offline  
Old 07-05-2004, 04:37 AM   #3
apusnaias
Junior Member
ioFTPD Foundation User
 
Join Date: Oct 2003
Posts: 21
Default

thx a lot, this will help for sure
apusnaias is offline  
Closed Thread

Tags
program, script, smthing, tcl, test

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 12:25 AM.

Parts of this site powered by vBulletin Mods & Addons from DragonByte Technologies Ltd. (Details)