Thursday, March 29, 2012
Newbie - Problem Loading SLN files.
I am having a problem that is driving me crazy.
I have Windows 2000 Professional, Visual Studio Professional, IIS installed
and running...
I am reading ASP.NET Developer's JumpStart by Paul Sheriff and Ken Getz.
I've downloaded the examples and now want to try some of them out.
In VS, I go to the File Menu and Select, Open Solution. I go to the
directory that the installer put the book's files and select the SLN file.I
then get the following error:
Unable to get the project file from the Web Server. Unable to open Web
Project 'JumpStart/VBLanguage.' The Web 'JumpStart/VBLanguage' located
on server 'http://localhost/' does not exist.
In IIS, their is a virtual directory for JumpStart. I've tried creating one
for VBLanguage but I still am getting errors.
I then tried just opening the Project. I had to use a URL
(http://localhost/jumpstart/vblanguage/vblanguage.vbproj) and I can open it,
but I get the message: "You do not have permission to make changes to this
document. Do you want to open a read-only copy?"
I answer Yes, but I still get the error that it is unable to get the project
file from the Web Server.
I can't reproduce exactly what I did before, but at one point I think I made
my own Solution file and added everything, but I could not view any of the
pages in Design view.
I just want to learn this stuff. I've spent too long just trying to open a
file and no time reading and learning. It had been very frustrating (thanks
for letting me vent).
Thank you for any help you can provide.
-RobI think you need to contact either Paul Sheriff or Ken Getz for your answer.
--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
"Rob G" <gumbatman@.hotmail.com> wrote in message
news:100t3elpo11ir12@.corp.supernews.com...
> Hi All,
> I am having a problem that is driving me crazy.
> I have Windows 2000 Professional, Visual Studio Professional, IIS
installed
> and running...
> I am reading ASP.NET Developer's JumpStart by Paul Sheriff and Ken Getz.
> I've downloaded the examples and now want to try some of them out.
> In VS, I go to the File Menu and Select, Open Solution. I go to the
> directory that the installer put the book's files and select the SLN
file.I
> then get the following error:
> Unable to get the project file from the Web Server. Unable to open Web
> Project 'JumpStart/VBLanguage.' The Web 'JumpStart/VBLanguage'
located
> on server 'http://localhost/' does not exist.
> In IIS, their is a virtual directory for JumpStart. I've tried creating
one
> for VBLanguage but I still am getting errors.
> I then tried just opening the Project. I had to use a URL
> (http://localhost/jumpstart/vblanguage/vblanguage.vbproj) and I can open
it,
> but I get the message: "You do not have permission to make changes to this
> document. Do you want to open a read-only copy?"
> I answer Yes, but I still get the error that it is unable to get the
project
> file from the Web Server.
> I can't reproduce exactly what I did before, but at one point I think I
made
> my own Solution file and added everything, but I could not view any of the
> pages in Design view.
> I just want to learn this stuff. I've spent too long just trying to open a
> file and no time reading and learning. It had been very frustrating
(thanks
> for letting me vent).
> Thank you for any help you can provide.
> -Rob
Maybe, but I installed it on a different PC with no problems. So I figured
it was a Microsoft problem, not Paul Sherrif's or Ken Getz's.
"Kevin Spencer" <kevin@.takempis.com> wrote in message
news:OMJfmRD4DHA.3944@.tk2msftngp13.phx.gbl...
> I think you need to contact either Paul Sheriff or Ken Getz for your
answer.
> --
> HTH,
> Kevin Spencer
> .Net Developer
> Microsoft MVP
> Big things are made up
> of lots of little things.
> "Rob G" <gumbatman@.hotmail.com> wrote in message
> news:100t3elpo11ir12@.corp.supernews.com...
> > Hi All,
> > I am having a problem that is driving me crazy.
> > I have Windows 2000 Professional, Visual Studio Professional, IIS
> installed
> > and running...
> > I am reading ASP.NET Developer's JumpStart by Paul Sheriff and Ken Getz.
> > I've downloaded the examples and now want to try some of them out.
> > In VS, I go to the File Menu and Select, Open Solution. I go to the
> > directory that the installer put the book's files and select the SLN
> file.I
> > then get the following error:
> > Unable to get the project file from the Web Server. Unable to open
Web
> > Project 'JumpStart/VBLanguage.' The Web 'JumpStart/VBLanguage'
> located
> > on server 'http://localhost/' does not exist.
> > In IIS, their is a virtual directory for JumpStart. I've tried creating
> one
> > for VBLanguage but I still am getting errors.
> > I then tried just opening the Project. I had to use a URL
> > (http://localhost/jumpstart/vblanguage/vblanguage.vbproj) and I can open
> it,
> > but I get the message: "You do not have permission to make changes to
this
> > document. Do you want to open a read-only copy?"
> > I answer Yes, but I still get the error that it is unable to get the
> project
> > file from the Web Server.
> > I can't reproduce exactly what I did before, but at one point I think I
> made
> > my own Solution file and added everything, but I could not view any of
the
> > pages in Design view.
> > I just want to learn this stuff. I've spent too long just trying to open
a
> > file and no time reading and learning. It had been very frustrating
> (thanks
> > for letting me vent).
> > Thank you for any help you can provide.
> > -Rob
newbie - server error
Server Error in '/commform' Application.
------------------------
Runtime Error
Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.
Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".
<!-- Web.Config Configuration File -->
<configuration>
<system.web>
<customErrors mode="Off"/>
</system.web>
</configuration>
Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.
<!-- Web.Config Configuration File -->
<configuration>
<system.web>
<customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
</system.web>
</configuration>I suggest you do what it says!
Edit your web.config file and add
<configuration>
<system.web>
<customErrors mode="RemoteOnly" />
</system.web>
</configuration>
If the <configuration> and <system.web> tags are already there, dont add them again.
Once you've done this, recompile your project and you will get more information about your error.
Note that the detailed error message will only appear to you if you are viewing the site on the webserver.
Newbie - Test a site using VWD locally on WinXP - but be able to test on Mac Safari
I have VWD running locally on WINXP. I have a site working well. I want to test it on Mac Safari. I have a Mac running on the same local network.
What address can I use to see VWD site on the Mac? On WinXP the site address is http://localhost:2062/12-1-06-B/ - - but not sure how to get my Mac and Safari to access this as well.
Thanks in advance.
The VWD was really only meant for local development, but assuming you had the Cassini server on the XP Machine running i don't see why this wouldn't work.
http://ipaddressofcomputer:xxxx/12-1-06-B/
Where ipaddressofcomputer is the IP of the machine (the XP one) and xxxx is the port that cassini is using. I Don't know if Cassini will actually host it on a non local machine, if not then you will have to upgrade to IIS.
To get your IP Address - Start / Run Type [cmd] press enter for cmd console.
Type ipconfig and press enter.
Type exit and enter to close.
vcsjones:
The VWD was really only meant for local development, but assuming you had the Cassini server on the XP Machine running i don't see why this wouldn't work.
http://ipaddressofcomputer:xxxx/12-1-06-B/
Where ipaddressofcomputer is the IP of the machine (the XP one) and xxxx is the port that cassini is using. I Don't know if Cassini will actually host it on a non local machine, if not then you will have to upgrade to IIS.
Unfortunately, this didn't work. But if I find a solution I'll post it here.
Monday, March 26, 2012
Newbie class inheritance question
calls a custom constructor. Here's the type of code found in the
parent class:
Public Class parent
Private _a As Long
Private _b As Long
Private _c As String
....
Public Sub New(ByVal a As Long, ByVal b As Long, ByRef c As
String)
_a = a
_b = b
_c = c
EndSub
EndClass
And now the derived class:
Public Class child
Inherits parent
' apparently, i have to redeclare the private vars found in the
parent?
Private _a As Long
Private _b As Long
Private _c As String
....
' cannot inherit the constructor, so define identical one here
Public Sub New(ByVal a As Long, ByVal b As Long, ByRef c As
String)
' call mybase.new to assign vars
MyBase.New(a, b, c)
EndSub
EndClass
By calling 'mybase.new' in the child class, I had expected the var
assignments in the parent to be executed, populating the vars declared
in the child.
What I found with the above class definitions is that the child 'var
_c' is NOT assigned a value.
I'm sure there's a simple answer, but I'm a beginner. Also, I found
some MSDN articles on class inheritance in the 'Upgrading to .NET'
section, but am looking for something that goes deeper. Any idea
where I can find articles that go into greater depth on the subject of
class inheritance?
Thanks... JonJon, "Private" means "Private". Not even a child class can see private
members. You would need to declare them as protected in the parent in order
for the child to use them.
And as a general rule, you should avoid having derived classes access fields
in the parent class. Let them stay private, but declare protected properties
to access them:
Protected Property A as Long
Get
Return _a
End Get
Set
_a = Value
End Set
End Property
This way, the parent class is in control of when these fields are set, and
the values to which it may be set. For instance, you can put code in the Set
accessor to validate the value, or even put code in the Get accessor to get
the value from somewhere else. If you allow your child classes to access the
fields directly, then the fields will _always_ have to be there, just the
way they are, or you'll break the derived classes.
--
John Saunders
Internet Engineer
john.saunders@.surfcontrol.com
"Jon" <to_jon@.hotmail.com> wrote in message
news:e4b2505c.0308061218.513521ee@.posting.google.c om...
> I'm running into a simple issue when instatiating a derived class that
> calls a custom constructor. Here's the type of code found in the
> parent class:
> Public Class parent
> Private _a As Long
> Private _b As Long
> Private _c As String
> ...
> Public Sub New(ByVal a As Long, ByVal b As Long, ByRef c As
> String)
> _a = a
> _b = b
> _c = c
> EndSub
> EndClass
> And now the derived class:
> Public Class child
> Inherits parent
> ' apparently, i have to redeclare the private vars found in the
> parent?
> Private _a As Long
> Private _b As Long
> Private _c As String
> ...
> ' cannot inherit the constructor, so define identical one here
> Public Sub New(ByVal a As Long, ByVal b As Long, ByRef c As
> String)
> ' call mybase.new to assign vars
> MyBase.New(a, b, c)
> EndSub
> EndClass
> By calling 'mybase.new' in the child class, I had expected the var
> assignments in the parent to be executed, populating the vars declared
> in the child.
> What I found with the above class definitions is that the child 'var
> _c' is NOT assigned a value.
> I'm sure there's a simple answer, but I'm a beginner. Also, I found
> some MSDN articles on class inheritance in the 'Upgrading to .NET'
> section, but am looking for something that goes deeper. Any idea
> where I can find articles that go into greater depth on the subject of
> class inheritance?
> Thanks... Jon
Thursday, March 22, 2012
Newbie IIS6 question: How to delete items from the Default Application Pool?
When I launch IIS Manager and expand Application Pools >> DefaultAppPool,
there are some Default Applications, and also a bunch of stuff that is
residue from practice web applications created from Visual Studio.Net:
WebApplication1, WebApplicationi2, etc.
How do I delete this stuff (the defunct WebApplication1, etc) and why is it
still there?
Thanks in Advance.The application details are stored in the IIS Metabase. You can use the
Metabase Explorer to delete them if they no longer exist.
If you delete the folder hosting a web application directly off the file
system (eg via Explorer), IIS doesn't know that, and the web application
remains defined in the metabase.
Instead, you should use the IIS Manager to delete the web application root
first (properties of the web app, and click "remove" on the directory tab,
where the Application Root settings are), then delete the folder off the
hard disk.
Metabase Explorer is available from:
http://www.microsoft.com/downloads/...&DisplayLang=en
Cheers
Ken
"deko" <deko@.hotmail.com> wrote in message
news:NiIhc.54063$Bo3.38355@.newssvr25.news.prodigy. com...
: Running IIS 6 on WS03
:
: When I launch IIS Manager and expand Application Pools >> DefaultAppPool,
: there are some Default Applications, and also a bunch of stuff that is
: residue from practice web applications created from Visual Studio.Net:
: WebApplication1, WebApplicationi2, etc.
:
: How do I delete this stuff (the defunct WebApplication1, etc) and why is
it
: still there?
:
: Thanks in Advance.
:
:
:
> The application details are stored in the IIS Metabase. You can use the
> Metabase Explorer to delete them if they no longer exist.
> If you delete the folder hosting a web application directly off the file
> system (eg via Explorer), IIS doesn't know that, and the web application
> remains defined in the metabase.
> Instead, you should use the IIS Manager to delete the web application root
> first (properties of the web app, and click "remove" on the directory tab,
> where the Application Root settings are), then delete the folder off the
> hard disk.
> Metabase Explorer is available from:
http://www.microsoft.com/downloads/...&DisplayLang=en
> Cheers
> Ken
Outstanding! I appreciate the clear and concise reply with a link to the
resource I needed. It worked great, and now I know how to avoid the problem
in the future. Thanks for the help!
Newbie looking for help... Data driven navigation
Is it possible to generate ASP.net website navigation based entirely on SQL queries?
If so, is it better to generate a static sitemap by running these queries only when a change is made to the database,
or
is it better to allow the queries to run "realtime" on page load and whenever a link is clicked?
Sorry if I'm not too clear, I'm still "extremely" wet behind the ears. ;-)
Thanks in advance,
Jeff
Well not sure if this is the answer you are looking for, but Asp.net 2.0 has a very good new feature Site Map where you can use the Site Map Provider to configure your Navigation of your website.
Hi,
Take a look at these tutorials
http://quickstarts.asp.net/QuickStartv20/aspnet/doc/ctrlref/data/sitemapdatasource.aspx
http://www.asp.net/learn/data-access/tutorial-62-cs.aspx
One thing you might want to do is cache the SiteMap the first time your page load, that way you will avoid unnecessary db roundtrips.
However if your SiteMap is going to be changing all the time than you can leave the caching out.
Goodluck
The second link is exactly what I was looking for. Thanks.
The link you posted is appending an extra character though, breaking the link, so I reposted it below. (This link points to the VB tutorial)
http://www.asp.net/learn/data-access/tutorial-62-vb.aspx
Jeff
Friday, March 16, 2012
Newbie needs help on messagebox
happen before running a piece of code. I need to have a messagebox that does
the typical 'Everything is done.' after I've run some VB code.
Here's the code snippet:
In my .aspx page:
<asp:linkbutton id="btnDeleteGroup" runat="server"
onclick="btnDeleteGroup_Click">Delete Group</asp:linkbutton>
In my page load function:
Me.btnDeleteGroup.Attributes.Add("onclick", "javascript:if (confirm('Do
you really want to this group?')== false) return false;")
In my code file, there's a function:
Protected Sub btnDeleteGroup_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs)
<do some stuff...>
' Need to display a 'All done' message to the user.
end subUse a hidden input to pass message strings from server to client. On the
client handle body's onload event. In the event handler check the input. If
it is not empty, call alert() to produce a messagebox with the message.
BTW, here is an improvement to your code:
Me.btnDeleteGroup.Attributes.Add("onclick", "return confirm('Do you really
want to this group?');")
Eliyahu
"UJ" <fred@.nowhere.com> wrote in message
news:%23AeRcytWFHA.2692@.TK2MSFTNGP15.phx.gbl...
> I've seen lots of messages about how to get a confirmation messagebox to
> happen before running a piece of code. I need to have a messagebox that
does
> the typical 'Everything is done.' after I've run some VB code.
> Here's the code snippet:
> In my .aspx page:
> <asp:linkbutton id="btnDeleteGroup" runat="server"
> onclick="btnDeleteGroup_Click">Delete Group</asp:linkbutton>
> In my page load function:
> Me.btnDeleteGroup.Attributes.Add("onclick", "java script:if
(confirm('Do
> you really want to this group?')== false) return false;")
> In my code file, there's a function:
> Protected Sub btnDeleteGroup_Click(ByVal sender As System.Object, ByVal e
As
> System.EventArgs)
> <do some stuff...>
> ' Need to display a 'All done' message to the user.
> end sub
>
Newbie needs help on messagebox
happen before running a piece of code. I need to have a messagebox that does
the typical 'Everything is done.' after I've run some VB code.
Here's the code snippet:
In my .aspx page:
<asp:linkbutton id="btnDeleteGroup" runat="server"
onclick="btnDeleteGroup_Click">Delete Group</asp:linkbutton
In my page load function:
Me.btnDeleteGroup.Attributes.Add("onclick", "javascript:if (confirm('Do
you really want to this group?')== false) return false;")
In my code file, there's a function:
Protected Sub btnDeleteGroup_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs)
<do some stuff...
' Need to display a 'All done' message to the user.
end subUse a hidden input to pass message strings from server to client. On the
client handle body's onload event. In the event handler check the input. If
it is not empty, call alert() to produce a messagebox with the message.
BTW, here is an improvement to your code:
Me.btnDeleteGroup.Attributes.Add("onclick", "return confirm('Do you really
want to this group?');")
Eliyahu
"UJ" <fred@.nowhere.com> wrote in message
news:%23AeRcytWFHA.2692@.TK2MSFTNGP15.phx.gbl...
> I've seen lots of messages about how to get a confirmation messagebox to
> happen before running a piece of code. I need to have a messagebox that
does
> the typical 'Everything is done.' after I've run some VB code.
> Here's the code snippet:
> In my .aspx page:
> <asp:linkbutton id="btnDeleteGroup" runat="server"
> onclick="btnDeleteGroup_Click">Delete Group</asp:linkbutton>
> In my page load function:
> Me.btnDeleteGroup.Attributes.Add("onclick", "javascript:if
(confirm('Do
> you really want to this group?')== false) return false;")
> In my code file, there's a function:
> Protected Sub btnDeleteGroup_Click(ByVal sender As System.Object, ByVal e
As
> System.EventArgs)
> <do some stuff...>
> ' Need to display a 'All done' message to the user.
> end sub