![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
So Fucking Banned
Join Date: Aug 2004
Location: Dearborn, MI
Posts: 5,921
|
Computer programmers, help me
40 C:\Documents and Settings\william\Desktop\ECE370\ass5\main.cpp no matching function for call to `strlen(std::string&)'
wtf is this? I have #include <string.h> |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Beer Money Baron
Industry Role:
Join Date: Jan 2001
Location: brujah / gmail
Posts: 22,157
|
show the previous lines ? the one using strlen() ?
__________________
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Confirmed User
Join Date: Nov 2005
Posts: 647
|
"no matching function"
answers your question, no?
__________________
money talks and bullshit walks. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Workin With The Devil
Industry Role:
Join Date: Oct 2004
Location: West Bloomfield, MI
Posts: 51,532
|
your calling a function that you have declared
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
So Fucking Banned
Join Date: Aug 2004
Location: Dearborn, MI
Posts: 5,921
|
I have this
struct stats{ string name; int cost; }; stats blah[2]; how can i find the length of blah[0].name ? |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Workin With The Devil
Industry Role:
Join Date: Oct 2004
Location: West Bloomfield, MI
Posts: 51,532
|
where are you declaring blah?
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
So Fucking Banned
Join Date: Aug 2004
Location: Dearborn, MI
Posts: 5,921
|
that is irrelevant. consider it in main.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#8 |
Workin With The Devil
Industry Role:
Join Date: Oct 2004
Location: West Bloomfield, MI
Posts: 51,532
|
whats on line 40?
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#9 |
So Fucking Banned
Join Date: Aug 2004
Location: Dearborn, MI
Posts: 5,921
|
just part of a conditional statement. I just need to know the function to get the length of a string.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#10 |
Confirmed User
Join Date: Nov 2005
Posts: 647
|
its probably string.length or string.len (ie: length(string))
__________________
money talks and bullshit walks. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#11 |
Beer Money Baron
Industry Role:
Join Date: Jan 2001
Location: brujah / gmail
Posts: 22,157
|
I think it's just being used incorrectly. Maybe this will help.
http://www.programmingforums.org/for...ad.php?p=43453
__________________
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#12 |
So Fucking Banned
Join Date: Aug 2004
Location: Dearborn, MI
Posts: 5,921
|
Thanks i found it. I saw it written online as length() and thought i used it like length(blah[0].name)
when it is actually supposed to be blah[0].name.length() thanks for looking. |
![]() |
![]() ![]() ![]() ![]() ![]() |