ExecuteNonQuery: Connection property has not been initialized.
-عندما تريد ان تعرف عدد الصفوف المتأثرة فى الداتا بيز فانك تستخدم الجملة التاليه 
; ()int x = com.ExecuteNonQuery
** ولكن يظهر لك خطأ عند التنفيذ ان الاتصال لم يتم !
قبل الانتهاء من كتابة الاتصال واغلاقه وماتحتاجه من تنفيذ 
    
; com.CommandType= CommandType.StoredProcedure
 
:sol
put command equal connection
You need to assign the connection to the SqlCommand"
"you can use the constructor or the property
; com.Connection = conn
 ;  SqlConnection conn
;    SqlCommand com
;()conn = new SqlConnection
 ;()  com = new SqlCommand
 ;""=conn.ConnectionString 
; com.CommandType= CommandType.StoredProcedure
**لابد من مساوة اتصال ال SqlCommand ب  SqlConnection
الحل اضافة السطر الاتى :
;com.Connection = conn
*************************************************
:error 
.ExecuteNonQuery: Connection property has not been initialized:sol
put command equal connection
You need to assign the connection to the SqlCommand"
"you can use the constructor or the property
; com.Connection = conn