Jump to content

  • Log In with Google      Sign In   
  • Create Account

FREE SOFTWARE GIVEAWAY

We have 4 x Pro Licences (valued at $59 each) for 2d modular animation software Spriter to give away in this Thursday's GDNet Direct email newsletter.


Read more in this forum topic or make sure you're signed up (from the right-hand sidebar on the homepage) and read Thursday's newsletter to get in the running!


VC++ Prob


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
8 replies to this topic

#1 PsYcHoPrOg   Members   -  Reputation: 115

Like
Likes
Like

Posted 15 February 2000 - 12:38 PM

Those of you with VC++ as their compiler will know that whenever you create a successful pointer to an object of a structure/class with -> or use the period and directly access it, a little popup window comes up with all of the members of the class/struct. Well I am having a problem, after I type in the "->", nothing pops up. I''m assuming that this means that the pointer to the structure was not successful. Here''s the code: (I boldfaced the part where it doesn''t work)

int GameInit
{
	if(FAILED(DirectDrawCreate(NULL, &lpdd, NULL)))
	{
		//error
		return(0)
	}

	if(FAILED(lpdd->SetCooperativeLevel(//not important
Games are the path to another dimension.

Sponsor:

#2 Gromit   Members   -  Reputation: 144

Like
Likes
Like

Posted 15 February 2000 - 12:57 PM

Only if you have v6. v5 and under doesn''t have the code complete feature. Unless I''m missing something.

#3 shmaLbus   Members   -  Reputation: 122

Like
Likes
Like

Posted 15 February 2000 - 01:00 PM

if you have v6.0..
i know there are more reasons prolly but if the file that contains the prototype or actual function body or the datatype (like ddraw.h) is in the "External Dependencies" folder the popup containing it''s members/arguments won''t popup.

#4 Torval   Members   -  Reputation: 122

Like
Likes
Like

Posted 15 February 2000 - 01:01 PM

Well... this feature is great when it works, but sometimes it simply doesn''t... occasionally it will start working again after closing visual c++ and then loading it back up again. And sometimes, some things it refuses to do this feature no matter what you do.

Torval


#5 shmaLbus   Members   -  Reputation: 122

Like
Likes
Like

Posted 15 February 2000 - 01:03 PM

really? when it doesn''t work for me it''s usually my previous post or i forgot to include it.

#6 LaughingD   Members   -  Reputation: 151

Like
Likes
Like

Posted 15 February 2000 - 01:08 PM

The autocomplete will fail to autocomplete if you forget important things like semicolons above where you are trying to get it to autocomplete...

if(FAILED(DirectDrawCreate(NULL, &lpdd, NULL)))
{
//error
return(0)
}
if(FAILED(lpdd->SetCooperativeLevel(//not important

Notice your missing semicolon after return(0)

It will also fail if you don't get the capitalization or other things right.

I also find that I have to include the ddraw header in my project (ie. add it to the project) to get the ddraw functions to autocomplete.



Mark Fassett
Laughing Dragon Entertainment
http:\\www.laughing-dragon.com

Edited by - LaughingD on 2/15/00 7:09:32 PM

#7 PsYcHoPrOg   Members   -  Reputation: 115

Like
Likes
Like

Posted 15 February 2000 - 01:16 PM

Thanks a lot. If syntax errors will cause autocomplete to fail, then you have solved my problem. Thanks for your help, everyone. Should you come across another reason autocomplete is failing, please post it up.;-)

#8 Spellbound   Members   -  Reputation: 122

Like
Likes
Like

Posted 15 February 2000 - 04:44 PM

Sometimes the autocomplete doesn''t work even though the code is compilable. In such cases I usually need to rebuild the whole project so that the precompiled headers are renewed.

Other times it doesn''t work simply because VC++ cannot find the declarations, usually when working with libraries and such.

#9 PsYcHoPrOg   Members   -  Reputation: 115

Like
Likes
Like

Posted 16 February 2000 - 12:28 AM

I found out the problem. I get this error which means that the struct LPDIRECTDRAW4 is not recognized although I did include ddraw.lib in my project as well as ddraw.h. Here is the error, the code is in the post "COMPILER ERROR". here is the error:

error C2501: ''LPDIRECTDRAW4'' : missing storage-class or type specifiers







Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS