Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 787013
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T21:08:05+00:00 2026-05-14T21:08:05+00:00

as i said i get this horrible error i dont really know what to

  • 0

as i said i get this horrible error i dont really know what to do anymore

 float n= xAxis[i].Normalize();

thats where i get the error and i get it cuz normalize is a void function this is it

void CVector::normalize()
{
 float len=Magnitude();
 this->x /= len;
 this->y /= len;  
}

i need normalize to stay as void tho i tried normal casting like this

float n= (float)xAxis[i].Normalize();

and it doesnt work also with static,dynamic cast,reinterpret,const cast and cant make it work any help would be really apreciated…
thank you >.<

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T21:08:06+00:00Added an answer on May 14, 2026 at 9:08 pm

    A void function doesn’t return anything, so there’s nothing to assign to n.

    You should return some value from normalize to assign it to n.

    float CVector::normalize()
    {
     float len=Magnitude();
     this->x /= len;
     this->y /= len;
     return 10.0;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

It is currently said that MD5 is partially unsafe. Taking this into consideration, I'd
Rather than population said DOM object with an external page such as HTML CFM
I've heard it said that the Entity Framework is overkill or that it's difficult
If it said oneword, then I could write #oneword, but what do I write
Or better said: When to use array as a field data type in a
Moments ago Jeff Atwood said the following on twitter : Look, I love rapid
As Knuth said, We should forget about small efficiencies, say about 97% of the
Well the docs finally said it, I need to take it easy on my
It has been said that C# can be regarded as a functional programming language,
Erm - what the question said. It's something I keep hearing about, but I've

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.