ContributionsMost RecentMost LikesSolutionsRe: [TechCorner Challenge #12] Compare images using the Region Checkpoint Task: Compare the two images below using TC Region Checkpoint ...and reveal a secret message!Post the message and the script to the comments. This is a solution created for [TechCorner Challenge #12] [DelphiScript] procedure comparingPictures(); begin if Not Regions.img1_png.Check('img2_png') then Log.Message('Differ') end; Project Explorer: Workspace Results Re: [TechCorner Challenge #11] Converting UTC TimeDate in an Excel file Task: Read the UTC DateTime in an Excel file (attached), convert the value for the PST (Pacific StandardTime) time zone and log each date in the following format: <month name> <day of month>, <full weekday name>. For example: September 8, Tuesday. This is a solution created for [TechCorner Challenge #11] Hi sonya_m and SiwarSayahi, I try again. # DelphiScript procedure Challenge_11(); var fileExcel, exSheet, Valx: OleVariant; i: Integer; begin fileExcel := Excel.Open('C:\\Temp\DateTime.xlsx'); exSheet := fileExcel.SheetByTitle['Sheet1']; for i := 1 to exSheet.RowCount do begin Valx := aqDateTime.AddHours(exSheet.Cell('A', i).Value, -8); Log.Message(aqConvert.DateTimeToFormatStr(Valx, '%B %d, %A')); end; end; Re: [TechCorner Challenge #11] Converting UTC TimeDate in an Excel file Hi, thanks sonya_m and SiwarSayahi . I'll hopefully find this week a quite moment where I can fix it. therefore the answer is yes, I am going to improve my script. I wish you a nice working day, E. Re: [TechCorner Challenge #11] Converting UTC TimeDate in an Excel file Hi everyone, Friday aftenoon... a challenging code week just behind... trying to give a quick first attempt. I see that something is not working properly... but now the chief is calling again and again and I have really to go... sorry.. Kind regards E. ______________ procedure Challenge_11(); var fileExcel, exSheet, ValA1, ValA2, ValA3: OleVariant; i: Integer; begin fileExcel := Excel.Open('C:\\Temp\DateTime.xlsx'); exSheet := fileExcel.SheetByTitle['Sheet1']; for i := 1 to exSheet.RowCount do begin Log.Message(aqConvert.DateTimeToFormatStr(aqDateTime.GetMonth(exSheet.Cell('A', i).Value), '%B') + ' ' + IntToStr(aqDateTime.GetDay(exSheet.Cell('A', i).Value)) + ' , ' + aqConvert.DateTimeToFormatStr(aqDateTime.GetDay(exSheet.Cell('A', i).Value), '%A')); end; Re: DelphiScript runtime error on: .GetColumn('name').Index Hi, we are calling exactly the same procedure (as Unit Reference and procedure calling) in another TC-Project (inside it there are other/different Test Items since it is very similar but with some “peculiarities” to check) where but at the end we are testing the same “GR_Mandant” object on which exactly the same action are performed. I just verified if the "GR_Mandant" Grid is focused (as suggested by AlexKaras) and this is the case, it is actually focused. I want check now the context which maybe play a rule in all that issue. Best Regards E.A. Re: DelphiScript runtime error on: .GetColumn('name').Index Hi AlexKaras, thanks for your suggestion; I will try today and then I will replay. Our nightly test on this point shows againthat an Exception raised (now I handled with try-except block and warning message); the point is but that the same function in another project on the same object (see point 3 of my first posting) raised no Exception. The context plays a rule and I have perhaps also to consider/analyse that. Have a nice day and best regards E. Antonini Re: DelphiScript runtime error on: .GetColumn('name').Index Thanks Robert, I'll try with RefreshMapping and then I'll come back. But please consider again the point 3. of my first post, since in another TC-Project, calling the same script on the same object it seems, - I tried/tested it more than one time - not to raise an exception at all. Many thanks again. Regards E.A. Re: DelphiScript runtime error on: .GetColumn('name').Index I attached the same picture, maybe it is now better to see. The error text is: "An Exception occurred: 0xC0000096; class: ; description: ". <So, a copy/paste of your code snippet would be helpful.> -- START SNIPPET procedure einenBeliebigenMandantenLoeschenAberNichtDenDemoDatenMandanten(); var i, mandantenAnzahl, ColumnVerzeichnisIndex: Integer; lVerzeichnis: String; const MAX_ANZAHL_MANDANTEN = 15; begin lVerzeichnis := ProjectSuite.Variables.DemoDatenMandantenPfad; if NOT Aliases.Lohn.FMandantenanlage.Exists then begin Aliases.Lohn.FSMenu.MDIClient.Keys('~fm'); end; Aliases.Lohn.FMandantenanlage.Maximize; Aliases.Lohn.FMandantenanlage.Panel1.NO_1.TS_Mandanten.GR_Mandant.Keys('^[Home]'); mandantenAnzahl := Aliases.Lohn.FMandantenanlage.Panel1.NO_1.TS_Mandanten.GR_Mandant.RowCounter; ColumnVerzeichnisIndex := Aliases.Lohn.FMandantenanlage.Panel1.NO_1.TS_Mandanten.GR_Mandant.GetColumn('Pfad').Index + 1; -- END Thank you. E.A. DelphiScript runtime error on: .GetColumn('name').Index Hi SM-TestComplete Community, First of all, here are some general info: --- TC language: DelphiScript Testcomplete Version: 14.20.2175.7 x64 OS: MS WIN 10 Pro 64-bit The AUT (Desktop) is built in Delphi 7. --- The object UT is a grid (inherited from TCustomGrid) and we want to get the column index like .GetColumn('name').Index + 1. 1. As we run the single script, it doesn't raise any exception, it works well. The single script is of course one of a more complex test project. 2. But when we run the whole project then we got (see attached *.jpg) this DelphiScript runtime error Exception. 3. But this is further to consider: when we call exactly the same script in another TC-project in order to perform the foreseen actions (on the exactly same grid), in this case it doesn't raise any runtime exception. This is the main aspect we wish to clear. The AUT (Desktop) is exactly the same. In the attached file (*.jpg) you can see some more details of the our DelphiScript and runtime error. Many thanks in advance and have a nice day Best regards Antonini E. Solved