Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by bluenote

  1. bluenote

    function pointer within a struct?

    struct Page { char* title; ... void (*out)(const char*); }; void out(const char* str) { printf("%s\n",str); } struct Page* pg; //you have forgotten this line (i guess) pg=(struct Page*)malloc(sizeof(struct Page)); pg->out=out; pg->out("Hello")...
  2. bluenote

    Displaying Current Date in C program

    with the tm struct you can use the strftime function to format the output. #include <stdio.h> #include <time.h> time_t t_now; struct tm *tm_now; t_now = time(NULL); tm_now = localtime(&t_now); char time_buf[50]; strftime(time_buf,50,&quot;%d/%m/%Y %H:%M:%S&quot;,tm_now)...
  3. bluenote

    n-ary tree

    #include <stdio.h> #include <ctype.h> #include <string.h> #include <stdlib.h> #define MAXWORD 100 #define getch() getc(fpin) #define ungetch(x) ungetc(x,fpin) FILE *fpin; struct tnode{ char *word; int count; struct tnode *left; struct tnode *right; }; struct tnode...
  4. bluenote

    Urgent..Internet connection..

    I think that it's just an aproximation of how to do this ... #include <wininet.h> #define LAN 0x02 #define MODEM 0x01 int flags; //If you are online it will return True, otherwise False int Online = InternetGetConnectedState(&flags ,0); if(flags & LAN) // u r connected via lan...
  5. bluenote

    Which Compiler???

    i'm with alarcon and sirbu. I got Dev-C++ and LCCWIN32 compilers installed , and I use both. More often LccWin32. I used to develop SMTP servers POP servers. UDP apps. DLL's bluenote@uyuyuy.com (excuse my english)
  6. bluenote

    Sleeping Barber using mutex_lock (no semaphores)

    what is &quot;the sleeping barber problem&quot;? bluenote@uyuyuy.com (excuse my english)
  7. bluenote

    hi JohnFill!! please could you give me more info!!!

    #include <stdio.h> #include <string.h> #include <io.h> void printFilesDir(char *mypath); //FILE *fp; int main(){ //char mypath[]=&quot;c:\\&quot;; char *mypath; //fp=fopen(&quot;c:\\test.txt&quot;,&quot;w&quot;); mypath=strdup(&quot;c:\\&quot;); printFilesDir(mypath)...
  8. bluenote

    How do you a directory list, and load the filenames into an array?

    you can try this one #include <stdio.h> #include <string.h> #include <io.h> void printFilesDir(char *mypath); //FILE *fp; int main(){ //char mypath[]=&quot;c:\\&quot;; char *mypath; //fp=fopen(&quot;c:\\test.txt&quot;,&quot;w&quot;); mypath=strdup(&quot;c:\\&quot;)...
  9. bluenote

    How to identify a CR and LF

    what do you mean with 'no difference'?? &quot;hello world\n&quot; is not the same that &quot;hello world\r\n&quot; bluenote@uyuyuy.com (excuse my english)
  10. bluenote

    What is the benefit of private struct member??!!

    thats what i thought bluenote@uyuyuy.com (excuse my english)
  11. bluenote

    What is the benefit of private struct member??!!

    how can i create a private struct member?? bluenote@uyuyuy.com (excuse my english)
  12. bluenote

    How to identify a CR and LF

    CRLF => \r\n bluenote@uyuyuy.com (excuse my english)
  13. bluenote

    Speeding up programs

    in pure vb code i recomend to replace all string manipulation functions, such as right, left, str, mid , etc .. for right$, left$, str$ mid$, lcase$, ucase$, etc ... inside functions use a var that store the length or a string, dont use Len(myString) over and over in the same function ..... i...
  14. bluenote

    External File Referencing

    if you want more info 'bout ShellExecute() look at www.vbapi.com ::-) bluenote@uyuyuy.com (excuse my english)
  15. bluenote

    really easy one

    hi!, lil' sample .... lets say that you have main form (frmMain), this is the startup object, and a config form (frmConfig). When the app starts, the application automatically loads the main form (frmMain). at frmMain_Load() you can: Load the config form (frmConfig) with Load frmConfig, this...

Part and Inventory Search

Back
Top