From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,dc6ab937143a5e6f X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-02-26 01:33:00 PST Path: archiver1.google.com!news2.google.com!news.maxwell.syr.edu!news2.telebyte.nl!newsfeed.nextoneserver.com!news-out.tin.it!news-in.tin.it!news.finmeccanica.it!not-for-mail From: "Lele" Newsgroups: comp.lang.ada Subject: Re: Send command to the Windows prompt from Ada procedure Date: Thu, 26 Feb 2004 09:50:43 +0100 Organization: Finmeccanica Message-ID: References: NNTP-Posting-Host: 193.70.207.169 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Xref: archiver1.google.com comp.lang.ada:5830 Date: 2004-02-26T09:50:43+01:00 List-Id: Great !!!!! It works fine !!! Thank you I'm really a newbie ;( > Here is a library-level function that invokes the "system" function > of the C-runtime library. > > with Interfaces.C; > function Execute_Shell_Command (Command : in String) return Integer > is > function Execute (Command : in Interfaces.C.char_array) > return Interfaces.C.int; > pragma Import (C, Execute, "system"); > begin -- Execute_Shell_Command > return Integer (Run (Interfaces.C.To_C (Item => Command))); > end Execute_Shell_Command; >