@@ -912,12 +912,15 @@ private bool ProgNoServer()
912912 {
913913 string swtype = "3" ;
914914 string swver = string . Empty ;
915+ string PK_Hash = "????????" ;
915916 if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "SWType" , i ] . Value . ToString ( ) ) ) swtype = dataGridView_FInd_Server [ "SWType" , i ] . Value . ToString ( ) ;
916- if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "SWVer" , i ] . Value . ToString ( ) ) ) swver = "(" + dataGridView_FInd_Server [ "SWVer" , i ] . Value . ToString ( ) + ")" ;
917- string somerec = string . Format ( "{0}-{1}-{2}-{3}-{4}" , dataGridView_FInd_Server [ "HW_FH" , i ] . Value . ToString ( ) ,
917+ if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "SWVer" , i ] . Value . ToString ( ) ) ) swver = string . Format ( "({0})" , dataGridView_FInd_Server [ "SWVer" , i ] . Value . ToString ( ) ) ;
918+ if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) ) ) PK_Hash = dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) . Substring ( dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) . Length - 8 ) ;
919+ string somerec = string . Format ( "{0}-{1}-{2}-{3}-{4}" ,
920+ dataGridView_FInd_Server [ "HW_FH" , i ] . Value . ToString ( ) ,
918921 dataGridView_FInd_Server [ "OEM_FH" , i ] . Value . ToString ( ) ,
919922 dataGridView_FInd_Server [ "MODEL_FH" , i ] . Value . ToString ( ) ,
920- dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) . Substring ( dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) . Length - 8 ) ,
923+ PK_Hash ,
921924 swtype + swver ) ;
922925 serverprogs . Add ( somerec ) ;
923926 }
@@ -1662,7 +1665,7 @@ private void Button_path_Click(object sender, EventArgs e)
16621665 {
16631666 string swtype = "3" ;
16641667 string swver = string . Empty ;
1665- string nozero_hash = string . Empty ;
1668+ string nozero_hash = "????????" ;
16661669 if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "SWType" , i ] . Value . ToString ( ) ) ) swtype = dataGridView_FInd_Server [ "SWType" , i ] . Value . ToString ( ) ;
16671670 if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "SWVer" , i ] . Value . ToString ( ) ) ) swver = "(" + dataGridView_FInd_Server [ "SWVer" , i ] . Value . ToString ( ) + ")" ;
16681671 if ( ! string . IsNullOrEmpty ( dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) ) && dataGridView_FInd_Server [ "HASH_FH" , i ] . Value . ToString ( ) . Length >= 8 )
@@ -2173,9 +2176,8 @@ private byte Rating(string[] id_str, int Currnum)
21732176 {
21742177 byte gross = 0 ; //Рейтинг файла
21752178 string sw_type = string . Empty ;
2176- string oemhash ;
2177- if ( id_str [ 3 ] . Length < 8 ) oemhash = id_str [ 3 ] ;
2178- else oemhash = id_str [ 3 ] . Substring ( id_str [ 3 ] . Length - 8 ) ;
2179+ string oemhash = "????????" ;
2180+ if ( id_str [ 3 ] . Length >= 8 ) oemhash = id_str [ 3 ] . Substring ( id_str [ 3 ] . Length - 8 ) ;
21792181 dataGridView_final [ "Column_id" , Currnum ] . Value = id_str [ 0 ] + '\u002D ' + id_str [ 1 ] + '\u002D ' + id_str [ 2 ] + '\u002D ' + oemhash + '\u002D ' + id_str [ 4 ] + id_str [ 5 ] ;
21802182 if ( guide . SW_ID_type . ContainsKey ( id_str [ 4 ] ) ) sw_type = guide . SW_ID_type [ id_str [ 4 ] ] ;
21812183 dataGridView_final [ "Column_SW_type" , Currnum ] . Value = sw_type ;
@@ -3363,7 +3365,11 @@ private async void ОтправкаПрограммераToolStripMenuItem_Click
33633365 $ "[{ Settings . Default . userFN } { Settings . Default . userLN } ({ Settings . Default . userN } )](tg://user?id={ Settings . Default . userID } )" + '\u0020 ' +
33643366 LocRes . GetString ( "thanks_u_data" ) + '\u0020 ' +
33653367 LocRes . GetString ( "increase_rating" ) ;
3366- await Guide . _botClient . SendDocumentAsync ( guide . channel , onlineFile , null , null , mess_to_post , Telegram . Bot . Types . Enums . ParseMode . Markdown ) ;
3368+ await Guide . _botClient . SendDocument (
3369+ chatId : guide . channel ,
3370+ onlineFile ,
3371+ caption : mess_to_post ,
3372+ parseMode : Telegram . Bot . Types . Enums . ParseMode . Markdown ) ;
33673373 textBox_soft_term . AppendText ( LocRes . GetString ( "sent" ) + Environment . NewLine ) ;
33683374 }
33693375 catch ( Exception ex )
0 commit comments