i apologize for not showing any code

i tried the code that made but it still didn't work.
here's my code ...
inside the doPost i get the values of the request and response and assign it to their corresponding Http objects.
public void doPost(HttpServletRequest req, HttpServletResponse resp)
{
try
{
this.req = req;
this.resp = resp;
//get session
session = req.getSession();
//get Form details
String action = (String)req.getParameter("action");
out("Action requested: " + action);
if(action == null)
{
resp.sendRedirect("../jsp/index.htm");
}
else if(action.equalsIgnoreCase("addproduct"))
{
String name = (String)req.getParameter("productName");
String desc = (String) req.getParameter("description");
String imageFile = (String)req.getParameter("file");
int mID = Integer.parseInt(req.getParameter("manufacturerID"));
int ptID = Integer.parseInt(req.getParameter("productTypeID"));
this.uploadImage();
Product prod = new Product();
prod.getDBConnectionMgr(this.dbConnManager);
prod.setName(name);
prod.setDescription(desc);
prod.setImageFile(imageFile);
prod.setManufacturerID(mID);
prod.setProductTypeID(ptID);
prod.insertRecord();
resp.sendRedirect("ProductHandler?action=viewProducts");
}
}
catch (Exception e)
{
out("Error in doPost: ");
e.printStackTrace();
}
}//END doPost
... this is outside the doPost and is called when i add a product
public void uploadImage() throws ServletException
{
SmartUpload mySmartUpload = new SmartUpload();
Properties profileProps = new Properties();
try
{
//start mySmartUpload
mySmartUpload.initialize(this.getServletConfig(), this.req, this.resp);
mySmartUpload.setAllowedFilesList("gif,jpg,jpeg,GIF,JPG,JPEG");
mySmartUpload.setMaxFileSize(1500);
mySmartUpload.upload();
out("file uploaded");
for (int i=0;i<mySmartUpload.getFiles().getCount();i++)
{
com.jspsmart.upload.File myFile = mySmartUpload.getFiles().getFile(i);
if (!myFile.isMissing())
{
myFile.saveAs(articlePath + myFile.getFileName(), mySmartUpload.SAVE_PHYSICAL);
out("saved file: " + myFile.getFileName());
}
//get the form fields as an enumeration. Then it associates with name/value pair
Enumeration enum = mySmartUpload.getRequest().getParameterNames();
while (enum.hasMoreElements())
{
String name = (String)enum.nextElement();
out("parameters in request: " + name);
String value = mySmartUpload.getRequest().getParameter(name);
profileProps.setProperty(name, value);
}
}
}
catch(Exception e)
{
e.printStackTrace();
}
... when i run the program, it's able to print out "file uploaded" (which is inside the uploadImage function) however it does not go through the enumeration, and does not print the parameter names. when i check the physical path to where the images are saved, there's nothing saved.