ndeniche 402 Posting Virtuoso Featured Poster

try wrapping everything into a

<div class="wrapper">
...
</div>

container, with the following properties (or you can play with your own):

.wrapper
{
    width:1000px;
    left:0;
    right:0;

    margin-left:auto;
    margin-right:auto;
}

Next, remove the margin-right from your nav menu.

The wrapper will act as a margin guide for the rest of the document, so the alignment for the elements will therefore be automatic.

ndeniche 402 Posting Virtuoso Featured Poster

Try removing line 55. The data print into the page counts as a page header, so the header("location...") function won't work.

ndeniche 402 Posting Virtuoso Featured Poster

You can create a comboBox that will show the user the product options, and for each item index assign a price using a select case decision.

When the client adds something, add the amount associated to the comboBox index to an accumulator variable (such as subtotal , and when he removes, substract the associated value from it.

As for the discount button, I guess it's pretty much self explanatory.

Come back when you've worked your way throughout the code, ok pal?

ndeniche 402 Posting Virtuoso Featured Poster

I guess what Chilton is trying to say is that you should compare your do... while loop to MAX_ACCOUNTS, instead of the constant number 10.
So, instead of this

do
{
... 
}while(input != QUIT && counter < 10);

Do this:

do
{
... 
}while(input != QUIT && counter < MAX_ACCOUNTS);

That way you can change the constant value anytime, and you actually use the constant variable you created.

Chilton commented: Yup. +2
Vindal commented: Very Helpful +1
ndeniche 402 Posting Virtuoso Featured Poster

Try creating a css class for a <div> container for the whole page (header, content and footer). This way, all your absolute positions and float properties will be included in that container.

Next, in the navbar class, you got

float:right;
margin-left:-225px;

If you tell it to float right, there's no need to specify a left margin.
Another thing: sicne you're telling the #nav container to float right, tell the <img> element to float left. That way they won't overflow throughout the header.

ndeniche 402 Posting Virtuoso Featured Poster

Since you are counting into counter each time an account gets data entered, you can use it as the sentinel for your print loop

ndeniche 402 Posting Virtuoso Featured Poster

Or, you can create a constructor for your class, so that it initializes the class's members so that they don't store garbage.

You then call the constructor when declaring your class array.

Or, as you are doing it, instead of

for(counter = 0; counter < MAX_ACCOUNTS; counter++)
{
accounts[counter].computeInterest();
}

use a new variable for the if loop and use the counter as a sentinel:

for(int i = 0; i < counter; i++)
{
accounts[i].computeInterest();
}
ndeniche 402 Posting Virtuoso Featured Poster

You can't send a header("location:page.php") command after sending html code to the webpage. You must do it when the page's headers haven't been loaded yet.

Though you can try doing it with a bit of javascript.

ndeniche 402 Posting Virtuoso Featured Poster

In your css file, inside the mainbody id you got the following:

.mainbody {
margin-left: auto;
margin-right: auto;
margin: 0 auto;
background: url(images/white-frame.png) no-repeat;
height: 702px;
width: 1000px;
}

The width property exceeds the screen's resolution... try reducing it to the body's container's width.

ndeniche 402 Posting Virtuoso Featured Poster

Somewhere in your code you're assigning a value that doesn't match the destination variable's type. Be sure to double check it

ndeniche 402 Posting Virtuoso Featured Poster

Ok, where you put HOME you should put Main , which I suppose is the name of the parent's class

ndeniche 402 Posting Virtuoso Featured Poster

Always a pleasure ;)

ndeniche 402 Posting Virtuoso Featured Poster

You can use <div></div> s to locate two images wherever you want in the page and use them as backgrounds using the position:absolute; property.

ndeniche 402 Posting Virtuoso Featured Poster

You can pass it through the constructor of the second panel's class constructor, like this:

public GameScreen(String name)
{
...
}

So when you call it from the first panel, you call it this way:

new GameScreen(txtName.Text).show();
HelloMe commented: Straight to the point and without cryptic extra explainations. +2
ndeniche 402 Posting Virtuoso Featured Poster

Try InstallShield

ndeniche 402 Posting Virtuoso Featured Poster

What about passing the variable as a parameter for the other panels constructor?

ndeniche 402 Posting Virtuoso Featured Poster

to make it go all the way down the screen there's a trick:

<div style="width:500px;top:0;bottom:0;margin:auto;">&nbsp;</div>
ndeniche 402 Posting Virtuoso Featured Poster

There is an html attribute called "width". You can specify an element's width with this attribute.

Do a quick google search for css and you shall get along pretty good.

ndeniche 402 Posting Virtuoso Featured Poster

That's because you're not specifying the Connection Property for da.SelectCommand (da.SelectCommand.Connection)

Try

da.SelectCommand.Connection = con
da.SelectCommand = cmditem
ndeniche 402 Posting Virtuoso Featured Poster

What do you mean by "grabbing"?

Btw, you should consider formatting and indenting your code for easier comprehension.

ndeniche 402 Posting Virtuoso Featured Poster

Because, in checking the current char, if there's a non-numeric character, the subscript's position is not changing, so it keeps checking the same character oiver and over again. Maybe you could try a validated loop exit?

bool valid = true;
while ((subscript < numChars) && (valid))
    {...
        if(...)
        {...}
        else
        {
            cout<<"Please enter digits only"<<endl;
            valid = false;
        }
    }
ndeniche 402 Posting Virtuoso Featured Poster

Point granted ;)

ndeniche 402 Posting Virtuoso Featured Poster

Exit(0) , is commonly used as a successful exit message. Usually, you don't use it, use instead Return 0; Exit(1) Is used to reference some kind of abnormal program termination.

ndeniche 402 Posting Virtuoso Featured Poster

you can always look for your header files in your library folders. Look for the address in the "Options" or "Preferences" of your c++ compiler, or go to the folder you configured when setting it up.

Once you reached the folder, look for the library you intend to study. That should do it

ndeniche 402 Posting Virtuoso Featured Poster

Besides, you can't declare two variables with the same name... see: int num[] and int num

ndeniche 402 Posting Virtuoso Featured Poster

in line 19, you have a semicolon. That should do it

ndeniche 402 Posting Virtuoso Featured Poster

have you tried separating the title from the image with a <br /> ?

ndeniche 402 Posting Virtuoso Featured Poster

what anout a function that will break up both strings (the one from the input and the one from the access db) into string arrays and compare them in a double function, constituted by nested for that will go through both arrays, counting the amount of matching words, loops that will return the results from the comparison... something like this:

String 1: "I would love to do that"
String 2: "I love to do that"

Array 1:
| "I" | "would" | "love" | "to "| "do" | "that" |

Array 2:
| "I" | "love" | "to" | "do" | "that" |

Total words in array 1: 6
Amount of matching words: 5

Percetnage of matching words= 5/6 * 100 = 83.33%

83.33 > 60 ? True

printf("true")

ndeniche 402 Posting Virtuoso Featured Poster

Great! Always a pleasure... (Mark it as solved so it can be useful to others)

ndeniche 402 Posting Virtuoso Featured Poster

Actually, your error is literally what the compiler displays. You _do_ have an error in your SQL syntax. It should be SELECT * FROM engineer .

I don't really know what the ADODB class for row storage is, so i'll just call it RowSet , so, supposing you have a Name column for the engineer's name, when you add the combobox items, it should be something like:

Dim queryStr As String = "SELECT * FROM engineer"
RowSet = SQLSEARCH(queryStr)
Dim count As Integer = 0
While Not RS.EOF Loop
   cmbEngNum.Add(RowSet.Rows[count].Columns["Name"].Value.ToString())
End While

Remember the results of a query are returned in a table format, so you must have an object receiving that value, and you must read through this object to assign the desired value to the combobox items.

ndeniche 402 Posting Virtuoso Featured Poster
ndeniche 402 Posting Virtuoso Featured Poster

a syrup container in use? the top left part is the base, and the tip, is... the tip

ndeniche 402 Posting Virtuoso Featured Poster

a microwave?

ndeniche 402 Posting Virtuoso Featured Poster

if you want to do what dani suggested, all you have to do is open a .txt file and save it as filename.html and then upload it to a ftp server

ndeniche 402 Posting Virtuoso Featured Poster

you're welcome... and, please, mark your thread as solved...

ndeniche 402 Posting Virtuoso Featured Poster

good luck

ndeniche 402 Posting Virtuoso Featured Poster

there's a pseudo-class in cs called :hover try this:

#image img
{
   background-image:url(image1.gif)
}

#image img:hover
{
   background-image:url(image2.gif)
}
...
<div id="image">
<img>&nbsp;</img>
</div>
ndeniche 402 Posting Virtuoso Featured Poster

do you know css?

ndeniche 402 Posting Virtuoso Featured Poster

what is your problem?

ndeniche 402 Posting Virtuoso Featured Poster

i'm checking on your page, and it seems to be aok... unless those are not the results you want... did you manage to solve your problem?

ndeniche 402 Posting Virtuoso Featured Poster

did you specify the <!DOCTYPE> ?

ndeniche 402 Posting Virtuoso Featured Poster

or try inserting a &nbsp; in between the <td id="id"></td> or the <div></div> tags

ndeniche 402 Posting Virtuoso Featured Poster

try putting the id not in a <div></div> but in the <td></td>

ndeniche 402 Posting Virtuoso Featured Poster

may we see some part of your code?

ndeniche 402 Posting Virtuoso Featured Poster

i like your opinion about tables... actually i rather code my pages based in tables than messing around with positioning

ndeniche 402 Posting Virtuoso Featured Poster

after all, Internet Explorer won the "browser wars" of the 90's, and has proved itself as the world's most popular web browser year after year since.

i wouldn't give that for granted, since mozilla is on the rise and it has more users day after day...

ndeniche 402 Posting Virtuoso Featured Poster

actually, i'm going through the same issue...

sbv's solution is pretty attractive... though, you must write compatible html codes with every css, so they're compatible to each one of them...

besides, what if i'm using for example, Safari 2, and there's no css code for my browser? or if i'm using an uncommon browser like Opera?

ndeniche 402 Posting Virtuoso Featured Poster

if 1 micron is 1/1000000000 of a km, that means 1 micron pero hour is 1/60000000000 km/hour... in miles, that is 1.6/60000000000 mi/hour, so your conversion should be .533*1.6/60000000000 for red light, and .674 * 1.6/60000000000 for green light...

ndeniche 402 Posting Virtuoso Featured Poster

one thing i don't understand is why in line 57 and 58 you have two returns if your main function is not over...

the errors you get are because main is declared as an int function, and the values you are returning are invalid conversions from double to int...

in your void calc() you should just use a, b, and c to calculate your perimeter and your area, because those operations there are messing your whole operations... maybe you should want to try this:

void calc(int a, int b, int c, double &s, double &area){
   s=((a+b+c)/2);
   area=sqrt (((s-a)*(s-b)*(s-c))*s);
}

try it and let me know...

ndeniche 402 Posting Virtuoso Featured Poster

^should study a little bit more geography... (Honduras is not in Spain...)

i don't think that's a good thing... but what the hell...