|
hello.
i need to get a html code so i can get same values out of it
but what is the best and the fastes way to do it?
|
|
|
|
|
Is there a procedure for copying folders from one place to another?
If there is such a procedure, could you tell me please which is it, and which parameters does it take?
THANK YOU!
|
|
|
|
|
|
All right... I saw it. But I don't understand a thing about that parameter, could you give me an example please?
|
|
|
|
|
|
I had already done that, but i still don't know how to use it... I'm quite new to visual c...
This is how i used it... and the program crashes. I guess i don't know how to handle the parameter...
LPSHFILEOPSTRUCT lpFileOp;
lpFileOp->pFrom="c:\\ad";
lpFileOp->pTo="d:\\";
lpFileOp->fFlags=FOF_ALLOWUNDO;
lpFileOp->wFunc=FO_COPY;
SHFileOperation(lpFileOp);
|
|
|
|
|
|
|
|
|
yesterday i spoke to soon...
i tried to use ravi's and dunn's programs... but they just didn't work, although ai included "c:\\DiskObject.h", or in the other case "c:\\CShellFileOp.h" and it gives the error message "undeclared identifier" when using the related procedures/functions
|
|
|
|
|
I have some experince in vc++.But i lack some fundamentals.If anybody having very good experince want to teach me i can pay for the service.If interested email me back.
Thanks
Ajit
ajitmittal@gmail.com
|
|
|
|
|
|
Hello..
I'm very new to visual C++ , I'm using a console application in Microsoft Visual Studio. NET..
I have a simple application where I want to get some parameters from the user, so i ask the user for it but when i type the answer and press enter on the keyboard the program just crashes (application has encountered a problem..send error to microsoft)
this is my code:
<br />
string host_name; <br />
<br />
printf("ENTER HOST NAME: "); <br />
<br />
<br />
scanf("%s",host_name); <br />
<br />
I have the following include files in stdafx.h file:
#include <iostream>
#include <string.h>
#include <tchar.h>
#include <windows.h>
#include <stdio.h>
#include <stdlib.h>
I tried declaring host_name as char* but it still crashes.. tries using gets() but doesnt as well..
I also tried doing it the C++ way as follows :
<br />
<br />
using namespace std; <br />
<br />
cout<< "ENTER HOST NAME: "; <br />
cin >>host_name; <br />
And that also crashes the program..
Please tell me where the problem is.. Thank you for ur help..
|
|
|
|
|
Declare char host_name[100] and this will take care of the input string.
If you are willing to use string , then be sure you have the following:
#include <iostream>
#include <stdlib.h>
#include <string>
using namespace std;
SkyWalker
-- modified at 10:37 Saturday 22nd October, 2005
|
|
|
|
|
Thanks i'll used char hostname[100] and its fine now..
Is there any way that when the user inputs a password through the console that i can not make it display or have *** display instead ??
|
|
|
|
|
Capture the input and display what you want.
The following could do the trick:
#include <iostream>
using namespace std;1
.
.
char c, thePassword[100];
int i=0;
while((c = getch()) != '\n')
{
thePassword[i]=c;
putch('*');
}
then use thePassword within your code
SkyWalker
-- modified at 12:00 Saturday 22nd October, 2005
|
|
|
|
|
Hi
I tried to use what u mentioned above but it just skips allowing the user to enter the password (no * are even displayed ) and just goes forward with the program..
this is how i'm using it:
<br />
<br />
printf("ENTER PASSWORD: ");<br />
<br />
char c, password[100];<br />
int i=0;<br />
<br />
while((c = getchar()) != '\n') <br />
{ <br />
password[i]=c; <br />
putchar('*');<br />
}<br />
Am i doing something wrong ? thanks for the help..
|
|
|
|
|
You should be writing a console application.
(and collateral to that, increase i, otherwise everything goes to password[0] )
SkyWalker
|
|
|
|
|
hello..
i'm sorry i dont quite understand what u mean (sorry i'm a novice at this) ?? sorry i noticed the mistake i had with the i.. but now i do this and still have the same problem..
<br />
<br />
while((c = getchar()) != '\n') <br />
{ <br />
password[i]=c; <br />
i++; <br />
putchar('*');<br />
}
|
|
|
|
|
|
I do have a console application.. not using MFC at all.. still no luck with it
|
|
|
|
|
aaah, sorry for the mistake, it's '\r' instead of '\n'.
Another thing is the use of getch() in order not to show the input character.
I tried this and it works :
int main(int argc, char* argv[])
{
printf("Input password (ENTER when ready):\n");
char password[100], c;
int i = 0;
c = -1;
while ( true )
{
c = getch();
if ( (c == '\r') || (i > 99) ) break;
putch('*');
password[i++] = c;
}
printf("\nPassword was entered.\n");
return 0;
}
SkyWalker
|
|
|
|
|
the string "afx" appears frequently in the code of mfc, what does it mean ?thank you
-------------------
I am trying to love c++
|
|
|
|
|
I guess you are refering to the afx_msg prefix.
Well, this keyword suggests the effect of the C++ virtual keyword by distinguishing the handlers from other member functions belonging to a CWnd class. Anyway, the afx_msg keyword resolves to white space after preprocessing.
SkyWalker
|
|
|
|