question

Daredavil-7016 avatar image
0 Votes"
Daredavil-7016 asked XuDongPeng-MSFT commented

Simple automation in C# web appliction

Hello, could somebody help us in following:

1) There is an WEB application in which via Search text box, we filter unique codes in column (ColumnName) in a form e.g., 12345

2) Upon having displayed found row of data from the database:

3) We must select that filtered row of data by checking check box

4) Final step is to click button which calls certain procedure (Get Largest number in column "Column Name ORDER")

Namely, after the first filtered code, we must manually select(via checking check box) filtered row and after that click on button.....that runs function get Largest number. Outcome of this are values in column "Oreder" in format: 1,2,3,4,5,6,etc.....

I.e., like in EXCEL function FILL IN, with step = 1

Please, what would be the way to automate the second and third step in order to avoid them completely i.e.

To manually type unique code in Search box and to have the rest of two steps to be performed automatically, i.e, upon having filtered certain row from database, to have steps SELECT AND PUSH BUTTON EVENT automatically performed.

Because, there are around 1000 different code numbers and, manual actions take too much of time. We need to speed it up......


namespace BallotLottery.UI
{

partial class ShowPartyVuk2010GENTable
: BaseApplicationPage
// Code-behind class for the ShowPartyVuk2010GENTable page.
// Place your customizations in Section 1. Do not modify Section 2.
{



   #region "Section 1: Place your customizations here."

   public ShowPartyVuk2010GENTable()
     {
         this.Initialize();
     }

     public void LoadData()
     {
         // LoadData reads database data and assigns it to UI controls.
         // Customize by adding code before or after the call to LoadData_Base()
         // or replace the call to LoadData_Base().
         LoadData_Base();
            
     }
      
   public override void SaveData()
   {
       this.SaveData_Base();
   }          

region "Ajax Functions"


     [System.Web.Services.WebMethod()]
     public static Object[] GetRecordFieldValue(string tableName , 
                                                 string recordID , 
                                                 string columnName, 
                                                 string title, 
                                                 bool persist, 
                                                 int popupWindowHeight, 
                                                 int popupWindowWidth, 
                                                 bool popupWindowScrollBar)
     {
         // GetRecordFieldValue gets the pop up window content from the column specified by
         // columnName in the record specified by the recordID in data base table specified by tableName.
         // Customize by adding code before or after the call to  GetRecordFieldValue_Base()
         // or replace the call to  GetRecordFieldValue_Base().

         return GetRecordFieldValue_Base(tableName, recordID, columnName, title, persist, popupWindowHeight, popupWindowWidth, popupWindowScrollBar);
     }

     [System.Web.Services.WebMethod()]
     public static object[] GetImage(string tableName,
                                     string recordID, 
                                     string columnName, 
                                     string title, 
                                     bool persist, 
                                     int popupWindowHeight, 
                                     int popupWindowWidth, 
                                     bool popupWindowScrollBar)
     {
         // GetImage gets the Image url for the image in the column "columnName" and
         // in the record specified by recordID in data base table specified by tableName.
         // Customize by adding code before or after the call to  GetImage_Base()
         // or replace the call to  GetImage_Base().
         return GetImage_Base(tableName, recordID, columnName, title, persist, popupWindowHeight, popupWindowWidth, popupWindowScrollBar);
     }
        
    
   protected override void BasePage_PreRender(object sender, EventArgs e)
   {
       base.BasePage_PreRender(sender, e);
       Base_RegisterPostback();
   }
    
      
   #endregion

   // Page Event Handlers - buttons, sort, links
dotnet-csharpdotnet-aspnet-general
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @Daredavil-7016 ,
Regarding the automation of the 3 step you mentioned, it needs to select the filtered records through the checkbox. Do you want to use fixed rules to achieve it? For example, select the first 5 records, or select all records.
If the record to be selected is determined by users, this will not be possible because machines cannot guess human thoughts.

And if you just want to achieve the final requirements, I think you could try to directly sort (order by columnName) the filtered data in the first step. This can also better show the differences between the various records.

0 Votes 0 ·

0 Answers