|
|
|
you registered CodeProject for that ? you suck dude...
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
This is not the correct forum for your inquiry.
Post a specific programming question, or move along.
------- sig starts
"I've heard some drivers saying, 'We're going too fast here...'. If you're not here to race, go the hell home - don't come here and grumble about going too fast. Why don't you tie a kerosene rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt
"...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
How can i get an image from Internet Explorer,
which is created as an internet explorer object.
|
|
|
|
|
does right-click on the image and "save-as" works ?
on the other hand, I would assume that you will need to parse the HTML code to find an tag, then parse the target string and collate the site URL to that string; use some FTP or HTTP protocol to download the file locally.
but what is "an internet explorer object" ?
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|
|
Maximilien wrote: but what is "an internet explorer object" ?
Presumably an instance of IWebBrowser2 .
"Take only what you need and leave the land as you found it." - Native American Proverb
|
|
|
|
|
I know this works, but i want automate this using IWebBrowser2 Object with the Document Interface
|
|
|
|
|
Hi all,
First I know the handle of a window with a embeded webbrowser , in other process, how can i get IWebbrowser2 of the webbrowser? thx!
WalkSnail
|
|
|
|
|
i find a article about get ihtmldocument2 from hwnd,
url: http://support.microsoft.com/kb/q249232/
how can i get iwebbrowser2 from ihtmldocument
walksnail
|
|
|
|
|
Mr. Baken
You are right. I am trying to do the same thing. I want to read one character at the time from the file and then interpret it as an integer. Plz check that in fact i is an intege and i am passing it to function as character pointer as it is function requirement.
Plz tell me how can i get one charecter or integer from the file at a time. Also i want to do one more thing which is not related to above problem. That is i want to go to a perticular location in file and then read a 4 bit number from there. How to do that?
Thank you for help.
Aqueel A. Mirza
We Believe in Excellence
-- modified at 2:36 Tuesday 1st November, 2005
|
|
|
|
|
Hello again.
The fact that you are casting the integer pointer to a char pointer doesn't matter at all. It's just pointers, not the real values.
I suggest this code (modified from your example, and not tested):
unsigned int i = 0;
int count = 0;
unsigned char ch;
ifstream fin("data.bin", ios::in | ios::binary);
while (count != 5120)
{
fin.seekg(count);
cout <
|
|
|
|
|
Thanks Mr. Baken
i wrongly typed 4 bit. It was 4 byte number. Should i just use a long int to get data and it will automatically get 4 bytes from a file or i would have to do something else.
Thanks
Aqueel Ahmad Mirza
We Believe in Excellence
-- modified at 5:13 Tuesday 1st November, 2005
|
|
|
|
|
Hi there!
I suspected you wanted an integer, that's why I put an '?' in the text.
You can use either an unsigned int or an unsigned long, they both are 32 bits (== 4 bytes) long (in Win32/VC++).
I suggest You use unsigned int.
But beware! The value can be stored in two different ways, depending on the CPU that wrote the file (or the specs of the file). Little endian and Big endian. Intel CPU's use little endian, Motorola CPU's (Macintosh) use big endian.
If you want to know more about endianness, Google for "endian intel motorola"
So if the value you get is incorrect, the file is written using big endian. Then you will need to convert the value you read to little endian.
Here is a function that will do that for you. Call it only if you need it:
<code>
void SwapInt(void* ap)
{
unsigned char* p;
unsigned int a;
p = (unsigned char*) ap;
a = (unsigned int) p[0];
p[0] = p[3];
p[3] = (unsigned char) a;
a = (unsigned int) p[2];
p[2] = p[1];
p[1] = (unsigned char) a;
}
Usage:
unsigned int ui;
ui = <something>;
// Now convert ui from big endian to little endian
SwapInt(&ui);
// Now ui is in little endian
</code>
-- modified at 7:14 Tuesday 1st November, 2005
|
|
|
|
|
Do you know that you can give score (points) to answers that has been helpful to you?
Have a look in the lower right corner, click on a number, the higher, the more appreciated...;)
-- modified at 6:58 Tuesday 1st November, 2005
|
|
|
|
|
I am doing a project to change computer name which is in the domain. I tried many way but all failed.
First, I used NetRenameMachineInDomain function, function return succeeded, and the computer name changed. But it isn't in domain again.
Then, I tried to change computer name, then use NetJoinDomain function. Function return succeeded again, but the computer is not in domain.
Computer name after changed shows ComputerName.DomainName.com, that is correctly, but there is not "DomainName\Domain Admins" in local Administrators group. I can't logon the computer by the domain user, so I think the computer is not join in the domain really.
How can I do or there is another step I must do after use NetJoinDomain function?
Pls help me!
Thanks a lot.
RickPan
|
|
|
|
|
hi
i want add an image to vc++ project with Transparent mode.
please help me.
|
|
|
|
|
|
Hello
I am working with binary files in c++. What i am doing is that i am reading at every 5th position in a binary file. if there is 0 then break the loop.
I wrote the following code
what is error in it. I wrote 1 at the start of the file. But it is not showing that 1
Code is
int i = 0;
int count = 0;
ifstream fin("data.bin", ios::in | ios::binary);
while (count != 5120)
{
fin.seekg(count);
cout <<i<<' ';
="" fin.read((reinterpret_cast="" <="" char="" *="">&i, sizeof(i));
if (i == 0)
break;
count+=5;
}
Please reply...
Thanks>
Aqueel A. Mirza
We Believe in Excellence
-- modified at 1:26 Tuesday 1st November, 2005
|
|
|
|
|
Hello.
You are reading sizeof(i) no of charaters from the file. Is that what you want?
i is an integer, so sizeof(i) will evaluate to 4 (bytes).
My guess is that you really want to read one character at the time from the file and then interpret it as an integer, right?
The read it as an unsigned char, with sizeof(unsigned char)
Then, cast it to ant int.
|
|
|
|
|
How do I create a folder in the Program Files directory programatically? I haven't programmed in Win32 the last few years and don't have my win code to refresh my memory. I know it is some COM object function that gets the special location like Trash, Program Files, History..
Thanks in advance.
|
|
|
|
|
LPITEMIDLIST pid;<br />
HRESULT hr;<br />
hr = SHGetSpecialFolderLocation(m_hWnd,0x0026,&pid);<br />
<br />
TCHAR path[MAX_PATH];<br />
SHGetPathFromIDList(pid,path);<br />
<br />
LPMALLOC mal;<br />
SHGetMalloc(&mal);<br />
mal->Free(pid);
I hope it works, and is without errors.
this is this.
|
|
|
|
|
I have used the MFC application wizard in Visual C 6.0 to create a FormView application. The resultant FormView contain the word "Untitled" before the program name I supplied. What is an acceptable method of eliminating the word "Untitled"?
|
|
|
|
|
I believe SetWindowText on the main window is what you need.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hi,
Put the following code in CMainFrame::PreCreateWindow
cs.style &= ~FWS_ADDTOTITLE ;
--
======
Arman
|
|
|
|