1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Problem in File Upload in enctype="multipart/form-data"

Discussion in 'C#' started by ravjeetbedi, Jun 19, 2006.

  1. #1
    Hi, I am developing an application which requires File upload in asp. The asp page requires multile server trips as there are dynamic drop down list. IF I add
    enctype="multipart/form-data" in the form tag then the drop down list does not get populated and if I dont then file does not get uploaded.
    CAn u provide a solution for this?
     
    ravjeetbedi, Jun 19, 2006 IP
  2. jaymcc

    jaymcc Peon

    Messages:
    139
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I'm not sure that the encoding type is going to affect your drop down lists being populated. I'm assuming that they are database driven?

    Change to enctype=yada yada changes the way you deal with all controls on the form, not just the upload control. It's been a while however I think you need to process the file upload with every post back (even if no file selected). It's only after initiating this process that the rest of the controls become assesible in the form collection.

    Does that make sense, let me know if not, I'll try and find an example.

    Thanks

    Jay
     
    jaymcc, Jun 19, 2006 IP
  3. ravjeetbedi

    ravjeetbedi Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Ya I think it will be better if u can explain it with an example..
    Thanks in advance!!
     
    ravjeetbedi, Jun 19, 2006 IP