Adding new COM Interface version

Leave a comment

Just for my self and other people like me who forget interestingly fast, and do not wish to get E_NOINTERFACE from C++ QueryInterface method after they add new COM interface version for maintaining backward compatibility for the COM object.

4 places to add the new version info..

1-In the idl file used for the description of the interface, Add the new interface and make sure you put a new UUID for it, make sure it inherits the old interface


[
 object,
 uuid(69BBF687-D8AE-4f7c-8E61-96DD47FA12C8),
 dual,
 helpstring("OldInterface Interface"),
 pointer_default(unique)
 ]
 interface IOldInterface : IDispatch
 {

//Some old functions

};

[
 object,
 uuid(9BFB8CD2-C090-4e37-A9AB-AE001B9EB4DC), //new UUID
 dual,
 helpstring("INewInterface Interface"),
 pointer_default(unique)
 ]
 interface INewInterface : IOldInterface
 {
//Some new functions

};

More

With Ubuntu [A Fresh Install]

4 Comments

No, the old install didn’t crash !!!

i just was very anxious about the new Ubuntu release (Karmic Koala), so i installed the RC version

and as u know i hate to install a fresh install of any OS until the currently running one crashes, hangs and cries to let it die 😀

More

Manipulating Visio “Shape Data” using VBA

2 Comments

recently i needed to write a macro that processes an MS  Visio 2007 page and and does some actions based on the contents of a custom defined stencil shapes, where this contents are saved as a Shape Data field in the shape

More

Troubleshooting in ACM-ICPC Contest

2 Comments

i’ve participated in many contests as organizer, specifically in the technical stuff which is mainly two portions

  • The IDE which is mainly “eclipse
  • The contest communication tool which can’t be except “pc2”

and in the last contest i’ve participated in it’s technical preparations i faced a number of troubles

lets take them one by one

1.Teams don’t connect to the Server which is a Linux Machine

  • Solution : before you open the server edit the “pc2server” file and edit this line
  • java -Djava.security.policy=policy.ini $PC2CN $*
  • to be
  • java -Djava.rmi.server.hostname=”10.106.0.35″ -Djava.security.policy=policy.ini $PC2CN $*
  • of course change the ip according to your server ip

and make this edit in all the executables you will run {team, board, judge…..}

More

psssst.. Somebody’s watchin’

5 Comments

well

i’m gonna start with an apologize to google 😀

i thought they had a stupid bug in thier chrome

but some how they were not the stupid … neither were I 😀

i’m gonna show you what happened every time i use chrome to navigate to any website

More

A JAVA Function !!! [Problem NOT of the week]

3 Comments

As my two friend Alaa & Foaud are writing [Problem of the week] 

i am also writing Problem NOT of the week 😀

bcoz i wont write a problem weekly in addition to i dont know the solution of my problems 🙂 almost…

.

.

during my internship time i spent in Mentor Graphics Cairo i needed to implement a function

and when i started coding i found that it was impossible to do it that way

may be there is a way that function can be implemented but i dont know how due to my small experience with JAVA

Here is the problem definition:

Programming Language used : of course u know its JAVA what r u looking at 😛

More