|
Is there some specific reason you don't just make a HTTP Post request?
led mike
|
|
|
|
|
well i like to understand this methodes. because i need them later to find links and pictures in the document
|
|
|
|
|
I assume you are working inside of DOM from the web browser object?
If so you directly interact with the elements them self, no need to try to submit the post directly as the browser object will do that for you.
System::String^ part = "XYZ";
HtmlElement^ x = WebBrowser::Document::GetElementById("PartNum");
if (x != nullptr)
{
x->SetAttribute("value", part);
x = WebBrowser::Document::GetElementById("Submit");
if (x != nullptr)
{
x->InvokeMember("click");
}
}
|
|
|
|
|
How do I read in words from a text file one at a time? I do not want the blank space or puncuation.
The file is long.
|
|
|
|
|
While there's still data in the file
{
Read an arbitrary amount of the file
Loop through the data read, parsing out the words
}
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
So like this?
while (!eof())<br />
while (fin != '\n')<br />
{<br />
fin >> words[i];<br />
i++;<br />
}<br />
}
|
|
|
|
|
Something like that should work, although it looks like you're parsing lines, not words.
Many stream classes have built-in support for reading lines of text, but I know of none that
parse words.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
The thing is I need to read them in from a file. Then check then againest the words before it and place them in a binary tree and if that word is in the tree I need to increament a counter to show that there are 2 or have ever many of that word are in the file.
Cary
|
|
|
|
|
|
led Mike.
thanks so much this is a great help.
|
|
|
|
|
Okay I have a question
const int MAX = 30;<br />
char fileName[MAX];<br />
char name[MAX];<br />
cout << "enter the file name: " << endl;<br />
cin >> name;<br />
fileName = name + ".txt";
My question is when I try and compile this it give me this error.
invalid operands of types `char[30]' and `const char[5]' to binary `operator+'
What is wrong with this code. I was told it is correct however I can not get it to compile.
led mike thanks for the great help on the last problem.
modified on Wednesday, April 2, 2008 3:55 PM
|
|
|
|
|
Cary D. Rutherford wrote: What is wrong with this code.
You can't concatenate char arrays like that in C/C++.
Here's one way you could build fileName:
strcpy(fileName, name);
strcat(fileName, ".txt");
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thanks Mark. I was told wrong. I thank you for clearing this up for me.
Now it works and I understand.
Thank you again.
Cary
|
|
|
|
|
hi
i have to add the gif file into to my datagrid.
i was very new to vc++ dotnet application. i tried to load gif file like bitmap file, it display the image not the action in the file.
how do i import gif file into datagrid??
thanks in adv
shivapalanirajan k.
iam a software engineer working for varisis technologies bangalore
|
|
|
|
|
I cannot run my application .exe on other pc. Error message like this "The application has failed to start because the application configuration is incorrect. Reinstall the application may fix the problem." But I can open the application on my own pc which I built and debugged the application. What may be the problem?
|
|
|
|
|
Member 4542272 wrote: What may be the problem?
The problem very likely is that you have not fulfilled your responsibility as a developer and read the MSDN Documentation on Deployment for the tools you used in constructing your application. Did I get it right?
led mike
|
|
|
|
|
I am still a student. Every semester I change to use different software depend on the project. Frankily speaking, this is the first time I use visual studio. I do admit that I have skipped the MSDN Documentation due to the time constraint. I just did the coding, built and debugged it to come out the .exe file then assumed that it can be run on same window platform on other machine. Did my answer statisfy you?
|
|
|
|
|
Member 4542272 wrote: Did my answer statisfy you?
Yes, I was right. Now let's recap. You don't have time to read the deployment documentation but you do have time to read the same information if someone types it into a forum message? I suggest you take a course in Logic while at the University, it tends to come in handy while developing software.
Member 4542272 wrote: then assumed
Also you will find that making assumptions doesn't come in very handy while developing software.
led mike
|
|
|
|
|
Ya, I will have time to read it because that is the solution. Let see a scenario: if you are going to have test 2 days later and still have ten chapters not yet finish study, even worse that you no pay attention during lecture, what will you do? As for me, i will hope that lecturer can give some tips or go through past year paper question to get some hints. That is what I am doing.
When I started this thread, I didn't have any clue about the problem. If solution is too long to write in forum, I would just expected that someone give me a direction, e.g, read the MSDN deployment documents. Now I will read it, thats all. One more thing, in my field of study, assumption is important and a course of logic not exist in my university.
|
|
|
|
|
Member 4542272 wrote: One more thing, in my field of study, assumption is important
Ok, good luck
led mike
|
|
|
|
|
Hi everyone,
I've got a problem with dialogs,
After I open a dialog I want to call a function in the parent dialog...
But when I include the parent header file it gives me errors...
Please help me...
Thanks.
Every new thing you learn,Gives you a new personality.
|
|
|
|
|
dSolariuM wrote: when I include the parent header file it gives me errors...
What kind of errors...exactly?
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
When I include the parent header file it gives the error that says:
"childclass" not declared...
Every new thing you learn,Gives you a new personality.
|
|
|
|
|
Hi,
Please post the code snippet and state in which line are you getting the compile error.
Best Regards,
Suman
--
"Programming is an art that fights back!"
|
|
|
|
|
<br />
#include "Form2.h"<br />
Form2 ^f=gcnew Form2;<br />
f->ShowDialog();<br />
<br />
#include "Form1.h"<br />
<br />
Error: <br />
syntax error : identifier 'Form2'<br />
error C2065: 'f' : undeclared identifier<br />
error C2065: 'Form2' : undeclared identifier<br />
error C2227: left of '->ShowDialog' must point to class/struct/union/generic type<br />
Every new thing you learn,Gives you a new personality.
|
|
|
|