Solved

Linq Error

Posted on 2010-08-29
3
461 Views
Last Modified: 2012-05-10
This code:
Dim timeformat2 As String = "d/MMM/yyyy"

Select New With {a.CTS = Convert.ToDateTime(a.CT).ToString(timeformat2), a.MD}

Open in new window


Thows this error: 'Anonymous type member name can be inferred only from a simple or qualified name with no arguments'

Has anyone else had this problem/found a solution?

Thanks in advance,

Jonathan
0
Comment
Question by:jonathangodwin
  • 2
3 Comments
 

Expert Comment

by:mikek1966
ID: 33552250
To correct this error
•Assign the expression to a member name, as shown in the following code:

CopyDim instanceName2 = New With {.number = numbers(3)}
0
 
LVL 27

Expert Comment

by:nmarun
ID: 33555771
0
 
LVL 27

Accepted Solution

by:
nmarun earned 500 total points
ID: 33555798
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

792 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question