Hello everyone/anyone,
I am a stutdent with UoP online. I just learning the IT world and the class I am taking right now is "Programming Concepts" using the C programming language. I have just wrote a program for a Tax Calclation, compiled it and now I am having issues with executing it because there is a "linking error" that says "Linker Error (Severity 8)
Destination string too small (256 bytes) to hold:
"c:\documents and settings\stephon woodland jr\desktop\uop\tax calculator\tax calculator in c_change1_ver3.obj,,c:\documents and settings\stephon woodland jr\desktop\uop\tax calculator\tax calculator in c_change1_ver3.map,c:\Program Files\Miracle C\ccl.lib ;" (257 bytes)"
Does anyone know what this means? If so, I would appreciate a hand so that I can fix this and turn in my assignment. Thank you a lot.
Stephon
3 4925
please post the code...It is very difficult to understand your problem...
Sorry for that. Here is my code: -
/*This is Tax Caluator program for Kudler Fine Foods. Based off of the Service Request hat was recieved from the organization, a program was needed that displays
-
the sales tax amount for each store location for a purchase amount of $125.00 or greater.*/
-
-
/*On June 20, 2007, the Kudler Fine Foods organization requested a change in the program. It was to modify the C program so that the user inputs the purchase amount.
-
Check the user's input for validity. In addition to calculating the sales tax for each location, calculate and display the total sale amount for each location.*/
-
-
/*On July 2, 2007, Kuddler Fine Foods made another change request to have the user select from a menu which store to use for the tax calculation.
-
Calculate and display the tax amount for the store selected and the total sale amount for that store.*/
-
-
//Tax Calculator
-
// by Stephon Woodland Jr.
-
// Version 4 with changes made on July 1, 2007
-
-
#include <stdio.h>
-
#include <ctype.h>
-
main(void)
-
{
-
//variable declarations
-
float DelMarRate;
-
float EncinitasRate;
-
float LaJollaRate;
-
float Price;
-
float SalesTax;
-
float TotalSaleAmount;
-
-
//variable initialization
-
DelMarRate = 0.0725;
-
EncinitasRate = 0.075;
-
LaJollaRate = 0.0775;
-
Price >= 125.00;
-
SalesTax = Price * DelMarRate, EncinitasRate, LaJollaRate;
-
TotalSaleAmount = (Price * DelMarRate, EncinitasRate, LaJollaRate) + Price;
-
-
//Program Header
-
printf("\n/tKudler Fine Foods Tax Calculator\n");
-
-
//printing variable contents to standard output
-
printf("\nThe value of DelMarRate is %f", DelMarRate);
-
printf("\nThe value of EncinitasRate is %f", EncinitasRate);
-
printf("\nThe value of LaJollaRate is %f", LaJollaRate);
-
-
//printing sales tax
-
printf("\nEnter Price: ");
-
scanf("%f", &Price);
-
if (Price <=125.00)//checking for validity of price entry
-
{
-
printf("\nThank you for shopping at Kuddler Fine Foods\n");
-
}
-
else
-
{
-
printf("Enter DelMarRate or EncinitasRate or LaJollaRate: ");//enter the sales tax rate of any store location
-
}
-
scanf("%f", &DelMarRate, &EncinitasRate, &LaJollaRate);//entering the sales tax rate
-
if (DelMarRate != 0.0725, EncinitasRate !=0.075, LaJollaRate != 0.0775)
-
{
-
printf("\nInvalid Input\n");//checking for validity
-
}
-
else
-
{
-
SalesTax = Price * DelMarRate, EncinitasRate, LaJollaRate;//Multiply Price by tax rate
-
printf("\nThe SalesTax is %f\n", Price * DelMarRate, EncinitasRate, LaJollaRate);//The sales tax amount is displayed
-
printf("\nThe TotalSaleAmount is %.2f\n", (Price * DelMarRate, EncinitasRate, LaJollaRate) + Price);//The Total Sale Amount
-
}
-
return 0;
-
}
-
/*The input validations have been implemented for the change request by the client organization. Input validity was for the price entry and the sales tax rate entry.*/
-
It's nothing to do with your code. Your compiler has a problem with the length of this file path:
"c:\documents and settings\stephon woodland jr\desktop\uop\tax calculator\tax calculator in c_change1_ver3.obj,,c:\documents and settings\stephon woodland jr\desktop\uop\tax calculator\tax calculator in c_change1_ver3.map,c:\Program Files\Miracle C\ccl.lib ;"
According to the error message it's only one character too long. Try renaming one of your files to shorten the name, or moving the project into a different directory with a shorter path, or checking if there's some setting in your compiler to fix it.
Since you posted your code, though, you might want to check your use of the comma operator in lines like: - if (DelMarRate != 0.0725, EncinitasRate !=0.075, LaJollaRate != 0.0775)
-
-
SalesTax = Price * DelMarRate, EncinitasRate, LaJollaRate;//Multiply Price by tax rate
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Skybuck Flying |
last post by:
Hi,
I think I understand now a bit better what the difference is between a c
compiler and a pascal compiler.
For example:
When compiling source code with a pascal compiler. The pascal...
|
by: Mary |
last post by:
Hello,
I am having a problem with the cl compiler. I have written a C class
(RegConnect.c) which uses Win32 API functions such as RegOpenKey,
RegCloseKey etc. Initially when I was trying to...
|
by: PCHOME |
last post by:
Hi!
I am looking for a good free IDE C Compiler.
Dose any have experience on using them?
Which is better? Bloodshed C or Miracle C?
Or anyother free IDE C Compiler you like to recomend?
...
|
by: Ondrej Spanel |
last post by:
I though that inline functions should be always visible only in the
compilation unit where they are defined - meaning if compiler cannot inline
them, they should be handled as if declared static....
|
by: NewsGroup |
last post by:
Hello,
I am trying to write a code to interface with ILOG OPL development
studio using their C++ libraries and header files. But I am encountering
linker issues, an example being -
error...
|
by: pwiekier |
last post by:
Hey everyone, I am presently enrolled at the University of Phoenix studying for my masters in IT Engineering. I am disabled and in a chair and computers are my craze at the young age of fifty-six...
|
by: yogesh |
last post by:
mysql in c++ initialize error occurs a simple program is executed in
redhat9.0 , using gcc 3.2.2 compiler version ...
#include <stdio.h>
#include <mysql.h>
#include <string.h>
int main()
{
|
by: dave0875 |
last post by:
I am a student at University of Phoenix and required to use the Miracle C compiler. I recently completed an assignment by using seperate functions to populate arrays of character strings, which...
|
by: M.Caggiano |
last post by:
I've write a function without errors but i've this message after
compilation:
*** Error1
how can i resolve this problem?
Many many thanks in advance.
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |