You have
public class stockmanager extends Activity{
And you are instantiating a activity class
stockmanager sm=new stockmanager()
.
You should not instantiate a activity class. It is wrong. Instead you can pass the value to the method itself or to the constructor of other class.
You can do as
StockTable st=new StockTable();
st.insert(your params);
Then in StockTable have a insert method that takes params
public ContentValues insert(params){