declaring functions ... ?

General topics about the Android-Platform itself.
Coding issues please to the subforum right below.

declaring functions ... ?

Postby Trip » Sat May 22, 2010 3:12 am

im new to java ... but am pretty well rounded in SQL & vb.net ... i understand and can code a little c++

can some one tell me how to declare functions in java ?

i have searched everywhere

i've been trying

private void Calculation(){};

but this doesnt work :(

any help appreciated or links to examples / tutorials would be great (and please dont refer me to google i've spent a few hours searching)
Trip
Junior Developer
Junior Developer
 
Posts: 19
Joined: Sat May 22, 2010 2:58 am

Top

Re: declaring functions ... ?

Postby ng.kishore » Sat May 22, 2010 6:41 pm

Hi Trip,

The function declaration in java same as in C/C++.
Any how the syntax for function declaration in java is given bellow.

Function <type> <funname>(<arglist>)
{
<statements>
return [<returnvalue>];
}
N G Kishore.
ng.kishore
Developer
Developer
 
Posts: 33
Joined: Wed Apr 28, 2010 11:07 am
Location: Hyderabad

Re: declaring functions ... ?

Postby Trip » Sun May 23, 2010 10:17 pm

thanks for your reply dude ... i figured it out after a while lol

... was trying to add my function inside the createbundle void ... such a noob thing to do :D
Trip
Junior Developer
Junior Developer
 
Posts: 19
Joined: Sat May 22, 2010 2:58 am

Top

Return to General

Who is online

Users browsing this forum: No registered users and 6 guests