AutoCAD绘图无环ACAD的实体:您好,
如何从AutoCAD图形文件,而无需使用循环实体。我试图找到ACAD的实体使用ACAD块的,没有使用循环。但我没有得到ACAD单位acadbockreference。 NBSP
- 阿莫尔
Dim dt As New Date
dt = "26-12-2011"
Dim a As Integer = 6
Dim a1 As Integer = 1
While a1 <= Len(dt)
If a = Mid(dt, a1, 1) Then
MsgBox(a)
Exit While
End If
a1 = a1 + 1
End While
/*
* Created by SharpDevelop.
* User: Peri 沤eljko
* Date: 27.12.2011
* Time: 14:50
*
*/
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Windows.Forms;
namespace Date_and_days
{
/// <summary>
/// Description of MainForm.
/// </summary>
public partial class MainForm : Form
{
public MainForm()
{
//
// The InitializeComponent() call is required for Windows Forms designer support.
//
InitializeComponent();
}
void DataGridView1CellEndEdit(object sender, DataGridViewCellEventArgs e)
{
//
// Event occurs when edit mode for the current cell ends,
// afther you press enter, or click on other cell i DataGridView control
//
//
// Local variables
//
DateTime Date;
int row = 0;
int column = 0;
bool IsDate = false;
row = dataGridView1.CurrentCell.RowIndex;
column = dataGridView1.CurrentCell.ColumnIndex;
//
// If edit mode ends for the cell in the first column,Date column.
//
if (column == 0)
{
//
// Checks if you have entered Date in first column, Date column.
//
// IsDate is true if it is Date entered into Date column,
// the value of the entered date is set out to Date variable,
// afther that program write the day of the week from entered date into
// seckond column Day of the week column.
//
// else program sets the value of the seckond column to empty string
//
IsDate = DateTime.TryParse(dataGridView1.CurrentCell.Value.ToString(),out Date);
if (IsDate)
{
dataGridView1[column+1,row].Value = Date.DayOfWeek.ToString();
}
else
{
dataGridView1[column+1,row].Value = String.Empty;
}
}
}
}
}