Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to Print/Show Contents of a Variable 1

Status
Not open for further replies.

JohnBates

MIS
Feb 27, 2000
1,995
0
0
US
Hi experts.

This is a very elementary question about VBscript.

When I'm running this in Debug mode, I want to display the value of the sMonthName variable.

Dim curDate As Date
Dim sMonthName As String
Dim iMonth As Integer
curDate = Now
sYear = DatePart(DateInterval.Year, curDate)

iMonth = DatePart(DateInterval.Month, curDate)

sMonthName = CStr(MonthName(iMonth))

**Print(sMonthName)** This does not work.

How can I display sMonthName - just when I'm debugging the scropt?

Thanks, John
 
Your code is not vbscript... you should try one of those forums:
forum222
forum796

If vb6, this should do what you want:
Debug.Print sMonthName
 
Thanks guitarzan.

You're correct. I'm using Microsoft SQL Server Integration Services Script Task which is Visual Basic

John
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top