Search Posts

Category: c#

Pause and Continue files with Fine Uploader

how to Pause and Continue files with Fine Uploader My configurations. Angular : 1.6, Back end : C#, Fine Uploader 5. my upload is working fine but the new requirement is to upload a whole folder with pause and continue functionality. Initially when folder is dropped, It should be in Pause state, and there must be a upload button for continue. I have tried to complete it with autoUpload: false but it’s also not working. […]

asp.net web api how to create zip file from multiple server files and download the zip file in your machine

how to asp.net web api how to create zip file from multiple server files and download the zip file in your machine I am trying to get multiple files from network and zip into one file and then open a window to allow user to save the zipped file in his/her machine. My current working code zips the files and return it to client in angularJS, but it doesn’t initiate the download. From client I […]

How to click on checkbox which is angular UI Grid based on its row item in selenium C#

I am automating angular application using selenium C#.I am facing an issue with selecting a checkbox based on the row text value.If it is “X” I want to select on the particular checkbox corresponding to that item. I have two seperate lists for the items and the checkboxs.And the checkbox count and items count are not matching because of checkbox itself has sub folders. My Code for Items: List<IWebElement> Down = driver.FindElements(By.XPath(“//div[@class=’ui-grid-cell-contents ng-binding’]”)).ToList(); int numberOfElements […]

Conditionally render an AngularJS template in ASP.NET

I’m using AngularJS on top of ASP.NET with C#. I have several partial AngularJS templates, but not all users should be able to access all templates. My client is using a database table to store the permissions for the different pages. I query the database and place the results of this query in a dynamic object that looks something like this (when serialized to JSON): {“page-one”: {“PageName”: “Page One”, “PageURL”: “page-one.html”, “Authorized”: true}, “page-two”: {“PageName”: […]

Change event fired twice for kendo ui Combobox

I noticed some weird behavior in all comboboxes in my application and after some time I noticed that the Kendo UI ComboBoxes are making or firing the change event two times and so they make two http requests if the code inside has one I searched alot but found nothing to help I use comboboxes with angularjs k-options (for general options) and k-on-change attribute for the change event handler I tried to implement the combo […]

Unable to select all the items in the UI-Grid selenium C#

I am able to select the first checkbox in the UI-Grid and the selecting of all the items at a a time or looping throgh the list is not happnening,But when I debug the code and verified the click works on all the items in the list. IList elements = driver.FindElements( By.XPath(“//div[@ng-click=’selectButtonClick(row, $event)’]”)).ToList(); int numberOfElements=elements.Count(); var wait = new WebDriverWait(driver, TimeSpan.FromSeconds(10)); wait.Until(ExpectedConditions.ElementToBeClickable( By.XPath(“//div[@ng-click=’selectButtonClick(row, $event)’]”))).Click(); for (int i = 0; i < numberOfElements; i++) { elements […]

Dynamic add charts based on a factory pattern

I want to add dynamically charts to a widget from a combobox. I have used the factory pattern to achieve this. This is the code for the backend: public interface ICharts { string chartType (); } public class ChartsFactory { public ICharts GraphType(ChartsType chartype) { switch (chartype) { case ChartsType.AREA: return new Area(); case ChartsType.BAR: return new Bar(); case ChartsType.HORIZONBAR: return new HorizonBar(); case ChartsType.HEATMAP: return new Heatmap(); case ChartsType.PIE: return new Pie(); default: throw […]

Next Page »