|
Hi,
Does anyone know how to scroll to a particular position in a CHtmlView derived object? Ideally I would like the user to be placed in exactly the same position on the page when they hit the back button. I know how to hightlight the element/item on the page and using ScrollIntoView() have it be on top of the page, but the users want it to be exactly in the same position it was before (i.e. in the middle of the page.)
Any help or suggestion is greatly appreciated.
Thanks,
Al
|
|
|
|
|
Hi!
I've got a problem with the fprintf function. I want to write a character into a file by giving the function the decimal value of the character.
Here's some code to explain it:
char * p;
CString csHex = "0A"; // hex value of the character
int iValue = strtol(csHex,&p,16); // int value of the character
char c = iValue;
fprintf(fFile,"%c",c);
Sofar it's working quiet good, but there seems to be a problem with 10 as int value (= 0x0A). Instead of only writing the character for 0x0A to the file it also adds the character for 0x0D before 0x0A to the file.
Can anyone tell me, how i can only add the character for 0x0A, without 0x0D?
Thankx a lot and greets from germany. Mike.
|
|
|
|
|
What is the second parameter to fopen() ?
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
Se above. And remember: Text mode is default (Default can be changed, though).
|
|
|
|
|
kakan wrote:
Se above.
Above what? What are you referring to?
kakan wrote:
Text mode is default (Default can be changed, though).
I'm full aware of this.
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
I tried to complete your answer to the original question. You didn't mention this in your answer.
It wasn't my intention to offend your knowledge in any way. Sorry if you got that impression.
I should have replied to the original question. I'll do better next time.
Regards
kakan
|
|
|
|
|
kakan wrote:
I tried to complete your answer to the original question. You didn't mention this in your answer.
I did not give him the answer on purpose. My intent was to lead him to it rather than just outright give it to him. It's that old "Give a man a fish..." adage.
kakan wrote:
It wasn't my intention to offend your knowledge in any way. Sorry if you got that impression.
No offense taken.
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
fOutput = fopen(csOutputFile,"w");
How can i open the file in binary mode?
-- modified at 1:32 Friday 26th August, 2005
I've found it! Thanks a lot.
|
|
|
|
|
You have to open your file in binary mode and not in text mode.
|
|
|
|
|
I've got it. Thanks a lot.
|
|
|
|
|
hi! Can anyone suggest a good project topic for DCOM, distributed processing system?
|
|
|
|
|
Windows Management Instrumentation - its based on DCOM .
redindian
|
|
|
|
|
How the MDI framework handles Window menu Item.
with regards
Srikanth
|
|
|
|
|
I have App.exe which uses Dll.dll, I also add classical Microsoft manifest file App.manifest.exe to enable XP styles for common controls.
Now question how can I disable influence of manifest on Dll.dll
Which means I want that App.exe continue to use
comctl32.dll (ver 6) new one
but
Dll.dll should use
comctl32.dll (ver 5) old one
Load / Unload library - already try not helps
#define/#undefine IE_CONTLOLS - already try doesnt helps
I need to customize body of manifest somehow include or exclude styles in the dependency section
Thanks.
|
|
|
|
|
Hi,
Does anybody know how to retrieve parameters from any exe-files?
Shoot first, ask questions last
|
|
|
|
|
What do you mean by retrieving parameters from exe files ???? Which parameters ?
|
|
|
|
|
Im not sure if parameter is the right word.
for example: If you run an exe-file through cmd.exe:
"C:\testfile.exe -wnd"
parameter = "wnd"
|
|
|
|
|
With MFC? Look at CWinApp::m_lpCmdLine.
Without MFC? Look at lpCmdLine in WinMain
-Dy
|
|
|
|
|
thanks
Its parameter the right name for this?
|
|
|
|
|
yes, "command line parameters"
-Dy
|
|
|
|
|
Technically there is a difference between parameters and arguments. Most folks use them interchangeably, and thus can lead to confusion.
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
How do you call this what I want?
arguments or parameters?
|
|
|
|
|
void foo( int x )
{
}
void main( int argc, char *argv )
{
foo(123);
} if this program were started at a command prompt like myprog.exe -excavator, the argument would be -excavator.
"One must learn from the bite of the fire to leave it alone." - Native American Proverb
|
|
|
|
|
You can also access __argc and __argv in windoze applications both with and without MFC. Just include stdlib.h.
I recommend checking the source code for CCommandLineInfo for more enlightenment on this issue.
|
|
|
|
|
you need to do this from the source code, not from the command line ( or if that's the case, juste copy paste the arguments )
from the a simple C or C++ source code :
int main ( int argc, char* argv[] )<br />
{<br />
}
from a MFC application :
BOOL YouApp::InitInstance()<br />
{<br />
CCommandLineInfo cmdLineInfo;<br />
}
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|