all groups > sql server reporting services > december 2005 >
You're in the

sql server reporting services

group:

Q: convert this to Code


Q: convert this to Code JIM.H.
12/30/2005 11:59:02 AM
sql server reporting services:
Hello,

This is my code in C#

DateTime sYear = new DateTime(Now(),1,1);
DateTime q1Start = sYear;
DateTime q2Start = sYear.AddMonths(3);
DateTime q3Start = sYear.AddMonths(6);
DateTime q4Start = sYear.AddMonths(9);
DateTime q1End = q2Start.AddDays(-1);
DateTime q2End = q3Start.AddDays(-1);
DateTime q3End = q4Start.AddDays(-1);
DateTime q4End = sYear.AddYears(1).AddDays(-1);


Can anyone convert this to VB.Net so that I can use it in “Code” section of
the Reporting Services. I tried a VB-C# converter but Reporting Services did
not like DateTime datatype.

Any help?
Re: Q: convert this to Code Potter
12/30/2005 12:41:17 PM
Jim,

Use System.DateTime, remove the semicolons and use VB.NET style
variable declaration.

Dim sYear as System.DateTime = blah

Andy Potter
AddThis Social Bookmark Button