Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 4.5 > BOOK: Beginning ASP.NET 4.5 : in C# and VB
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning ASP.NET 4.5 : in C# and VB
This is the forum to discuss the Wrox book Beginning ASP.NET 4.5: in C# and VB by Imar Spaanjaars; ISBN: 978-1-118-31180-6
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 4.5 : in C# and VB section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #11 (permalink)  
Old September 2nd, 2013, 04:21 PM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

I don't see where I can attach screen shots. So I'm going to create a web page and post the link with screen shots of my IIS set up.

I will edit this and post them when I get finish.

Thanks!
Reply With Quote
  #12 (permalink)  
Old September 2nd, 2013, 04:22 PM
Authorized User
Points: 175, Level: 3
Points: 175, Level: 3 Points: 175, Level: 3 Points: 175, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2013
Location: St.Petersburg, Russia
Posts: 36
Thanks: 1
Thanked 4 Times in 4 Posts
Default

Quote:
Originally Posted by maurices5000 View Post
Unhandled Exception: System.TimeoutException: The request channel timed out while waiting for a reply after 00:00:58.8749356. Increase the timeout value passed to the call to Request or increase the SendTimeout value on the Binding. The time allotted to this operation may have been a portion of a longer timeout. ---> System.TimeoutException: The HTTP request to'http://localhost/ProductsService/Service.svc' has exceeded the allotted timeout of 00:00:59.0370000. The time allotted to this operation may have been a portion of a longer timeout. ---> System.Net.WebException: The operation has timed out
This says that localhost/ProductsService/Service.svc does not answer.
IMHO: Make sure that the service reference is correct.
Reply With Quote
  #13 (permalink)  
Old September 2nd, 2013, 04:42 PM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

I'll see if i can delete it and recreate it.

Thanks!
Reply With Quote
  #14 (permalink)  
Old September 2nd, 2013, 05:13 PM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

HEre are my screen shots. If you need a description I can provide one. This is IIS. I have deleted and recreated the Service reference yet and I'll do the SSMS screen shots in a minute.

http://www.secondchoice.org/2ndchoice/iis.htm
Reply With Quote
  #15 (permalink)  
Old September 2nd, 2013, 05:23 PM
Imar's Avatar
Wrox Author
Points: 72,045, Level: 100
Points: 72,045, Level: 100 Points: 72,045, Level: 100 Points: 72,045, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,083
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

The error message with "Invalid application path" is interesting. What are the permissions on disk for the ProductsService folder? Did you add the app pool account to the list of users with at least read permissions? Are there any specific deny permissions set?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
  #16 (permalink)  
Old September 2nd, 2013, 05:47 PM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

I gave full access to IUSR and Network Service for everything in the wwwroot directory. So those two users have full access. Should i have added the ASP.NET v4.0 application pool as a user?

WHen i try to add ASP.NET v4.0 as a user i get this error: "An object named "ASP.NET v4.0" cannot be found. Check the selected object types and location for accuracy and ensure that you typed the object name correctly, or remove this object from the selection."

There are NO denies

Regarding Server Reference, I copied the code from Book Download and made the changes to the config files and re-published the site. It gives me the exact same error.

Last edited by maurices5000; September 2nd, 2013 at 05:56 PM..
Reply With Quote
  #17 (permalink)  
Old September 2nd, 2013, 06:02 PM
Imar's Avatar
Wrox Author
Points: 72,045, Level: 100
Points: 72,045, Level: 100 Points: 72,045, Level: 100 Points: 72,045, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,083
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Yes, you need to add IIS APPPOOL\ASP.NET v4.0 as well. You won't find it in the list of users but if you type it directly, it works.

My book has more details; searching for IIS apppool should show you where (can't check right now)

cheers,


Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
The Following User Says Thank You to Imar For This Useful Post:
maurices5000 (September 2nd, 2013)
  #18 (permalink)  
Old September 2nd, 2013, 06:10 PM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

HEre is my SQL Server Information

http://www.secondchoice.org/2ndchoice/ssms.htm

I was able to all the fully qualifed name rather than the shorted named I used. That by itself did not solve the problem. I'm going to read your book and see what else it says.

Thanks Looks like its in Appendix B Configuring SQL Server 2012

Last edited by maurices5000; September 2nd, 2013 at 06:27 PM..
Reply With Quote
  #19 (permalink)  
Old September 2nd, 2013, 11:28 PM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

Thank guys for your help. At this point, I've read all of Chapter 19 and Appendix B. I understand a lot more than I did and it was a pleasure to read. Very easy to follow. I'm hoping the last part of Appendix B will fix my problem, but I don't understand it. This post is all about Appendix B the next post will tell you what I've done.

I'm in the last section of Appendix B and I don't understand it: "Configuring Application Services" Its the only thing so far I don't understand.

I'm not sure what the following statement means. Was this covered in Ch 19 and Appendix B?
Quote:
Earlier in this book you learned that the ASP.NET application services make use of a SQL Server database. You also saw how to make sure your own website and the application services use the same database.
Quote:
Follow these steps to let the application services use your own database:

1. First, make sure the application services point to a connection string you want to use. To do this, you need to set the connectionStringName to a connectionstring defined in your config file. The following example shows how to do this for the Membership section, but the other services follow a similar pattern: (I'm assuming this is in Web.Config. Its not in mine.)

< membership defaultProvider =" DefaultMembershipProvider" > < providers >
< add name =" DefaultMembershipProvider" type =" System.Web.Providers.DefaultMembershipProvider, System.Web.Providers, Version = 1.0.0.0, Culture = neutral, PublicKeyToken = 31bf3856ad364e35" connectionStringName ="PlanetWroxConnectionString1" enablePasswordRetrieval =" false" enablePasswordReset =" true" requiresQuestionAndAnswer =" false" requiresUniqueEmail =" false" maxInvalidPasswordAttempts =" 5" minRequiredPasswordLength =" 7" minRequiredNonalphanumericCharacters =" 1" passwordAttemptWindow =" 10" applicationName ="/" /> </ providers >
</ membership >

Notice how connectionStringName points to the connection string called PlanetWroxConnectionString1, defined elsewhere in the config file.
Quote:
(I didn't think this one was necessary. But i can do it if i need to. This is in SSMS.)

2. Make sure the account used by the web server has permissions to alter the database schema. You can accomplish this by adding the account to the db_ddladmin group, shown in Figure B. 6 . This grants the account the permissions to execute Data Definition Language statements , which means it can create and alter tables and other objects in the database.
I don't know what the following means:
Quote:
4. Browse to your site and request the Login page. Try to log in with a fake username and password. At this stage, the .NET run time will modify the database and add the necessary tables to it. If you look in the database defined in the connection string used by the membership services, you'll notice it now contains the tables that are used by Membership, Roles, and Profile.
Reply With Quote
  #20 (permalink)  
Old September 3rd, 2013, 12:13 AM
Authorized User
Points: 94, Level: 1
Points: 94, Level: 1 Points: 94, Level: 1 Points: 94, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2013
Posts: 24
Thanks: 7
Thanked 0 Times in 0 Posts
Default

Guys! Its working.


Thanks A MILLION!!!!!




I was typing the below beforehand. I'll keep it for future reference. The Test Setting button in IIS Basic Setting still fails. But when i run the app now in VS2010, it works like its supposed to. I hope I'm not deceiving myself. Could it be running off VS Development Server?


Ok What I've done is I added both IIS APPPOOL\ASP.NET v4.0 and IIS APPPOOL\DefaultAppPool to the SQL SERVER's Security Logins. The Book author's aspnet.sql script had already added them to the AdventureWorks database.

I added them both to the file permissions at C:\inetpub\wwwroot, giving them full access.

I clicked the Advanced button at the bottom of the Security tab. Clicked Change Permissions and clicked the checkbox that says Replace All Child Object Permissions check box. ((It did not stay checked however).
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't reinstall Access database Xzyl Access 6 November 18th, 2008 04:39 PM
MySQL - Uninstall Fix MySQL 2 April 12th, 2006 02:53 AM
Uninstall BETA's first Robert Reno BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 3 February 14th, 2006 12:50 PM
Trouble connecting to Access DB thru IIS swoopest Classic ASP Databases 6 November 10th, 2004 10:13 AM
MSDE Uninstall Doesn't jeffg22 SQL Server 2000 11 September 15th, 2004 09:11 AM



All times are GMT -4. The time now is 09:12 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.