help

1. Senior Member
Join Date
Dec 1969
Posts
214

## help

Hi,<BR><BR>I want to gave a variable the value of 01 but it keeps returning 1<BR>How can I do it so the 0 stays there?<BR>&#060;%<BR>Dim nDex<BR>nDex = 01<BR>response.write"&(nDex)&"<BR>%&#062;

2. Senior Member
Join Date
Dec 1969
Posts
1,032

## RE: help

&#060;%<BR>Dim nDex<BR>nDex = "01"<BR>response.write"&(nDex)&"<BR>%&#062;<BR><BR >jon

3. Senior Member
Join Date
Dec 1969
Posts
214

## RE: help

That dosen^t seem to work here is all my code:<BR><BR>&#060;%<BR>for nDex = 8 to 22<BR>if nDex = 8 then<BR>nDex = "08"<BR>end if<BR>response.write"&#060;tr&#062;&#060;td&#062;" (nDex)&":00&#060;/td&#062;&#060;/tr&#062;"<BR>next<BR>%&#062;<BR><BR>What I&#039;m trying to do is display the numbers 8 to 22 in time format so that I have 08:00 to 22:00. Maybe I&#039;m going the wrong way about this so if you have a better way please tell me.

4. Senior Member
Join Date
Dec 1969
Posts
1,032

## RE: help

&#060;% <BR><BR>response.Write "&#060;table&#062;"<BR>for nDex = 8 to 22 <BR>if nDex = 8 or nDex=9 then <BR>nDex = "0"&nDex <BR>end if <BR>response.write"&#060;tr&#062;&#060;td&#062;"&n Dex&":00&#060;/td&#062;&#060;/tr&#062;" <BR>next <BR>response.Write "&#060;/table&#062;"<BR>%&#062;<BR><BR>jon

5. Senior Member
Join Date
Dec 1969
Posts
476

## RE: help

for nDex = 8 to 22<BR> if nDex &#060; 10 then<BR> strnDex = "0" & nDex & ":00"<BR> else<BR> strnDex = nDex & ":00"<BR> end if<BR> response.write "&#060;tr&#062;&#060;td&#062;" & strnDex & "&#060;/td&#062;&#060;/tr&#062;"<BR>next

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•