|
Actually, if you use the IIS to run your ASP.NET 2.0 application, then you can run in the same way as you would with the version 1.x. With the built-in server, you are required to start the server from the command line if you don't want to hit f5 or ctrl+f5.
Web Servers in Visual Web Developer [^]
|
|
|
|
|
Sorry for the delay.
Iam using IIS as my web server.
I've tried to run asp.net2.0 application like I would do in 1.x, but I get an error about xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0" so that configuration node doesen't have attribute name specified above (xmlns...).
When I run from VS.NET, it runs OK.
The project structure is:
ProjectName
|
+- ProjectName
| |
| +- Default.aspx
| |
| +- Web.Config
| |
| +- ...
|
+- ProjectName.sln
Maybe this is source of the problem, but Iam not sure becouse I copy the second folder (ProjectName) anywhere in the hdd and create an applcation in IIS management console and it should work (this will work in 1.x), but it doesen't.
Any ideas?
|
|
|
|
|
Hi there,
Are you sure that you pick up the right version of the ASP.NET runtime for your application? In the IIS snap-in, you can right click the application entry and go to the ASP.NET tab, then have a look at the selected version. Also, in the VS 2005, it allows you to create a web site using the IIS instead of the File System (by default).
|
|
|
|
|
hi all,
can anyone guide me in creating an web custom control for wizard control in asp 2.0.
advance thanks
ShadesRulz
|
|
|
|
|
|
hi Satips,
well, the link shows how to create in standalone website.
but am talking how to generate the same thru code.
something like we do in creating web custom control like this
protected override void CreateChildControls()
{
Wizard myWizard = new Wizard();
//myWizard.DisplaySideBar = false;
myWizard.Height = 300;
myWizard.Width = 300;
myWizard.BorderColor = Color.Black;
myWizard.BorderWidth = new Unit(2);
WizardStepBase WIZARDSTEP1 = new WizardStep();
WIZARDSTEP1.ID = "0";
Label first = new Label();
first.Text = "first";
WIZARDSTEP1.Controls.Add(first);
WIZARDSTEP1.StepType = WizardStepType.Start;
myWizard.WizardSteps.Add(WIZARDSTEP1);
WizardStepBase WIZARDSTEP2 = new WizardStep();
WIZARDSTEP2.ID = "1";
Label second = new Label();
second.Text = "second";
WIZARDSTEP2.Controls.Add(second);
WIZARDSTEP2.StepType = WizardStepType.Step;
myWizard.WizardSteps.Add(WIZARDSTEP2);
WizardStepBase WIZARDSTEP3 = new WizardStep();
WIZARDSTEP3.ID = "2";
Label three = new Label();
three.Text = "three";
WIZARDSTEP3.Controls.Add(three);
WIZARDSTEP3.StepType = WizardStepType.Complete;
myWizard.WizardSteps.Add(WIZARDSTEP3);
Controls.Add(myWizard);
}
}
ShadesRulz
|
|
|
|
|
Hi, im new to asp.net and having some trouble with user controls.
The senario is this,
I have 4 files,
control.ascx - my custom control
control.ascx.cs - the codebehind file for my custom control
page.aspx - the page im placing the control in
page.aspx.cs - the codebehind file for the page
I have successfully created the control and placed into page.aspx and it works, the problem is that i cannot access the control from the page.aspx.cs code behind file
assuming the control class is MyControl and the page class is MyPage, if i try to access the control class MyControl from MyPage in the page.aspx.cs codebehind file i get a compilation error saying that the type or namespace MyControl doesnt exist. However if i place the code directly into the page.aspx file it works just fine. So how can i access the custom control classes that i create in codebehind files?
|
|
|
|
|
Can you persist the dynamic control in a web page class's variable so that you can reuse it later? In addition, there are a couple of ways that you can use to programmatically get reference to the control.
Accessing ASP.NET Controls Programmatically [^]
|
|
|
|
|
The problem isnt getting the control into a variable, its getting it as the correct type.
For example if i can get it as a UserControl but then i cant access the customized features of the class for example control.MyProperty = "123" wont work, i need to be able to cast it to a MyControl class. But in the code behind file asp.net cant resolv the class name. It does work fine however if i place the code direct into the aspx file instead of the codebehind file.
e.g. i can use the LoadControl function like this
UserControl c = LoadControl("control.ascx");
but if i try to cast it to MyControl it fails because it can resolve the name MyControl
MyControl mc = (MyControl)LoadControl("control.ascx");
but it only fails in the codebehind file, not in the aspx page its self.
|
|
|
|
|
In the ASP.NET 2.0, you will need to use the @ Reference[^] directive to link to the type of the web user control so that you can access its custom members. Another option is that you can define the custom properties in an interface or a base class and have the web user control implement the interface or inherit from the base class, then you can cast the runtime object to the interface/baseclass.
|
|
|
|
|
Turns out it was a little pequliarity between some asp.net 1.1 and asp.net 2.0 features. I was linking the codebehind file to the aspx page using Src attribute so i didnt have to go compiling the classes all the time but it doesnt seem to like that. Where as if i use the asp.net 2.0 CodeFile attribute which i just found out about then it all works just fine.
Thanks for you help anyway.
|
|
|
|
|
Hi Friends,
I have created some web services. I added them using my local IIS.
Now I want to upload it to my domaing hosting server.
I dont know the proceduere.I cppied my all folders there, now i am trying to add those services into my project using visual studion add web references.
I am connected to internet.
visual studio is not finding those services.
This is first time i have developed web services and trying to develop.
If some one could help me how it will work I would be obliged.
thanks
Naveed Kamboh
|
|
|
|
|
Can you browse manually to the webservices (on your ISP's server) by putting the .asmx url into a web browser?
|
|
|
|
|
Yes I can see file via direct access.
Naveed Kamboh
|
|
|
|
|
Thanks dear,
Its working now.
I didn't think like that.
Cheers
Naveed Kamboh
|
|
|
|
|
Sir,
What are Secured Socket Layers .I want to implement it in the project.(an online project).
Please help.
Thanks
Can i get a code project link in vb.net 1.1 with asp.net that uses the Secure Sockets Layer (SSL)?
|
|
|
|
|
|
Sir,
Thanks for ur kind attention.But the link u gave is displaying the message that The page u requested does not exist.
|
|
|
|
|
Hi,
Please Open it by the link with new window.
With Regards
Satips
|
|
|
|
|
Plz Help.
How can I put asp.net control output HTML into a string variable (or string builder).
|
|
|
|
|
You can call the Control.RenderControl method of the control to get the output html markup of that control, then you can put it in a string variable in the way you want.
|
|
|
|
|
I have two textboxes in which in one box i'll type text in english,other textbox will have converted text according to selected language(ex:Hindi).
And if i click the My Search button,Google Search Engine should search that hindi word in their Google Search and displays the Searched text in Hindi Language.
Sathiyaraj Ganesan
|
|
|
|
|
i want to enable one of the security setting in Custum Level of Trusted Site zone in IE.How can we do it programatically.
|
|
|
|
|
As in change the security from your web page? Not easily. Being able to change a users security setting from your web page would constitute a major hole in IE security. You would need to write and sign an ActiveX control to do this, and even then, it would not be trivial. Alternatively, you would write an windows executable to do this and allow your users to download and run the .exe to adjust their security settings needed to work with your web app.
|
|
|
|
|
Thanks jim but can u please tell me what code will sort out my problem
|
|
|
|