NameSilo

Get FileUpload control value ASP.Net

Namecheap AuctionsNamecheap Auctions
SpaceshipSpaceship
SpaceshipSpaceship
Watch

jonambed

New Member
Impact
0
Hi guys, I have an aspx webpage with 9 fileupload controls called (fupBlogImg1,fupBlogImg2,.........fupBlogImg9 ). I want to get their values with a for at the code after the button (cmdAlbumCreate) is clicked.

Here is the code but fupBlogImg is null (I dont know why)
for (int n = 1; n < 10; n++)
{
string StrBlogImg = "fupBlogImg" + n;
FileUpload fupBlogImg = (FileUpload)FindControl(StrBlogImg);
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
DomainEasy: white label portfolios are live. Enable yours.

We're social

Escrow.com
Spaceship
Escrowly
CryptoExchange.com
Domain Recover
Catchy
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back