|
I've read that you can use an ActiveX control, but this control seems to be very poorly documented. Besides, this is not really what I want, I just want to launch the acrobat reader or writer.
Thanx anyway.
|
|
|
|
|
[RANT]
it is documented like 99.9% of all the ActiveX Controls.. NOT AT ALL
[/RANT]
and i've quickly watched the functions of the interfaces.. it doesn't look like it has a "goto page" - function.. but you can call the "goto next page" function in a loop
yaya.. the joys of programming
"I'm from the South Bronx, and I don't care what you say: those cows look dangerous." U.S. Secretary of State Colin Powell at George Bush's ranch in Texas
|
|
|
|
|
I am developing a small windows XP application that iterates over a set of files in a folder and extracts information from the files properties (right-click, select properties and then the summary tab) like title, summary etc.
The article Microsoft Knowledge Base Article - 186898 shows how to do this for compund docuemnts like Word documents and so on, using IPropertyStorage.
However, In my application, I access non-compound documents (jpeg-files mostly). They can also have attributes like the office files, but IPropertyStorage doesn't seem to be the right choice for finding the information. Does anyone have any excpreience with this?
Regards // Jonas Pettersson
Regards // Jonas
|
|
|
|
|
It does work for JPG files, assuming they have information to show. You will, however, need to use StgOpenStorageEx() instead.
Five birds are sitting on a fence.
Three of them decide to fly off.
How many are left?
|
|
|
|
|
Can anybody provide me a sample code in c++ for creating classes using absrtact factory design patterns.
Only a layout will work (one bacse class with 1 -2 methods, and one derived class).
|
|
|
|
|
C++ Programmers needed at our site at www.losttware.com for new project.
|
|
|
|
|
Try in this forum[^] instead.
HTH,
K.
New, what do you own the world?
How do you own disorder?
|
|
|
|
|
Unlike a global variable that can be misused, does a global 'typedef' pose any such danger?
Are there any special constraint where I place a 'typedef'?
Thanks for any insight into this matter.
William
Fortes in fide et opere!
|
|
|
|
|
Check the below article.
In global scope, variables defined will be global in scope.
In local scope, variables defined will be local in scope.
If a variable is local, it can be redefined in global scope. Any previous global variable is overwritten and the local definition no longer exists.
If a variable is global, it can be redefined in local scope. Any previous local variable is overwritten and the global definition no longer exists.
Global variables (and methods) created by the concept instance have a super-global scope, they are visible to all instances providing the instance has not already defined the variable in local or global scope. If the instance un-defines its own global and local copies of the variable, then the variable defined in the concept instance becomes visible. Local variables created in the concept instance are not accessible by other instances and visa versa.
A common mistake when trying to create a local variable over top of a global variable is not to typedef it. For example:
// Define global scope
global ;
// Define a global variable (we didn't use a typedef, so the type is 'list'
a = 100 ;
// Define local scope
local ;
// The following statement simply overwrites the global variable 'a'
a = 101 ;
// But the next statement creates a new local variable because it was typedef'd
int a = 1 ;
CH.L.RAMANA RAO.
chlramanarao@sify.com
|
|
|
|
|
Are you sure you read the question right?
William
Fortes in fide et opere!
|
|
|
|
|
Whilst it cant be misused like a global (you cant change it from numerous places in your code, for example), it is suspectable to a namespace clash with something else of the same name. Just follow the standard rules of defining it before use, putting it into the smallest scope you can, and if necessary, use a namespace.
|
|
|
|
|
Thanks for replying.
What you said, makes a lot of sense!
William
Fortes in fide et opere!
|
|
|
|
|
I've been using SetWindowOrg for quite a while now, but it still bugs me that I don't completely understand what's happening with the "y" coordinate. I know that SetWindowOrg maps the logical (x,y) coordinates to the physical device's (0,0) coordinates (upper left), but I don't understand the sign associated with the "y" coordinate of SetWindowOrg. For example, the following code will draw a circle in the center of the screen (assuming that you've got a device context):
CRect rect;
GetClientRect(&rect);
CPoint point(rect.Width()/2, rect.Height()/2);
dc.SetMapMode(MM_LOENGLISH);
dc.DPtoLP(&point);
dc.SetWindowOrg(-point.x, -point.y);
dc.Ellipse(-50,50,50,-50);
So the origin has been shifted to the center of the screen. Here's my question. Why must negative point.y be sent to SetWindowOrg and not positive point.y? After all, in the MM_LOENGLISH mapping mode the coordinate system is with positive y up and negative y down. So if this code makes the logical upper left be in the second quadrant somewhere (-x,y), which is where it has to be if the logical origin is now in the center, then why do I have to send a negative point.y into the SetWindowOrg? Sending a positive point.y makes more sense, but sending a positive point.y ends up with the circle off the screen. The sign associated with point.x makes sense.
Ed
|
|
|
|
|
I'm trying to align static text windows on a CFormView dialog. I used the visual editor, but sometimes there's a larger gap between text windows than others, so I want to make this even.
I've tried to adjust the window positions in the OnInitialUpdate function. The confusing part to me is that the following 4 lines end up putting my static text window in random places within my application. Between the 3rd and 4th lines of code I would obviously adjust the CRect borders, but I was hoping somebody could give me a reason as to how and why these lines of code cause my window to appear (if it shows at all) in random locations within my dialog. How can I fix this? Thanks a ton!!!
CWnd * MyWindow = GetDlgItem( NUMBER_STATIC );
ASSERT( NUMBER_STATIC );
MyWindow->GetWindowRect( &WindowRect );
MyWindow->MoveWindow( &WindowRect );
Douglas A. Wright
dawrigh3@kent.edu
|
|
|
|
|
you're using GetWindowRect, which is the rect of the window on the screen.
GetClientRect would return the control rect on the client x,y
BUT, grabbing a rect, then moving the window right back to the same position will do absolutely nothing, even if you do it right.
|
|
|
|
|
GetWindowRect() retrieves the window position in screen co-ordinates (i.e. 0,0 is the top-left corner of the screen. MoveWindow() moves the window to the specified client co-ordinates of its parent window (i.e. 0,0 is the top-left corner of the parent window).
You need to peform a conversion between the screen and client co-ordinates before moving the window as follows:
MyWindow->GetWindowRect( &WindowRect );
ScreenToClient( &WindowRect );
// Adjust the position here...
MyWindow->MoveWindow( &WindowRect );
Dave
http://www.cloudsofheaven.org
|
|
|
|
|
I put a CEdit control into a simple frame OLE Active X MFC project, and created it on the OnCreate function, and it works fine, except that when I embed the active x control into a webpage, it will not receive the backspace messages.
Where did they go?, what took them? Is it internet explorer's client window that's filtering the keypress message?
Here is my project example, which is simply a standard MFC Active X control VC++6 project wizard output with a public CEdit member m_edit, that is initialized on the component's OnCreate function.
Please take a look and let me know what's going on
http://www.employsoft.com/test.zip[^]
|
|
|
|
|
Most likely they are going to the IE main window. The backspace causes IE to navigate back one page.
"What lies behind us and what lies before us are small matters compared to what lies within us." -- Ralph Waldo Emerson
FLUID UI Toolkit
|
|
|
|
|
ok, now what?
can I pretranslate the IE client WND's messages from inside an embedded component?
What can I do?
|
|
|
|
|
|
|
from MSDN
Some objects might want to support the inside-out activation model by marking themselves with the OLEMISC_INSIDEOUT flag. In this model, a single click on the object causes it to be activated in place.
mk:@MSITStore:C:\Program%20Files\Microsoft%20Visual%20Studio\MSDN98\98VS\1033\inole.chm::/D1/S12f9.htm
Therefore, to select the object as a whole, the user selects the border, or some other handle, provided by the object or its container. For example, the container
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwue/html/ch12f.asp
I found out that If i click the top level window(the one with the elipse drawn from my example), the backspace will work.
Now I know why it wouldn't work in the first place, the ocx has the OLEMISC_ACTIVATEWHENVISIBLE flag, but it WON'T activate when visible, as the quote above from suggests, unless the user clicks the control border.
Now, who in their right mind is going to click the border instead of the CEdit in the control?
jdunlap's link doesn't work, because my example is an active X control and not a ATL Com control, so the activateinplace method is not exposed.
Also, MDunn's suggestion won't work either because it's not a keystroke problem
|
|
|
|
|
how to load and write data into SQL server? please show me ex.
thanks
Nho'c Ti`
|
|
|
|
|
SQL's INSERT command would probably be a good start
I'm drinking triples, seeing double and acting single
|
|
|
|
|
hello ppl,
i am making a very simple program that is a window application. pretty much a basic hello world program to just get myself started and i have the program set up. its written in c++ and compiled with visual basic 6.0
my question is how do you pick text colors and font size? i also have a couple console programs (they open with a dos command prompt) and i would like to know how to do it in those as well. its been making me insane cause its taking so long to find something as simple as the code to change text color.
mabie i would even like to add a next page to it so u can toggle pages, but i want to take it one thing at a time and try and figure this color thing out first.
i would appreciate any help or advise, thank you.
|
|
|
|