|
|
 |
BOOK: Professional ASP.NET MVC 1.0 ISBN: 978-0-470-38461-9
 |
This is the forum to discuss the Wrox book Professional ASP.NET MVC 1.0 by Rob Conery, Scott Hanselman, Phil Haack, Scott Guthrie; ISBN: 978-0-470-38461-9 |
|
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: Professional ASP.NET MVC 1.0 ISBN: 978-0-470-38461-9 section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.
|
 |
|

June 26th, 2009, 08:57 AM
|
|
Registered User
|
|
Join Date: Jun 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Virtual Earth Map Does Not Display Properly
Hi calculemus,
I checked for "<divid" and that was an error on my post here. Sorry about that.
Here is my Map.ascx. I notice that pasting "div id" converts it to "divid" again. Thanks again for your help.
<%@ControlLanguage="C#"Inherits="System.Web.Mvc.ViewUserControl<NerdDinner.Models .Dinner>" %>
<scriptsrc="http://dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.2"
type="text/javascript"></script>
<scriptsrc="/Scripts/Map.js"type="text/javascript"></script>
<div id="theMap"style="width:520x">
</div>
<scripttype="text/javascript">$(document).ready(function() {
var latitude = <%=Model.Latitude %>;
var longitude = <%=Model.Longitude %>;
if ((latitude == 0) || (longitude == 0))
LoadMap();
else
LoadMap(latitude, longitude, mapLoaded);
});
function mapLoaded() {var title = "<%= Html.Encode(Model.Title) %>";
var address = "<%= Html.Encode(Model.Address) %>";
LoadPin(center, title, address);
map.SetZoomLevel(14);
}
</script>
|

June 26th, 2009, 09:48 AM
|
|
Registered User
|
|
Join Date: Jun 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Virtual Earth Map Does Not Display Properly
Please don't put any more time into this. Something very weird is going on.
I thought I would use brute force to debug this thing, so I backed up my broken app and copied all the .aspx files from the download version of Views/Dinners/ into my version. Presto! it works fine.
Here is where it gets weird. I replaced the Dinners files with my old (supposedly broken) versions. It still works.
I performed the file copying etc with VS shut down.
I swear I didn't touch any other files.
I always do re-builds of the app.
I always re-start the development web server between code changes.
Any ideas?
This is a pretty scary scenario. In a real world situation, I would not have a working copy of the software to somehow "reset" the IDE.
Thank you for all of your help.
|

June 26th, 2009, 10:22 AM
|
|
Authorized User
|
|
Join Date: Jun 2009
Posts: 19
Thanks: 0
Thanked 1 Time in 1 Post
|
|
Hmm... interesting....
Hi taddendum,
I would do a simple diff (tortoise SVN is handy) to see if your aspx files are somehow different from the downloaded ones.
If they are somewhat the same, I suspect that it might be somehow related to your browser caching old CSS files. I highly doubt this though because you say that you're restarting your dev server after code changes.
I guess what's important is that the problem's resolved. Have fun reading rest of the book.
Good luck!
S.
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
 |