Umbrage Posted February 13, 2019 Author Report Share Posted February 13, 2019 W kodzie mam nastepujacy fragment: char exename[256]; char *a; ... GetModuleFileName(0,exename,sizeof(exename)); a=strstr(exename,"nazwa.exe"); *a=0; SetCurrentDirectory(exename); sa.nLength=sizeof(SECURITY_ATTRIBUTES); sa.lpSecurityDescriptor=NULL; sa.bInheritHandle=false; CreateDirectory("files",&sa); Pobieram pelna sciezke do uruchomionego programu, wyszukuje w niej gdzie sie zaczyna jego nazwa i wpisuje tam 0 aby zakonczyc string i uzyskac tym samym sam katalog, ktory potem ustawiam i zakladam w im katalog. Problem w tym ze na niektorych konfiguracjach program sie wiesza przy SetCurrentDirectory. Czy ktos zna przyczyne dlaczego sie tak dzieje? Wyczytalem w MSDNie o jakims UNICODE dla starszych Windowsow - moze o to chodzi? Quote Link to comment Share on other sites More sharing options...
Juju Posted February 13, 2019 Report Share Posted February 13, 2019 Witam Jesli chodzi o unikod polecam petzolda, cały rozdział jest o unikodzie. Jesli kompilujesz pod win nt/2000/xp unikod jest domyslnie wlaczony, na win98 moze nie dzialac Quote Link to comment Share on other sites More sharing options...
Freak Posted February 13, 2019 Report Share Posted February 13, 2019 Jesli kompilujesz pod win nt/2000/xp unikod jest domyslnie wlaczony Unicode nie jest włączony dopóki sam go nie włączysz, przez #define UNICODE Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.