Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

AppTheory specializes in solutions based on the DotNetNuke platform and has 2 employees on the DotNetNuke Core Team.
  Need Help?  
Professional technical support for DotNetNuke is available from DotNetNuke Corporation.
 


  Ads  
Active Modules -- Active Forums for DotNetNuke
 


  Sponsors  

Meet Our Sponsors

Salaro -- Skins and more
OnyakTech
The best choice for your web site host, email hosting, and domain registration.
CrystalTech Web Hosting™
Webhost4life, specialists in DNN hosting
Mad Development is a full service interactive agency focusing on the merge of design, technology, e-commerce, and affiliate marketing by providing total website solutions.
 


DotNetNuke Forums
 
  Forum  DotNetNuke® Pro...  Authentication ...  Problem with User Account module in DNN 4.8.1 version
Previous Previous
 
Next Next
New Post 5/12/2008 10:21 PM
Resolved
User is offline shreekala
5 posts
10th Ranked


Problem with User Account module in DNN 4.8.1 version 

I used file upload control for uploading photo but its throwing error "object reference not set to an instance of an object" only in dnn 481,dnn 482 versions. I used same control in dnn 470 version there it works fine.

Please find the code below

I used btn as  asp button control,fu as asp file upload control,img as asp image control

I am getting error in  this line  " contLength = fu.PostedFile.ContentLength" as object refererence not set to an instance of an object.
I am able to get file upload control's ID but I am not able to  capturethe content of that upload control.

Pls give me a soln.

Protected Sub btn_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btn.Click
            Dim contLength As Integer
            contLength = fu.PostedFile.ContentLength
            Dim myData(contLength) As Byte
            fu.PostedFile.InputStream.Read(myData, 0, contLength)
            Dim strpath As String = "C:\Inetpub\wwwroot\iredver1.0\CompanyLogo"
            Dim strfileName As String = Path.GetFileName(fu.PostedFile.FileName)
            Dim strpth As String = ""
            strpth = Path.Combine(strpath, strfileName)
            fu.SaveAs(strpth)
            img.ImageUrl = strpth

  End Sub

 

 

Report
 
Previous Previous
 
Next Next
  Forum  DotNetNuke® Pro...  Authentication ...  Problem with User Account module in DNN 4.8.1 version
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:

1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


Customer Connect
Customer Connect provides cutting edge solutions that deliver sales, marketing and customer service results.
www.customer-connect.com
TechNexxus
Business process and technology sourcing solutions delivering superior people, process and value. We have used, and continue to use, DNN successfully in numerous client projects to deliver exceptional value. We are proud to support the DNN team and community.
www.technexxus.com
PartnerPoint - Microsoft Technology Community
PartnerPoint is one of the largest online communities of Microsoft Partners Worldwide. With over 5,000 active members, it serves as a collaboration platform for other technology communties around the globe
www.partnerpoint.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP