From: sparhawk AT eunet DOT at (Gerhard Gruber) Newsgroups: comp.os.msdos.djgpp Subject: Re: Help...using execve() in NT Date: Sat, 13 Jun 1998 09:53:18 GMT Organization: Customer of EUnet Austria Lines: 29 Message-ID: <358c469c.3186983@news.Austria.EU.net> References: <6lsbb1$gjr AT dailyplanet DOT wam DOT umd DOT edu> NNTP-Posting-Host: e170.dynamic.vienna.at.eu.net Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk Destination: meatball AT wam DOT umd DOT edu (Arnold Hyo Lee) From: Gruber Gerhard Group: comp.os.msdos.djgpp Date: 12 Jun 1998 22:50:09 GMT: >basically, net view from the command line will do it. > >unfortunantly, i can't get "net view" to work in my execve() function. > >execve("//kyle/c$/winnt/system32", "net", "view"); > >gives me two errors. 1) incompatible pointer type, Argument 2 >2) Incompatible argument type, argument 3. > >so...what am i doing wrong? please help. int execve(const char *path, char *const argv[], char *const envp[]); You are giving a const char * instead of an array. Either you have to use another function or you must setup an array with the arguments and environment and pass this on. -- Bye, Gerhard email: sparhawk AT eunet DOT at g DOT gruber AT sis DOT co DOT at Spelling corrections are appreciated.