I have more than 5 DBs in Sql Server that each has more that 150 tables with
complex Relations that use GUID primary Keys and Foreign Keys very heavily
and I need to create data Entry Forms for them
so the smooth running of the created forms and ease of data Entry for users
while fast , robust designation of the forms are important so I heavily rely
on InBuilt bahvior of data bound controls rather than changing them or
creating user controls (besides the end users are more familiar with the
..Net Controls behaviors)
because of that some function that gengerates defualt values for the GUID
fields is the prefered way if possible so it will require less event handler
coding and coding for detection of false data Error exceptions or coding for
correcting the unwanted behaviors caused by these?!
besides where is the Data Form Generator that was in New Item window in
previous versions of VS .Net ?
"Leon_Amirreza" <am**************@yahoo.comwrote in message
news:OA****************@TK2MSFTNGP03.phx.gbl...
chances of collsion may be a problem but simplicity of management of
dataset and code is more important to me I would rather prefer to use
something like newid() function in default value of the field in the typed
dataset. because requires less tricks and code than for example ommiting
the Primary Key or attaching a handler to the TableNewRow and DataBound
controls are aware of the difference between default values and user
Entered values in firing their event handlers or raising Data Error
Exceptions and .....
"Leon_Amirreza" <am**************@yahoo.comwrote in message
news:eA****************@TK2MSFTNGP03.phx.gbl...
>>I have a column named "ID" and its type is "uniqueidentifier" in SQL
Server
2005 Express.
this column is the primary key and its default value is "newid()" in SQL
Server.
I have generated a DataSet in C# that has this column but its default
value
is DBNull what can I do to make the default value be the return value of
this function ( or I want the Id be generated by default in the DataSet)?
System.Guid.NewGuid()