fab2022DataSet.Designer.cs 88 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550
  1. //------------------------------------------------------------------------------
  2. // <auto-generated>
  3. // This code was generated by a tool.
  4. // Runtime Version:4.0.30319.42000
  5. //
  6. // Changes to this file may cause incorrect behavior and will be lost if
  7. // the code is regenerated.
  8. // </auto-generated>
  9. //------------------------------------------------------------------------------
  10. #pragma warning disable 1591
  11. namespace Пример_плиточного_интерфейса {
  12. /// <summary>
  13. ///Represents a strongly typed in-memory cache of data.
  14. ///</summary>
  15. [global::System.Serializable()]
  16. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  17. [global::System.ComponentModel.ToolboxItem(true)]
  18. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedDataSetSchema")]
  19. [global::System.Xml.Serialization.XmlRootAttribute("fab2022DataSet")]
  20. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.DataSet")]
  21. public partial class fab2022DataSet : global::System.Data.DataSet {
  22. private FurnituraDataTable tableFurnitura;
  23. private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
  24. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  25. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  26. public fab2022DataSet() {
  27. this.BeginInit();
  28. this.InitClass();
  29. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  30. base.Tables.CollectionChanged += schemaChangedHandler;
  31. base.Relations.CollectionChanged += schemaChangedHandler;
  32. this.EndInit();
  33. }
  34. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  35. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  36. protected fab2022DataSet(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  37. base(info, context, false) {
  38. if ((this.IsBinarySerialized(info, context) == true)) {
  39. this.InitVars(false);
  40. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  41. this.Tables.CollectionChanged += schemaChangedHandler1;
  42. this.Relations.CollectionChanged += schemaChangedHandler1;
  43. return;
  44. }
  45. string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
  46. if ((this.DetermineSchemaSerializationMode(info, context) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
  47. global::System.Data.DataSet ds = new global::System.Data.DataSet();
  48. ds.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
  49. if ((ds.Tables["Furnitura"] != null)) {
  50. base.Tables.Add(new FurnituraDataTable(ds.Tables["Furnitura"]));
  51. }
  52. this.DataSetName = ds.DataSetName;
  53. this.Prefix = ds.Prefix;
  54. this.Namespace = ds.Namespace;
  55. this.Locale = ds.Locale;
  56. this.CaseSensitive = ds.CaseSensitive;
  57. this.EnforceConstraints = ds.EnforceConstraints;
  58. this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
  59. this.InitVars();
  60. }
  61. else {
  62. this.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
  63. }
  64. this.GetSerializationData(info, context);
  65. global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
  66. base.Tables.CollectionChanged += schemaChangedHandler;
  67. this.Relations.CollectionChanged += schemaChangedHandler;
  68. }
  69. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  70. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  71. [global::System.ComponentModel.Browsable(false)]
  72. [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
  73. public FurnituraDataTable Furnitura {
  74. get {
  75. return this.tableFurnitura;
  76. }
  77. }
  78. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  79. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  80. [global::System.ComponentModel.BrowsableAttribute(true)]
  81. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)]
  82. public override global::System.Data.SchemaSerializationMode SchemaSerializationMode {
  83. get {
  84. return this._schemaSerializationMode;
  85. }
  86. set {
  87. this._schemaSerializationMode = value;
  88. }
  89. }
  90. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  91. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  92. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
  93. public new global::System.Data.DataTableCollection Tables {
  94. get {
  95. return base.Tables;
  96. }
  97. }
  98. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  99. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  100. [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
  101. public new global::System.Data.DataRelationCollection Relations {
  102. get {
  103. return base.Relations;
  104. }
  105. }
  106. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  107. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  108. protected override void InitializeDerivedDataSet() {
  109. this.BeginInit();
  110. this.InitClass();
  111. this.EndInit();
  112. }
  113. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  114. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  115. public override global::System.Data.DataSet Clone() {
  116. fab2022DataSet cln = ((fab2022DataSet)(base.Clone()));
  117. cln.InitVars();
  118. cln.SchemaSerializationMode = this.SchemaSerializationMode;
  119. return cln;
  120. }
  121. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  122. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  123. protected override bool ShouldSerializeTables() {
  124. return false;
  125. }
  126. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  127. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  128. protected override bool ShouldSerializeRelations() {
  129. return false;
  130. }
  131. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  132. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  133. protected override void ReadXmlSerializable(global::System.Xml.XmlReader reader) {
  134. if ((this.DetermineSchemaSerializationMode(reader) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
  135. this.Reset();
  136. global::System.Data.DataSet ds = new global::System.Data.DataSet();
  137. ds.ReadXml(reader);
  138. if ((ds.Tables["Furnitura"] != null)) {
  139. base.Tables.Add(new FurnituraDataTable(ds.Tables["Furnitura"]));
  140. }
  141. this.DataSetName = ds.DataSetName;
  142. this.Prefix = ds.Prefix;
  143. this.Namespace = ds.Namespace;
  144. this.Locale = ds.Locale;
  145. this.CaseSensitive = ds.CaseSensitive;
  146. this.EnforceConstraints = ds.EnforceConstraints;
  147. this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
  148. this.InitVars();
  149. }
  150. else {
  151. this.ReadXml(reader);
  152. this.InitVars();
  153. }
  154. }
  155. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  156. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  157. protected override global::System.Xml.Schema.XmlSchema GetSchemaSerializable() {
  158. global::System.IO.MemoryStream stream = new global::System.IO.MemoryStream();
  159. this.WriteXmlSchema(new global::System.Xml.XmlTextWriter(stream, null));
  160. stream.Position = 0;
  161. return global::System.Xml.Schema.XmlSchema.Read(new global::System.Xml.XmlTextReader(stream), null);
  162. }
  163. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  164. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  165. internal void InitVars() {
  166. this.InitVars(true);
  167. }
  168. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  169. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  170. internal void InitVars(bool initTable) {
  171. this.tableFurnitura = ((FurnituraDataTable)(base.Tables["Furnitura"]));
  172. if ((initTable == true)) {
  173. if ((this.tableFurnitura != null)) {
  174. this.tableFurnitura.InitVars();
  175. }
  176. }
  177. }
  178. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  179. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  180. private void InitClass() {
  181. this.DataSetName = "fab2022DataSet";
  182. this.Prefix = "";
  183. this.Namespace = "http://tempuri.org/fab2022DataSet.xsd";
  184. this.EnforceConstraints = true;
  185. this.SchemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
  186. this.tableFurnitura = new FurnituraDataTable();
  187. base.Tables.Add(this.tableFurnitura);
  188. }
  189. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  190. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  191. private bool ShouldSerializeFurnitura() {
  192. return false;
  193. }
  194. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  195. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  196. private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) {
  197. if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) {
  198. this.InitVars();
  199. }
  200. }
  201. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  202. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  203. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  204. fab2022DataSet ds = new fab2022DataSet();
  205. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  206. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  207. global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
  208. any.Namespace = ds.Namespace;
  209. sequence.Items.Add(any);
  210. type.Particle = sequence;
  211. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  212. if (xs.Contains(dsSchema.TargetNamespace)) {
  213. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  214. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  215. try {
  216. global::System.Xml.Schema.XmlSchema schema = null;
  217. dsSchema.Write(s1);
  218. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  219. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  220. s2.SetLength(0);
  221. schema.Write(s2);
  222. if ((s1.Length == s2.Length)) {
  223. s1.Position = 0;
  224. s2.Position = 0;
  225. for (; ((s1.Position != s1.Length)
  226. && (s1.ReadByte() == s2.ReadByte())); ) {
  227. ;
  228. }
  229. if ((s1.Position == s1.Length)) {
  230. return type;
  231. }
  232. }
  233. }
  234. }
  235. finally {
  236. if ((s1 != null)) {
  237. s1.Close();
  238. }
  239. if ((s2 != null)) {
  240. s2.Close();
  241. }
  242. }
  243. }
  244. xs.Add(dsSchema);
  245. return type;
  246. }
  247. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  248. public delegate void FurnituraRowChangeEventHandler(object sender, FurnituraRowChangeEvent e);
  249. /// <summary>
  250. ///Represents the strongly named DataTable class.
  251. ///</summary>
  252. [global::System.Serializable()]
  253. [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
  254. public partial class FurnituraDataTable : global::System.Data.TypedTableBase<FurnituraRow> {
  255. private global::System.Data.DataColumn columnidfur;
  256. private global::System.Data.DataColumn columnnamefur;
  257. private global::System.Data.DataColumn columnphoto;
  258. private global::System.Data.DataColumn columncountfur;
  259. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  260. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  261. public FurnituraDataTable() {
  262. this.TableName = "Furnitura";
  263. this.BeginInit();
  264. this.InitClass();
  265. this.EndInit();
  266. }
  267. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  268. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  269. internal FurnituraDataTable(global::System.Data.DataTable table) {
  270. this.TableName = table.TableName;
  271. if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
  272. this.CaseSensitive = table.CaseSensitive;
  273. }
  274. if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
  275. this.Locale = table.Locale;
  276. }
  277. if ((table.Namespace != table.DataSet.Namespace)) {
  278. this.Namespace = table.Namespace;
  279. }
  280. this.Prefix = table.Prefix;
  281. this.MinimumCapacity = table.MinimumCapacity;
  282. }
  283. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  284. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  285. protected FurnituraDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
  286. base(info, context) {
  287. this.InitVars();
  288. }
  289. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  290. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  291. public global::System.Data.DataColumn idfurColumn {
  292. get {
  293. return this.columnidfur;
  294. }
  295. }
  296. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  297. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  298. public global::System.Data.DataColumn namefurColumn {
  299. get {
  300. return this.columnnamefur;
  301. }
  302. }
  303. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  304. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  305. public global::System.Data.DataColumn photoColumn {
  306. get {
  307. return this.columnphoto;
  308. }
  309. }
  310. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  311. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  312. public global::System.Data.DataColumn countfurColumn {
  313. get {
  314. return this.columncountfur;
  315. }
  316. }
  317. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  318. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  319. [global::System.ComponentModel.Browsable(false)]
  320. public int Count {
  321. get {
  322. return this.Rows.Count;
  323. }
  324. }
  325. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  326. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  327. public FurnituraRow this[int index] {
  328. get {
  329. return ((FurnituraRow)(this.Rows[index]));
  330. }
  331. }
  332. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  333. public event FurnituraRowChangeEventHandler FurnituraRowChanging;
  334. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  335. public event FurnituraRowChangeEventHandler FurnituraRowChanged;
  336. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  337. public event FurnituraRowChangeEventHandler FurnituraRowDeleting;
  338. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  339. public event FurnituraRowChangeEventHandler FurnituraRowDeleted;
  340. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  341. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  342. public void AddFurnituraRow(FurnituraRow row) {
  343. this.Rows.Add(row);
  344. }
  345. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  346. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  347. public FurnituraRow AddFurnituraRow(string namefur, string photo, int countfur) {
  348. FurnituraRow rowFurnituraRow = ((FurnituraRow)(this.NewRow()));
  349. object[] columnValuesArray = new object[] {
  350. null,
  351. namefur,
  352. photo,
  353. countfur};
  354. rowFurnituraRow.ItemArray = columnValuesArray;
  355. this.Rows.Add(rowFurnituraRow);
  356. return rowFurnituraRow;
  357. }
  358. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  359. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  360. public FurnituraRow FindByidfur(int idfur) {
  361. return ((FurnituraRow)(this.Rows.Find(new object[] {
  362. idfur})));
  363. }
  364. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  365. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  366. public override global::System.Data.DataTable Clone() {
  367. FurnituraDataTable cln = ((FurnituraDataTable)(base.Clone()));
  368. cln.InitVars();
  369. return cln;
  370. }
  371. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  372. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  373. protected override global::System.Data.DataTable CreateInstance() {
  374. return new FurnituraDataTable();
  375. }
  376. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  377. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  378. internal void InitVars() {
  379. this.columnidfur = base.Columns["idfur"];
  380. this.columnnamefur = base.Columns["namefur"];
  381. this.columnphoto = base.Columns["photo"];
  382. this.columncountfur = base.Columns["countfur"];
  383. }
  384. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  385. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  386. private void InitClass() {
  387. this.columnidfur = new global::System.Data.DataColumn("idfur", typeof(int), null, global::System.Data.MappingType.Element);
  388. base.Columns.Add(this.columnidfur);
  389. this.columnnamefur = new global::System.Data.DataColumn("namefur", typeof(string), null, global::System.Data.MappingType.Element);
  390. base.Columns.Add(this.columnnamefur);
  391. this.columnphoto = new global::System.Data.DataColumn("photo", typeof(string), null, global::System.Data.MappingType.Element);
  392. base.Columns.Add(this.columnphoto);
  393. this.columncountfur = new global::System.Data.DataColumn("countfur", typeof(int), null, global::System.Data.MappingType.Element);
  394. base.Columns.Add(this.columncountfur);
  395. this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
  396. this.columnidfur}, true));
  397. this.columnidfur.AutoIncrement = true;
  398. this.columnidfur.AutoIncrementSeed = -1;
  399. this.columnidfur.AutoIncrementStep = -1;
  400. this.columnidfur.AllowDBNull = false;
  401. this.columnidfur.ReadOnly = true;
  402. this.columnidfur.Unique = true;
  403. this.columnnamefur.MaxLength = 50;
  404. this.columnphoto.MaxLength = 50;
  405. }
  406. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  407. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  408. public FurnituraRow NewFurnituraRow() {
  409. return ((FurnituraRow)(this.NewRow()));
  410. }
  411. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  412. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  413. protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
  414. return new FurnituraRow(builder);
  415. }
  416. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  417. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  418. protected override global::System.Type GetRowType() {
  419. return typeof(FurnituraRow);
  420. }
  421. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  422. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  423. protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
  424. base.OnRowChanged(e);
  425. if ((this.FurnituraRowChanged != null)) {
  426. this.FurnituraRowChanged(this, new FurnituraRowChangeEvent(((FurnituraRow)(e.Row)), e.Action));
  427. }
  428. }
  429. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  430. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  431. protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
  432. base.OnRowChanging(e);
  433. if ((this.FurnituraRowChanging != null)) {
  434. this.FurnituraRowChanging(this, new FurnituraRowChangeEvent(((FurnituraRow)(e.Row)), e.Action));
  435. }
  436. }
  437. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  438. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  439. protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
  440. base.OnRowDeleted(e);
  441. if ((this.FurnituraRowDeleted != null)) {
  442. this.FurnituraRowDeleted(this, new FurnituraRowChangeEvent(((FurnituraRow)(e.Row)), e.Action));
  443. }
  444. }
  445. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  446. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  447. protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
  448. base.OnRowDeleting(e);
  449. if ((this.FurnituraRowDeleting != null)) {
  450. this.FurnituraRowDeleting(this, new FurnituraRowChangeEvent(((FurnituraRow)(e.Row)), e.Action));
  451. }
  452. }
  453. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  454. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  455. public void RemoveFurnituraRow(FurnituraRow row) {
  456. this.Rows.Remove(row);
  457. }
  458. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  459. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  460. public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
  461. global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
  462. global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
  463. fab2022DataSet ds = new fab2022DataSet();
  464. global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
  465. any1.Namespace = "http://www.w3.org/2001/XMLSchema";
  466. any1.MinOccurs = new decimal(0);
  467. any1.MaxOccurs = decimal.MaxValue;
  468. any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  469. sequence.Items.Add(any1);
  470. global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
  471. any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
  472. any2.MinOccurs = new decimal(1);
  473. any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
  474. sequence.Items.Add(any2);
  475. global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
  476. attribute1.Name = "namespace";
  477. attribute1.FixedValue = ds.Namespace;
  478. type.Attributes.Add(attribute1);
  479. global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
  480. attribute2.Name = "tableTypeName";
  481. attribute2.FixedValue = "FurnituraDataTable";
  482. type.Attributes.Add(attribute2);
  483. type.Particle = sequence;
  484. global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
  485. if (xs.Contains(dsSchema.TargetNamespace)) {
  486. global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
  487. global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
  488. try {
  489. global::System.Xml.Schema.XmlSchema schema = null;
  490. dsSchema.Write(s1);
  491. for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
  492. schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
  493. s2.SetLength(0);
  494. schema.Write(s2);
  495. if ((s1.Length == s2.Length)) {
  496. s1.Position = 0;
  497. s2.Position = 0;
  498. for (; ((s1.Position != s1.Length)
  499. && (s1.ReadByte() == s2.ReadByte())); ) {
  500. ;
  501. }
  502. if ((s1.Position == s1.Length)) {
  503. return type;
  504. }
  505. }
  506. }
  507. }
  508. finally {
  509. if ((s1 != null)) {
  510. s1.Close();
  511. }
  512. if ((s2 != null)) {
  513. s2.Close();
  514. }
  515. }
  516. }
  517. xs.Add(dsSchema);
  518. return type;
  519. }
  520. }
  521. /// <summary>
  522. ///Represents strongly named DataRow class.
  523. ///</summary>
  524. public partial class FurnituraRow : global::System.Data.DataRow {
  525. private FurnituraDataTable tableFurnitura;
  526. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  527. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  528. internal FurnituraRow(global::System.Data.DataRowBuilder rb) :
  529. base(rb) {
  530. this.tableFurnitura = ((FurnituraDataTable)(this.Table));
  531. }
  532. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  533. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  534. public int idfur {
  535. get {
  536. return ((int)(this[this.tableFurnitura.idfurColumn]));
  537. }
  538. set {
  539. this[this.tableFurnitura.idfurColumn] = value;
  540. }
  541. }
  542. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  543. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  544. public string namefur {
  545. get {
  546. try {
  547. return ((string)(this[this.tableFurnitura.namefurColumn]));
  548. }
  549. catch (global::System.InvalidCastException e) {
  550. throw new global::System.Data.StrongTypingException("The value for column \'namefur\' in table \'Furnitura\' is DBNull.", e);
  551. }
  552. }
  553. set {
  554. this[this.tableFurnitura.namefurColumn] = value;
  555. }
  556. }
  557. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  558. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  559. public string photo {
  560. get {
  561. try {
  562. return ((string)(this[this.tableFurnitura.photoColumn]));
  563. }
  564. catch (global::System.InvalidCastException e) {
  565. throw new global::System.Data.StrongTypingException("The value for column \'photo\' in table \'Furnitura\' is DBNull.", e);
  566. }
  567. }
  568. set {
  569. this[this.tableFurnitura.photoColumn] = value;
  570. }
  571. }
  572. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  573. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  574. public int countfur {
  575. get {
  576. try {
  577. return ((int)(this[this.tableFurnitura.countfurColumn]));
  578. }
  579. catch (global::System.InvalidCastException e) {
  580. throw new global::System.Data.StrongTypingException("The value for column \'countfur\' in table \'Furnitura\' is DBNull.", e);
  581. }
  582. }
  583. set {
  584. this[this.tableFurnitura.countfurColumn] = value;
  585. }
  586. }
  587. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  588. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  589. public bool IsnamefurNull() {
  590. return this.IsNull(this.tableFurnitura.namefurColumn);
  591. }
  592. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  593. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  594. public void SetnamefurNull() {
  595. this[this.tableFurnitura.namefurColumn] = global::System.Convert.DBNull;
  596. }
  597. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  598. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  599. public bool IsphotoNull() {
  600. return this.IsNull(this.tableFurnitura.photoColumn);
  601. }
  602. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  603. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  604. public void SetphotoNull() {
  605. this[this.tableFurnitura.photoColumn] = global::System.Convert.DBNull;
  606. }
  607. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  608. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  609. public bool IscountfurNull() {
  610. return this.IsNull(this.tableFurnitura.countfurColumn);
  611. }
  612. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  613. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  614. public void SetcountfurNull() {
  615. this[this.tableFurnitura.countfurColumn] = global::System.Convert.DBNull;
  616. }
  617. }
  618. /// <summary>
  619. ///Row event argument class
  620. ///</summary>
  621. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  622. public class FurnituraRowChangeEvent : global::System.EventArgs {
  623. private FurnituraRow eventRow;
  624. private global::System.Data.DataRowAction eventAction;
  625. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  626. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  627. public FurnituraRowChangeEvent(FurnituraRow row, global::System.Data.DataRowAction action) {
  628. this.eventRow = row;
  629. this.eventAction = action;
  630. }
  631. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  632. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  633. public FurnituraRow Row {
  634. get {
  635. return this.eventRow;
  636. }
  637. }
  638. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  639. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  640. public global::System.Data.DataRowAction Action {
  641. get {
  642. return this.eventAction;
  643. }
  644. }
  645. }
  646. }
  647. }
  648. namespace Пример_плиточного_интерфейса.fab2022DataSetTableAdapters {
  649. /// <summary>
  650. ///Represents the connection and commands used to retrieve and save data.
  651. ///</summary>
  652. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  653. [global::System.ComponentModel.ToolboxItem(true)]
  654. [global::System.ComponentModel.DataObjectAttribute(true)]
  655. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
  656. ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  657. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  658. public partial class FurnituraTableAdapter : global::System.ComponentModel.Component {
  659. private global::System.Data.SqlClient.SqlDataAdapter _adapter;
  660. private global::System.Data.SqlClient.SqlConnection _connection;
  661. private global::System.Data.SqlClient.SqlTransaction _transaction;
  662. private global::System.Data.SqlClient.SqlCommand[] _commandCollection;
  663. private bool _clearBeforeFill;
  664. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  665. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  666. public FurnituraTableAdapter() {
  667. this.ClearBeforeFill = true;
  668. }
  669. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  670. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  671. protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter {
  672. get {
  673. if ((this._adapter == null)) {
  674. this.InitAdapter();
  675. }
  676. return this._adapter;
  677. }
  678. }
  679. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  680. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  681. internal global::System.Data.SqlClient.SqlConnection Connection {
  682. get {
  683. if ((this._connection == null)) {
  684. this.InitConnection();
  685. }
  686. return this._connection;
  687. }
  688. set {
  689. this._connection = value;
  690. if ((this.Adapter.InsertCommand != null)) {
  691. this.Adapter.InsertCommand.Connection = value;
  692. }
  693. if ((this.Adapter.DeleteCommand != null)) {
  694. this.Adapter.DeleteCommand.Connection = value;
  695. }
  696. if ((this.Adapter.UpdateCommand != null)) {
  697. this.Adapter.UpdateCommand.Connection = value;
  698. }
  699. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  700. if ((this.CommandCollection[i] != null)) {
  701. ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value;
  702. }
  703. }
  704. }
  705. }
  706. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  707. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  708. internal global::System.Data.SqlClient.SqlTransaction Transaction {
  709. get {
  710. return this._transaction;
  711. }
  712. set {
  713. this._transaction = value;
  714. for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
  715. this.CommandCollection[i].Transaction = this._transaction;
  716. }
  717. if (((this.Adapter != null)
  718. && (this.Adapter.DeleteCommand != null))) {
  719. this.Adapter.DeleteCommand.Transaction = this._transaction;
  720. }
  721. if (((this.Adapter != null)
  722. && (this.Adapter.InsertCommand != null))) {
  723. this.Adapter.InsertCommand.Transaction = this._transaction;
  724. }
  725. if (((this.Adapter != null)
  726. && (this.Adapter.UpdateCommand != null))) {
  727. this.Adapter.UpdateCommand.Transaction = this._transaction;
  728. }
  729. }
  730. }
  731. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  732. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  733. protected global::System.Data.SqlClient.SqlCommand[] CommandCollection {
  734. get {
  735. if ((this._commandCollection == null)) {
  736. this.InitCommandCollection();
  737. }
  738. return this._commandCollection;
  739. }
  740. }
  741. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  742. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  743. public bool ClearBeforeFill {
  744. get {
  745. return this._clearBeforeFill;
  746. }
  747. set {
  748. this._clearBeforeFill = value;
  749. }
  750. }
  751. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  752. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  753. private void InitAdapter() {
  754. this._adapter = new global::System.Data.SqlClient.SqlDataAdapter();
  755. global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
  756. tableMapping.SourceTable = "Table";
  757. tableMapping.DataSetTable = "Furnitura";
  758. tableMapping.ColumnMappings.Add("idfur", "idfur");
  759. tableMapping.ColumnMappings.Add("namefur", "namefur");
  760. tableMapping.ColumnMappings.Add("photo", "photo");
  761. tableMapping.ColumnMappings.Add("countfur", "countfur");
  762. this._adapter.TableMappings.Add(tableMapping);
  763. this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand();
  764. this._adapter.DeleteCommand.Connection = this.Connection;
  765. this._adapter.DeleteCommand.CommandText = @"DELETE FROM [dbo].[Furnitura] WHERE (([idfur] = @Original_idfur) AND ((@IsNull_namefur = 1 AND [namefur] IS NULL) OR ([namefur] = @Original_namefur)) AND ((@IsNull_photo = 1 AND [photo] IS NULL) OR ([photo] = @Original_photo)) AND ((@IsNull_countfur = 1 AND [countfur] IS NULL) OR ([countfur] = @Original_countfur)))";
  766. this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
  767. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idfur", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  768. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_namefur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "namefur", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  769. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_namefur", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "namefur", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  770. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_photo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  771. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_photo", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  772. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_countfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "countfur", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  773. this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_countfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "countfur", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  774. this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand();
  775. this._adapter.InsertCommand.Connection = this.Connection;
  776. this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[Furnitura] ([namefur], [photo], [countfur]) VALUES (@namefur, " +
  777. "@photo, @countfur);\r\nSELECT idfur, namefur, photo, countfur FROM Furnitura WHERE" +
  778. " (idfur = SCOPE_IDENTITY())";
  779. this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
  780. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@namefur", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "namefur", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  781. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@photo", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  782. this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@countfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "countfur", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  783. this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand();
  784. this._adapter.UpdateCommand.Connection = this.Connection;
  785. this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[Furnitura] SET [namefur] = @namefur, [photo] = @photo, [countfur] = @countfur WHERE (([idfur] = @Original_idfur) AND ((@IsNull_namefur = 1 AND [namefur] IS NULL) OR ([namefur] = @Original_namefur)) AND ((@IsNull_photo = 1 AND [photo] IS NULL) OR ([photo] = @Original_photo)) AND ((@IsNull_countfur = 1 AND [countfur] IS NULL) OR ([countfur] = @Original_countfur)));
  786. SELECT idfur, namefur, photo, countfur FROM Furnitura WHERE (idfur = @idfur)";
  787. this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
  788. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@namefur", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "namefur", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  789. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@photo", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  790. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@countfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "countfur", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  791. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idfur", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  792. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_namefur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "namefur", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  793. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_namefur", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "namefur", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  794. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_photo", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  795. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_photo", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "photo", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  796. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_countfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "countfur", global::System.Data.DataRowVersion.Original, true, null, "", "", ""));
  797. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_countfur", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "countfur", global::System.Data.DataRowVersion.Original, false, null, "", "", ""));
  798. this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idfur", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idfur", global::System.Data.DataRowVersion.Current, false, null, "", "", ""));
  799. }
  800. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  801. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  802. private void InitConnection() {
  803. this._connection = new global::System.Data.SqlClient.SqlConnection();
  804. this._connection.ConnectionString = global::Пример_плиточного_интерфейса.Properties.Settings.Default.fab2022ConnectionString;
  805. }
  806. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  807. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  808. private void InitCommandCollection() {
  809. this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1];
  810. this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand();
  811. this._commandCollection[0].Connection = this.Connection;
  812. this._commandCollection[0].CommandText = "SELECT idfur, namefur, photo, countfur FROM dbo.Furnitura";
  813. this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
  814. }
  815. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  816. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  817. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  818. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
  819. public virtual int Fill(fab2022DataSet.FurnituraDataTable dataTable) {
  820. this.Adapter.SelectCommand = this.CommandCollection[0];
  821. if ((this.ClearBeforeFill == true)) {
  822. dataTable.Clear();
  823. }
  824. int returnValue = this.Adapter.Fill(dataTable);
  825. return returnValue;
  826. }
  827. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  828. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  829. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  830. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
  831. public virtual fab2022DataSet.FurnituraDataTable GetData() {
  832. this.Adapter.SelectCommand = this.CommandCollection[0];
  833. fab2022DataSet.FurnituraDataTable dataTable = new fab2022DataSet.FurnituraDataTable();
  834. this.Adapter.Fill(dataTable);
  835. return dataTable;
  836. }
  837. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  838. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  839. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  840. public virtual int Update(fab2022DataSet.FurnituraDataTable dataTable) {
  841. return this.Adapter.Update(dataTable);
  842. }
  843. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  844. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  845. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  846. public virtual int Update(fab2022DataSet dataSet) {
  847. return this.Adapter.Update(dataSet, "Furnitura");
  848. }
  849. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  850. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  851. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  852. public virtual int Update(global::System.Data.DataRow dataRow) {
  853. return this.Adapter.Update(new global::System.Data.DataRow[] {
  854. dataRow});
  855. }
  856. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  857. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  858. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  859. public virtual int Update(global::System.Data.DataRow[] dataRows) {
  860. return this.Adapter.Update(dataRows);
  861. }
  862. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  863. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  864. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  865. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
  866. public virtual int Delete(int Original_idfur, string Original_namefur, string Original_photo, global::System.Nullable<int> Original_countfur) {
  867. this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_idfur));
  868. if ((Original_namefur == null)) {
  869. this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(1));
  870. this.Adapter.DeleteCommand.Parameters[2].Value = global::System.DBNull.Value;
  871. }
  872. else {
  873. this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
  874. this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_namefur));
  875. }
  876. if ((Original_photo == null)) {
  877. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
  878. this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
  879. }
  880. else {
  881. this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
  882. this.Adapter.DeleteCommand.Parameters[4].Value = ((string)(Original_photo));
  883. }
  884. if ((Original_countfur.HasValue == true)) {
  885. this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
  886. this.Adapter.DeleteCommand.Parameters[6].Value = ((int)(Original_countfur.Value));
  887. }
  888. else {
  889. this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
  890. this.Adapter.DeleteCommand.Parameters[6].Value = global::System.DBNull.Value;
  891. }
  892. global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
  893. if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
  894. != global::System.Data.ConnectionState.Open)) {
  895. this.Adapter.DeleteCommand.Connection.Open();
  896. }
  897. try {
  898. int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
  899. return returnValue;
  900. }
  901. finally {
  902. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  903. this.Adapter.DeleteCommand.Connection.Close();
  904. }
  905. }
  906. }
  907. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  908. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  909. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  910. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
  911. public virtual int Insert(string namefur, string photo, global::System.Nullable<int> countfur) {
  912. if ((namefur == null)) {
  913. this.Adapter.InsertCommand.Parameters[0].Value = global::System.DBNull.Value;
  914. }
  915. else {
  916. this.Adapter.InsertCommand.Parameters[0].Value = ((string)(namefur));
  917. }
  918. if ((photo == null)) {
  919. this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value;
  920. }
  921. else {
  922. this.Adapter.InsertCommand.Parameters[1].Value = ((string)(photo));
  923. }
  924. if ((countfur.HasValue == true)) {
  925. this.Adapter.InsertCommand.Parameters[2].Value = ((int)(countfur.Value));
  926. }
  927. else {
  928. this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
  929. }
  930. global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
  931. if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
  932. != global::System.Data.ConnectionState.Open)) {
  933. this.Adapter.InsertCommand.Connection.Open();
  934. }
  935. try {
  936. int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
  937. return returnValue;
  938. }
  939. finally {
  940. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  941. this.Adapter.InsertCommand.Connection.Close();
  942. }
  943. }
  944. }
  945. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  946. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  947. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  948. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  949. public virtual int Update(string namefur, string photo, global::System.Nullable<int> countfur, int Original_idfur, string Original_namefur, string Original_photo, global::System.Nullable<int> Original_countfur, int idfur) {
  950. if ((namefur == null)) {
  951. this.Adapter.UpdateCommand.Parameters[0].Value = global::System.DBNull.Value;
  952. }
  953. else {
  954. this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(namefur));
  955. }
  956. if ((photo == null)) {
  957. this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value;
  958. }
  959. else {
  960. this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(photo));
  961. }
  962. if ((countfur.HasValue == true)) {
  963. this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(countfur.Value));
  964. }
  965. else {
  966. this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
  967. }
  968. this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_idfur));
  969. if ((Original_namefur == null)) {
  970. this.Adapter.UpdateCommand.Parameters[4].Value = ((object)(1));
  971. this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
  972. }
  973. else {
  974. this.Adapter.UpdateCommand.Parameters[4].Value = ((object)(0));
  975. this.Adapter.UpdateCommand.Parameters[5].Value = ((string)(Original_namefur));
  976. }
  977. if ((Original_photo == null)) {
  978. this.Adapter.UpdateCommand.Parameters[6].Value = ((object)(1));
  979. this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
  980. }
  981. else {
  982. this.Adapter.UpdateCommand.Parameters[6].Value = ((object)(0));
  983. this.Adapter.UpdateCommand.Parameters[7].Value = ((string)(Original_photo));
  984. }
  985. if ((Original_countfur.HasValue == true)) {
  986. this.Adapter.UpdateCommand.Parameters[8].Value = ((object)(0));
  987. this.Adapter.UpdateCommand.Parameters[9].Value = ((int)(Original_countfur.Value));
  988. }
  989. else {
  990. this.Adapter.UpdateCommand.Parameters[8].Value = ((object)(1));
  991. this.Adapter.UpdateCommand.Parameters[9].Value = global::System.DBNull.Value;
  992. }
  993. this.Adapter.UpdateCommand.Parameters[10].Value = ((int)(idfur));
  994. global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
  995. if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
  996. != global::System.Data.ConnectionState.Open)) {
  997. this.Adapter.UpdateCommand.Connection.Open();
  998. }
  999. try {
  1000. int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
  1001. return returnValue;
  1002. }
  1003. finally {
  1004. if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
  1005. this.Adapter.UpdateCommand.Connection.Close();
  1006. }
  1007. }
  1008. }
  1009. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1010. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1011. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
  1012. [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
  1013. public virtual int Update(string namefur, string photo, global::System.Nullable<int> countfur, int Original_idfur, string Original_namefur, string Original_photo, global::System.Nullable<int> Original_countfur) {
  1014. return this.Update(namefur, photo, countfur, Original_idfur, Original_namefur, Original_photo, Original_countfur, Original_idfur);
  1015. }
  1016. }
  1017. /// <summary>
  1018. ///TableAdapterManager is used to coordinate TableAdapters in the dataset to enable Hierarchical Update scenarios
  1019. ///</summary>
  1020. [global::System.ComponentModel.DesignerCategoryAttribute("code")]
  1021. [global::System.ComponentModel.ToolboxItem(true)]
  1022. [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerDesigner, Microsoft.VSD" +
  1023. "esigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
  1024. [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapterManager")]
  1025. public partial class TableAdapterManager : global::System.ComponentModel.Component {
  1026. private UpdateOrderOption _updateOrder;
  1027. private FurnituraTableAdapter _furnituraTableAdapter;
  1028. private bool _backupDataSetBeforeUpdate;
  1029. private global::System.Data.IDbConnection _connection;
  1030. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1031. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1032. public UpdateOrderOption UpdateOrder {
  1033. get {
  1034. return this._updateOrder;
  1035. }
  1036. set {
  1037. this._updateOrder = value;
  1038. }
  1039. }
  1040. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1041. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1042. [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
  1043. "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
  1044. "a", "System.Drawing.Design.UITypeEditor")]
  1045. public FurnituraTableAdapter FurnituraTableAdapter {
  1046. get {
  1047. return this._furnituraTableAdapter;
  1048. }
  1049. set {
  1050. this._furnituraTableAdapter = value;
  1051. }
  1052. }
  1053. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1054. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1055. public bool BackupDataSetBeforeUpdate {
  1056. get {
  1057. return this._backupDataSetBeforeUpdate;
  1058. }
  1059. set {
  1060. this._backupDataSetBeforeUpdate = value;
  1061. }
  1062. }
  1063. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1064. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1065. [global::System.ComponentModel.Browsable(false)]
  1066. public global::System.Data.IDbConnection Connection {
  1067. get {
  1068. if ((this._connection != null)) {
  1069. return this._connection;
  1070. }
  1071. if (((this._furnituraTableAdapter != null)
  1072. && (this._furnituraTableAdapter.Connection != null))) {
  1073. return this._furnituraTableAdapter.Connection;
  1074. }
  1075. return null;
  1076. }
  1077. set {
  1078. this._connection = value;
  1079. }
  1080. }
  1081. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1082. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1083. [global::System.ComponentModel.Browsable(false)]
  1084. public int TableAdapterInstanceCount {
  1085. get {
  1086. int count = 0;
  1087. if ((this._furnituraTableAdapter != null)) {
  1088. count = (count + 1);
  1089. }
  1090. return count;
  1091. }
  1092. }
  1093. /// <summary>
  1094. ///Update rows in top-down order.
  1095. ///</summary>
  1096. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1097. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1098. private int UpdateUpdatedRows(fab2022DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  1099. int result = 0;
  1100. if ((this._furnituraTableAdapter != null)) {
  1101. global::System.Data.DataRow[] updatedRows = dataSet.Furnitura.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
  1102. updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
  1103. if (((updatedRows != null)
  1104. && (0 < updatedRows.Length))) {
  1105. result = (result + this._furnituraTableAdapter.Update(updatedRows));
  1106. allChangedRows.AddRange(updatedRows);
  1107. }
  1108. }
  1109. return result;
  1110. }
  1111. /// <summary>
  1112. ///Insert rows in top-down order.
  1113. ///</summary>
  1114. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1115. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1116. private int UpdateInsertedRows(fab2022DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  1117. int result = 0;
  1118. if ((this._furnituraTableAdapter != null)) {
  1119. global::System.Data.DataRow[] addedRows = dataSet.Furnitura.Select(null, null, global::System.Data.DataViewRowState.Added);
  1120. if (((addedRows != null)
  1121. && (0 < addedRows.Length))) {
  1122. result = (result + this._furnituraTableAdapter.Update(addedRows));
  1123. allAddedRows.AddRange(addedRows);
  1124. }
  1125. }
  1126. return result;
  1127. }
  1128. /// <summary>
  1129. ///Delete rows in bottom-up order.
  1130. ///</summary>
  1131. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1132. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1133. private int UpdateDeletedRows(fab2022DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows) {
  1134. int result = 0;
  1135. if ((this._furnituraTableAdapter != null)) {
  1136. global::System.Data.DataRow[] deletedRows = dataSet.Furnitura.Select(null, null, global::System.Data.DataViewRowState.Deleted);
  1137. if (((deletedRows != null)
  1138. && (0 < deletedRows.Length))) {
  1139. result = (result + this._furnituraTableAdapter.Update(deletedRows));
  1140. allChangedRows.AddRange(deletedRows);
  1141. }
  1142. }
  1143. return result;
  1144. }
  1145. /// <summary>
  1146. ///Remove inserted rows that become updated rows after calling TableAdapter.Update(inserted rows) first
  1147. ///</summary>
  1148. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1149. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1150. private global::System.Data.DataRow[] GetRealUpdatedRows(global::System.Data.DataRow[] updatedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
  1151. if (((updatedRows == null)
  1152. || (updatedRows.Length < 1))) {
  1153. return updatedRows;
  1154. }
  1155. if (((allAddedRows == null)
  1156. || (allAddedRows.Count < 1))) {
  1157. return updatedRows;
  1158. }
  1159. global::System.Collections.Generic.List<global::System.Data.DataRow> realUpdatedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  1160. for (int i = 0; (i < updatedRows.Length); i = (i + 1)) {
  1161. global::System.Data.DataRow row = updatedRows[i];
  1162. if ((allAddedRows.Contains(row) == false)) {
  1163. realUpdatedRows.Add(row);
  1164. }
  1165. }
  1166. return realUpdatedRows.ToArray();
  1167. }
  1168. /// <summary>
  1169. ///Update all changes to the dataset.
  1170. ///</summary>
  1171. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1172. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1173. public virtual int UpdateAll(fab2022DataSet dataSet) {
  1174. if ((dataSet == null)) {
  1175. throw new global::System.ArgumentNullException("dataSet");
  1176. }
  1177. if ((dataSet.HasChanges() == false)) {
  1178. return 0;
  1179. }
  1180. if (((this._furnituraTableAdapter != null)
  1181. && (this.MatchTableAdapterConnection(this._furnituraTableAdapter.Connection) == false))) {
  1182. throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" +
  1183. "tring.");
  1184. }
  1185. global::System.Data.IDbConnection workConnection = this.Connection;
  1186. if ((workConnection == null)) {
  1187. throw new global::System.ApplicationException("TableAdapterManager contains no connection information. Set each TableAdapterMana" +
  1188. "ger TableAdapter property to a valid TableAdapter instance.");
  1189. }
  1190. bool workConnOpened = false;
  1191. if (((workConnection.State & global::System.Data.ConnectionState.Broken)
  1192. == global::System.Data.ConnectionState.Broken)) {
  1193. workConnection.Close();
  1194. }
  1195. if ((workConnection.State == global::System.Data.ConnectionState.Closed)) {
  1196. workConnection.Open();
  1197. workConnOpened = true;
  1198. }
  1199. global::System.Data.IDbTransaction workTransaction = workConnection.BeginTransaction();
  1200. if ((workTransaction == null)) {
  1201. throw new global::System.ApplicationException("The transaction cannot begin. The current data connection does not support transa" +
  1202. "ctions or the current state is not allowing the transaction to begin.");
  1203. }
  1204. global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  1205. global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
  1206. global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter> adaptersWithAcceptChangesDuringUpdate = new global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter>();
  1207. global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection> revertConnections = new global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection>();
  1208. int result = 0;
  1209. global::System.Data.DataSet backupDataSet = null;
  1210. if (this.BackupDataSetBeforeUpdate) {
  1211. backupDataSet = new global::System.Data.DataSet();
  1212. backupDataSet.Merge(dataSet);
  1213. }
  1214. try {
  1215. // ---- Prepare for update -----------
  1216. //
  1217. if ((this._furnituraTableAdapter != null)) {
  1218. revertConnections.Add(this._furnituraTableAdapter, this._furnituraTableAdapter.Connection);
  1219. this._furnituraTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection));
  1220. this._furnituraTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction));
  1221. if (this._furnituraTableAdapter.Adapter.AcceptChangesDuringUpdate) {
  1222. this._furnituraTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
  1223. adaptersWithAcceptChangesDuringUpdate.Add(this._furnituraTableAdapter.Adapter);
  1224. }
  1225. }
  1226. //
  1227. //---- Perform updates -----------
  1228. //
  1229. if ((this.UpdateOrder == UpdateOrderOption.UpdateInsertDelete)) {
  1230. result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
  1231. result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
  1232. }
  1233. else {
  1234. result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
  1235. result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
  1236. }
  1237. result = (result + this.UpdateDeletedRows(dataSet, allChangedRows));
  1238. //
  1239. //---- Commit updates -----------
  1240. //
  1241. workTransaction.Commit();
  1242. if ((0 < allAddedRows.Count)) {
  1243. global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
  1244. allAddedRows.CopyTo(rows);
  1245. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  1246. global::System.Data.DataRow row = rows[i];
  1247. row.AcceptChanges();
  1248. }
  1249. }
  1250. if ((0 < allChangedRows.Count)) {
  1251. global::System.Data.DataRow[] rows = new System.Data.DataRow[allChangedRows.Count];
  1252. allChangedRows.CopyTo(rows);
  1253. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  1254. global::System.Data.DataRow row = rows[i];
  1255. row.AcceptChanges();
  1256. }
  1257. }
  1258. }
  1259. catch (global::System.Exception ex) {
  1260. workTransaction.Rollback();
  1261. // ---- Restore the dataset -----------
  1262. if (this.BackupDataSetBeforeUpdate) {
  1263. global::System.Diagnostics.Debug.Assert((backupDataSet != null));
  1264. dataSet.Clear();
  1265. dataSet.Merge(backupDataSet);
  1266. }
  1267. else {
  1268. if ((0 < allAddedRows.Count)) {
  1269. global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
  1270. allAddedRows.CopyTo(rows);
  1271. for (int i = 0; (i < rows.Length); i = (i + 1)) {
  1272. global::System.Data.DataRow row = rows[i];
  1273. row.AcceptChanges();
  1274. row.SetAdded();
  1275. }
  1276. }
  1277. }
  1278. throw ex;
  1279. }
  1280. finally {
  1281. if (workConnOpened) {
  1282. workConnection.Close();
  1283. }
  1284. if ((this._furnituraTableAdapter != null)) {
  1285. this._furnituraTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._furnituraTableAdapter]));
  1286. this._furnituraTableAdapter.Transaction = null;
  1287. }
  1288. if ((0 < adaptersWithAcceptChangesDuringUpdate.Count)) {
  1289. global::System.Data.Common.DataAdapter[] adapters = new System.Data.Common.DataAdapter[adaptersWithAcceptChangesDuringUpdate.Count];
  1290. adaptersWithAcceptChangesDuringUpdate.CopyTo(adapters);
  1291. for (int i = 0; (i < adapters.Length); i = (i + 1)) {
  1292. global::System.Data.Common.DataAdapter adapter = adapters[i];
  1293. adapter.AcceptChangesDuringUpdate = true;
  1294. }
  1295. }
  1296. }
  1297. return result;
  1298. }
  1299. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1300. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1301. protected virtual void SortSelfReferenceRows(global::System.Data.DataRow[] rows, global::System.Data.DataRelation relation, bool childFirst) {
  1302. global::System.Array.Sort<global::System.Data.DataRow>(rows, new SelfReferenceComparer(relation, childFirst));
  1303. }
  1304. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1305. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1306. protected virtual bool MatchTableAdapterConnection(global::System.Data.IDbConnection inputConnection) {
  1307. if ((this._connection != null)) {
  1308. return true;
  1309. }
  1310. if (((this.Connection == null)
  1311. || (inputConnection == null))) {
  1312. return true;
  1313. }
  1314. if (string.Equals(this.Connection.ConnectionString, inputConnection.ConnectionString, global::System.StringComparison.Ordinal)) {
  1315. return true;
  1316. }
  1317. return false;
  1318. }
  1319. /// <summary>
  1320. ///Update Order Option
  1321. ///</summary>
  1322. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1323. public enum UpdateOrderOption {
  1324. InsertUpdateDelete = 0,
  1325. UpdateInsertDelete = 1,
  1326. }
  1327. /// <summary>
  1328. ///Used to sort self-referenced table's rows
  1329. ///</summary>
  1330. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1331. private class SelfReferenceComparer : object, global::System.Collections.Generic.IComparer<global::System.Data.DataRow> {
  1332. private global::System.Data.DataRelation _relation;
  1333. private int _childFirst;
  1334. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1335. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1336. internal SelfReferenceComparer(global::System.Data.DataRelation relation, bool childFirst) {
  1337. this._relation = relation;
  1338. if (childFirst) {
  1339. this._childFirst = -1;
  1340. }
  1341. else {
  1342. this._childFirst = 1;
  1343. }
  1344. }
  1345. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1346. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1347. private global::System.Data.DataRow GetRoot(global::System.Data.DataRow row, out int distance) {
  1348. global::System.Diagnostics.Debug.Assert((row != null));
  1349. global::System.Data.DataRow root = row;
  1350. distance = 0;
  1351. global::System.Collections.Generic.IDictionary<global::System.Data.DataRow, global::System.Data.DataRow> traversedRows = new global::System.Collections.Generic.Dictionary<global::System.Data.DataRow, global::System.Data.DataRow>();
  1352. traversedRows[row] = row;
  1353. global::System.Data.DataRow parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
  1354. for (
  1355. ; ((parent != null)
  1356. && (traversedRows.ContainsKey(parent) == false));
  1357. ) {
  1358. distance = (distance + 1);
  1359. root = parent;
  1360. traversedRows[parent] = parent;
  1361. parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
  1362. }
  1363. if ((distance == 0)) {
  1364. traversedRows.Clear();
  1365. traversedRows[row] = row;
  1366. parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
  1367. for (
  1368. ; ((parent != null)
  1369. && (traversedRows.ContainsKey(parent) == false));
  1370. ) {
  1371. distance = (distance + 1);
  1372. root = parent;
  1373. traversedRows[parent] = parent;
  1374. parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
  1375. }
  1376. }
  1377. return root;
  1378. }
  1379. [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
  1380. [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "17.0.0.0")]
  1381. public int Compare(global::System.Data.DataRow row1, global::System.Data.DataRow row2) {
  1382. if (object.ReferenceEquals(row1, row2)) {
  1383. return 0;
  1384. }
  1385. if ((row1 == null)) {
  1386. return -1;
  1387. }
  1388. if ((row2 == null)) {
  1389. return 1;
  1390. }
  1391. int distance1 = 0;
  1392. global::System.Data.DataRow root1 = this.GetRoot(row1, out distance1);
  1393. int distance2 = 0;
  1394. global::System.Data.DataRow root2 = this.GetRoot(row2, out distance2);
  1395. if (object.ReferenceEquals(root1, root2)) {
  1396. return (this._childFirst * distance1.CompareTo(distance2));
  1397. }
  1398. else {
  1399. global::System.Diagnostics.Debug.Assert(((root1.Table != null)
  1400. && (root2.Table != null)));
  1401. if ((root1.Table.Rows.IndexOf(root1) < root2.Table.Rows.IndexOf(root2))) {
  1402. return -1;
  1403. }
  1404. else {
  1405. return 1;
  1406. }
  1407. }
  1408. }
  1409. }
  1410. }
  1411. }
  1412. #pragma warning restore 1591