|
hi , can anyone please tell me how to copy a file to another destination , something like the filecopy command in the vb.
|
|
|
|
|
Check out shfileoperation api.
My God is more powerfull Than Your God.
|
|
|
|
|
> ...something like the filecopy command in the vb.
Just swap the words in filecopy ...and you'll get the C++ equivalent.
CopyFile or CopyFileEx will do it in C++. Another alternative is SHFileOperation .
Regards,
RK
|
|
|
|
|
|
hi , can anyone please tell me how to copy a file to another destination , something like the filecopy command in the vb.
|
|
|
|
|
what about "CopyFile"?
BOOL CopyFile(
LPCTSTR lpExistingFileName,
LPCTSTR lpNewFileName,
BOOL bFailIfExists
);
Don't try it, just do it!
|
|
|
|
|
hallo all i have a picture data in a DC and i want to store it in defferent formats(specially .bmp)still i can use this data working on it and store it againe in the same file.
help me please.
|
|
|
|
|
HI , CHECK OUT THE cxIMAGE CLASS IN THIS FORUM.
BYE.
|
|
|
|
|
hallo all, is there any one have a VC++ code or any tuturials to take a video from a computer camera using DirectX and store the video data in any format(.AVI,.mpg,..etc)while still i can take the data , process it and play it againe.
thanks for any help.
|
|
|
|
|
sorry, we're not doing your homework! ->get directX sdk!
Don't try it, just do it!
|
|
|
|
|
How can I find the full path of running batch file under cmd.exe or command.com(windows98).
For ex: open cmd.exe and execute any batch file.
How can I get full path of batch file?
viji
|
|
|
|
|
'cd' (with no arguments) returns the full path, which you should be able to capture from within the batch file.
|
|
|
|
|
I shouldn't touch this batch file. Is there any way to find from another vc++ application?. I have only cmd.exe processid and threadid.
Okay I want to put my question this way. I know the batch file but i cannot modify the file and i need to find whether it is currently running or not in the system.
viji
|
|
|
|
|
code:
std::map<const char*,int=""> amap; char str[];
amap.find(str); // compiler point error to here
error:
error C2451: conditional expression of type 'class std::_Tree<char const="" *,str=""
uct="" std::pair<char="" *="" const,int="">,struct std::map<char const="" *,int,struct=""
std::less<char="" *="">,class std::al
locator<int> >::_Kfn,struct std::less<char const="" *="">,class std::allocator<int>
>::iterator' is illegal No user-defined-conversion operator available that can perform this co
nversion, or the operator cannot be called
i don't know how to cope with it.
please help me!
thanks.
love program
|
|
|
|
|
Did you correctly include your code within your message, or did the angle brackets get chopped off? A map needs two template parameters, for example:
std::map<int,string>
This is the map key, and the map item. If you have done this then repost your code and escape the < and > (or check the 'do not treat <'s as HTML) and we can take another look.
|
|
|
|
|
|
i was going to design a reminder tool and i wanted some suggestions
can i use the task scheduler somehow is that recommended ?
or should i simply use the timers ?
or is there any other technique ?
|
|
|
|
|
Use Task Schedular API , as it comes with every OS from Win98 to onwards.
It best provides you COM model to program.
Thanks.
The Phantom.
|
|
|
|
|
How do you pgm. resolve a url?
Say http://www.coolsite.com
Best Wishes and Happy Holiday's,
ez_way
|
|
|
|
|
#include <winsock.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(int argc, int **argv)
{
WSADATA wsda; // Structure to store info
// returned from WSAStartup
struct hostent *host; // Used to store information
// retreived about the server
char szAddress[64];
int i;
// Check arguments
if(argc != 2 ||
(argc==2 && strcmp((char *) &argv[1][0], "/?")==0))
{
printf("resolver domain\n");
printf(" domain: the domain name that you want to resolve\n");
exit(1);
}
// Copy the IP address
strcpy(szAddress, (char *) &argv[1][0]);
// Load version 1.1 of Winsock
WSAStartup(MAKEWORD(1,1), &wsda);
host = NULL;
printf("Resolving host...");
host = gethostbyname(szAddress); // Get the IP address of the server
// and store it in host
if(host == NULL)
{
printf("Error\nUnknown host: %s\n", szAddress);
exit(1);
}
printf("OK\n");
printf("host->h_name = %s\n", host->h_name);
i = 0;
while(host->h_aliases[i] != NULL)
{
printf("host->h_aliases[%d] = %s\n", i, host->h_aliases[i]);
i++;
}
printf("host->h_addrtype = %d\n", host->h_addrtype);
printf("host->h_length = %d\n", host->h_length);
i = 0;
while(host->h_addr_list[i] != NULL)
{
printf("host->h_addr_list[%d] = 0x%X (%s)\n",
i,
(long) host->h_addr_list[i],
inet_ntoa(*(struct in_addr *) host->h_addr_list[i]));
i++;
}
WSACleanup();
return 0;
}
The Phantom.
|
|
|
|
|
Great work, Thanks so very much, I was killin myself over this one.
Best Wishes, thank again
Marty
Best Wishes and Happy Holiday's,
ez_way
|
|
|
|
|
Hi all,
There is a problem with CRichEditCtrl class.
The problem when I change the aligning from left to right or right to left the text disturbs, means it got corrupted.
Help kindly appreciated.
Best Regards,
The Phantom.
|
|
|
|
|
I enabled the horizontal and vertical scrolling options in my dialog properties but how come when i run it, the scrollers doesn't work even though my dialog is bigger then screen size.
|
|
|
|
|
you will have to handle the onhscroll and on vscroll notification and scroll the window urself
|
|
|
|
|
What is prefered base address with respect to dlls? If any one can provide a link for its description i will be helpfull...
Regards,
Prakash.
My God is more powerfull Than Your God.
|
|
|
|