The forums have permanently moved to This forum will be kept around in read-only mode for archival purposes. To learn how to continue using your existing account on the new forums, check out this thread.

Results 1 to 1 of 1

Thread: Having problem on remote retrieval and upload module for BLOB

  1. #1

    Having problem on remote retrieval and upload module for BLOB

    hi, i am doing a project on allowing upload of images remotely from client to server through web application (BLOB). In my project, when i run my C# program on my visual studio 2005, it can able to upload my .jpg image from any location of my PC where i saved in and when i can able to reteive the image and display on my localhost webportal. Everything work fine, but when i save my program folder where i name it as "STCWebsite" into my IIS. When i create a new virtual directory.. i run a remote on other PC(client). http://host IP_address/STCWebsite/login.aspx when i went to upload any new .jpg image contain inside the other PC(client).. it happen that it could not be able to find the "FILEPATH" of the image i wanted to upload on that client PC.. so i am thinking is it the "mainpath" problem.. here r the source problem i face.. it only can read the directory i set eg. in my program i set the logofilepath to D:\STCwebsite\image\ when i as a client PC, i only can put my image to this same directory then i can able to upload it, and somemore, the image i upload on my client PC, the host must also have contain that picture already inside its PC.. so thats the i am hoping if can able to access any .jpg image i upload on my client PC, can also accept to the database server and can retieve it on the display webpage.. is like uploading new image on facebook or myspace... thank you//

    here r my code for that particular upload source: see if theres any thing need to be changed?

    protectedvoid BTNSave_Click(object sender, EventArgs e)
    // Set a specified View to display
    MVEditCompanyDetails.SetActiveView(ViewConfirmComp anyDetails);
    companyname = (
    if (FileUploadCompanyLogo1.HasFile)
    // **IMPORTANT BROWSER** Write the logo to the confirmation company logo image control
    FileStream fsread = newFileStream(FileUploadCompanyLogo1.PostedFile.FileName.ToStri ng(), FileMode.Open, FileAccess.Read);
    FileStream fswrite = newFileStream(ConfigurationManager.AppSettings["LoginLogoPath"] + "temp" + companyname + ".jpg", FileMode.Create);

    // Create the writer for data.
    BinaryReader logoread = newBinaryReader(fsread);
    BinaryWriter logowrite = newBinaryWriter(fswrite);

    logowrite.Write(logoread.ReadBytes(FileUploadCompa nyLogo1.PostedFile.ContentLength));
    // Reference IMGComLogo to the path of the image
    IMGComLogo.ImageUrl = "../" + ConfigurationManager.AppSettings["ImageLoginLogoPath"] + "temp" + companyname + ".jpg";
    "mainpath", companyname + ".jpg");
    "path", "temp" + companyname + ".jpg");
    IMGComLogo.ImageUrl = IMGCompanyLogo.ImageUrl;
    "path", companyname + ".jpg");
    "fileUpload", FileUploadCompanyLogo1);
    LBLComName.Text = LBLCompanyName.Text;
    LBLDescription.Text = TBDescription.Text;
    LBLProducts.Text = TBProducts.Text;
    LBLContactPerson.Text = TBContactPerson.Text;
    LBLDesignation.Text = TBDesignation.Text;
    LBLTelephone.Text = TBTelephone.Text;
    LBLFax.Text = TBFax.Text;
    LBLEmail.Text = TBEmail.Text;
    LBLWebsite.Text = TBWebsite.Text;
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	error.jpg 
Views:	40 
Size:	73.9 KB 
ID:	47074  

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Home About Meet the Moderators Advertise

 Link to Us


Copyright 1999 - 2012