I've recently upgraded from VWD 2008 Express to Visual Studio 2008 Professional edition, and installed Telerik's RadControls. Now, when I create a new Telerik project, I get the following errors: Namespace or type specified in the project-level Imports 'System.Xml.Linq' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases. Namespace or type specified in the project-level Imports 'System.Linq' doesn't contain any public member [etc...] The Web.config file contains the following:
[Code]....
I can fix one error if I right-click on my references folder, select "Add Reference...", select the ".NET" tab, and find System.Xml.Linq, but System.Linq isn't there, or anywhere else that I can see.
I've just got a new PC set up with windows 7. I mainly do front-end dev, but have done some classic ASP and .NET too. My 'systems admin' skills aren't too good, so I'm looking for advice as to the best way to set up my sites locally.
I built a new asp.net web app just now in Visual Studio 2010 Express, and by default it created a new project in: C:UsersMyNameDocumentsVisual Studio 2010Projects. I then needed to do some work on an old legacy classic ASP site, so I created a new folder in the same 'Projects' directory and loaded my files in there. I then went in to IIS to create this site so I can preview it locally but when I locate the content directory and click 'Test settings...' I get the following authentication error:
"The server is configured to use pass-through authentication with a built-in account to access the specified physical path. However, IIS Manager cannot verify whether the built-in account has access. Make sure that the application pool identity has Read access to the physical path. If this server is joined to a domain, and the application pool identity is NetworkService or LocalSystem, verify that <domain><computer_name>$ has Read access to the physical path. Then test these settings again." Which I don't really understand how to resolve.
I have a datalayer that uses Linq to SQL , inorder to maintain properly I removed various references to the connection strings to be placed in the same location.
So used the base(ConfigurationSettings.ConnectionString[""].ConnectionString,mappingsource) in the dbml.designer.cs file.
But doing this we have to define the connection strings in the web.config of all the projects that are going to use the data layer.. instead is there a way where in I can define the connection strings in the app.config of the data layer project and have the dbml.designer.cs file to pick from this one place?
From Windows Server 2003 Std Ed SP, 32 bit VMWare Virtual Server
.Net Framework v1.1.4322
When attempting to run a hello world aspx page it fails to load returning the message "Server Application Unavailable". The application even viewer logged the following:
Event Type: Error Event Source: ASP.NET 1.1.4322.0 Event Category: None Event ID: 1088 Description: Failed to execute request because the App-Domain could not be created. Error: 0x80070002 The system cannot find the file specified.
I tried to run aspnet_regiis.exe -i, rebooted but this did not work.
I tried to uninstall, reboot, reinstall .net from the Windows component section of Add/Remove Programs.
I am running Windows Server 2008, ASP.NET 3.5, IIS7 i wonder if it's IIS7 problem, or .NET Framework or even security updates problem suddenly all websites do not work, and from event viewer there're two errors
Exception: System.TypeLoadException
Message: Could not load type 'System.Security.Authentication.ExtendedProtection.ChannelBinding' from assembly 'System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.
StackTrace: at System.Web.Hosting.IIS7WorkerRequest.Dispose()
at System.Web.Hosting.PipelineRuntime.DisposeHandlerPrivate(HttpContext context) at System.Web.HttpRuntime.FinishRequestNotification(IIS7WorkerRequest wr, HttpContext context, RequestNotificationStatus& status) at System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) at System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags) at System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags) Faulting application w3wp.exe, version 7.0.6002.18005, time stamp 0x49e023cf, faulting module kernel32.dll, version 6.0.6002.18005, time stamp 0x49e037dd
I have a table "OSTAN" with two columns "ID" (Key index) and "NAME". I am trying to construct a linq query to select the Name for a specific ID. I have not luck trying to construct the where clause. Here what I have so far:
using (XeledsEntities db = new XeledsEntities()) { string SelectedName = db.Ostans.Name.Where( Ostan=> Ostan.Equals(Request.QueryString["Ostan"])).FirstOrDefault(); }
Can anybody construct this where clause to set the Selected Name?
I've just used Visual Studio to create a linq to sql class. In the .designer.cs file the code includes:using System.Data.Linq;However, when I compile the projeget:Compiler Error Message: CS0234: The type or namespace name 'Linq' does not exist in the namespace 'System.Data' (are you missing an assembly reference?)The code is completely generated by Visual Studio
In machine XPSP2, I tried to install SQL SErver 2005 express edition (downloaded from the microsoft site) - after mode selction form (Windows/SQL server authentication) - system restarted, automatically.Again restarted, Again restarted,Again restarted,Again restarted,a 1000 times or more.finally I unplugged the system from the UPS
I wasted the better part of the day on this and am no closer to a understanding the issue than what I was this morning.
I am looping through a set of objects and marking them for deletion. The 2nd one always causes the above exception. tb_invoice has a FK to tb_shipment.
As always, I am probably missing something very obvious, but I have stripped out so much from this code already that there is nothing left, and I am still getting this exception. This is a local SQL 2008 instance and there is of course nothing and nobody changing the invoice in between reading them and calling SubmitChanges().
myDataContext db = new myDataContext(); IQueryable<invoiceDetail> pendingInvoices db.GetInvoiceDetailPending(); foreach (invoiceDetail id in pendingInvoices) { tb_shipment s = db.GetShipmentById((Guid)id.shipment_id); db.tb_invoices.DeleteOnSubmit( db.GetInvoiceById(s.tb_invoices.FirstOrDefault().id)); } SubmitChanges(); // fails for the 2nd invoice }
I am using System.Linq.Dynamic to create the following query at runtime:
[Code]....
I can then successfully display vMediaQ in a GridView.But I need to be able to access the individual fields (column headers and data) in vMediaQ, which is of type System.Linq.IQueryable.
In some of my new websites under .NET 4.0 my Visual Studio does not recognize System.Linq as a valid class. I need to add a reference to System.Core in Web.Config to solve this but there are projects where this is not needed.
I have a System.Data.Linq.DataContext object and need to know the proper way of closing it out before it goes out of scope in order to prevent the following error when making a bunch of database changes:
Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.
Can I just call obj.Dispose() or do I need to call obj.Connection.Dispose() or obj.Connection.Close()?
I guess what I want to know is will calling obj.Dispose() end up executing the functionality in obj.Connection.Dispose() and obj.Connection.Close(). The MSDN documentation that I found on these functions does not have this information (at least I didn't see it - I could have mistakenly overlooked it).
I have downloaded Visual Web Developer 2010 Express and am trying to use LINQ. In order to do that I have added a LINQ to SQL class to the web site and have dragged tables from the database view into the LINQ designer, which worked fine.But..When I add: using System.Data.Linq;to MainPage.xaml.cs, I receive an error:
Error 3 The type or namespace name 'Data' does not exist in the namespace 'System' (are you missing an assembly reference?)Even although I have references to System.Core, System.Data, System.Data.Linq in the website references.
I need a linq-to-sql use dbml, then I follow this article : http://www.west-wind.com/weblog/posts/147218.aspxSet the child to internal, set serialzable to unidirection and add updatecheck=never
Is there a way to do the following in VB:dim sTableClass as string = <my underlying table class in linq>dim dbTab as system.data.linq.table(<typed class of sTableClass>)I've tried cycling through the table objects of the linq data context and retrieved the following: Dim ddData = pkDB.GetTable(tt.RowType.Type.UnderlyingSystemType)(where tt reflects the row of the table I want to retrieve) But the expression returns and itable and I need the table equivalent but can't get this to work with a stri
If I have below code, how to make it work as it has below compile error:
Error: cannot implicitly convert type 'System.Linq.Iqueryable<system.data.DataSet> to 'System.Data.Dateset'. An explicit conversion exists.
public DataSet GetProductList() { using (var sdatabase = new DatabaseDataContext()) { IQueryable<DataSet> result = wmsdatabase.ExecuteQuery<DataSet>(@"SELECT productid, productname from product group by productid, productname").AsQueryable(); return result; // Compile error here } }
I am having a lot of the same issue as this poster did with errors on initializing type.
I am trying to learn linq and am about ready to give up - don't get how this is easier...
I'm trying to do a simple update to product names in the product table based on the manufacturer ID
In order to do this I am looping through each record. I was initally successful with changing all names in the column but when I try to query the data, I continually run into multiple problems.
The following poster has had the same issue I have but his solution isn't working for me.
[URL]
I keep getting the same error on the opening bracket on the select statement in the SelectByManufacturerID function...
Error 1 Cannot initialize type 'DataBaseDataManagement.ProductName' with a collection initializer because it does not implement 'System.Collections.IEnumerable'
Button that does the actual updating...
[Code]....
The function that the button calls to get the query... ERROR