• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2909
  • Last Modified:

draw a single line by VBScript

Can anyone show me how to draw a line by using VBScript.
0
chkwah
Asked:
chkwah
1 Solution
 
JOKCommented:
You can't do graphics with vbscript. You could use the html <hr> tag. You're more likely to be able to do stuff like that with JavaScript and DHTML.
0
 
AemerginCommented:
Another option you might have is to us a table, and give that table a border. This will allow you to do underlines, overlines, and vertical lines on either the left or right side.

-Aemergin
0
 
chkwahAuthor Commented:
JOK:

If JavaScript can do that.
So, can you pls show the the way.
Thank you.
0
 
jamestthomasCommented:
This is simplistic I know but just to toss it out...in an ASP page of course any HTML can be written using VBscript.
You can then impose conditions for howyou want your page to look.  So chkwah, you may do something like

<%If MyConditon = True then %>
     <hr>
<%End If%>

-OR-

<%
If MyConditon = True then
   Response.Write "<hr>"
End If
%>

 
0
 
xabiCommented:
You can only "draw" vertical and horizontal lines this way:

1st create a table with border="0" cellpadding="0" cellspacing="0" width=""

2nd insert into it a transparent 1x1 gif pixel

3th give the cell a color

4th change the width and height of the pixel:

example:

<table border="0" cellspacing="0" cellpadding="0">
  <tr><td bgcolor="black"><img src="point.gif" with="100" height="2"></td></tr>
</table>

this with draw a 100x2 horizontal black line

xabi
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now