Search Results

Search found 4833 results on 194 pages for 'component'.

Page 9/194 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • Detect if Java Swing component has been hidden

    - by kayahr
    Assume we have the following Swing application: final JFrame frame = new JFrame(); final JPanel outer = new JPanel(); frame.add(outer); JComponent inner = new SomeSpecialComponent(); outer.add(inner); So in this example we simply have an outer panel in the frame and a special component in the panel. This special component must do something when it is hidden and shown. But the problem is that setVisible() is called on the outer panel and not on the special component. So I can't override the setVisible method in the special component and I also can't use a component listener on it. I could register the listener on the parent component but what if the outer panel is also in another panel and this outer outer panel is hidden? Is there an easier solution than recursively adding componentlisteners to all parent components to detect a visibility change in SomeSpecialComponent?

    Read the article

  • Render ViewComponent from another component codebehind

    - by George Polevoy
    I'm trying to render a component from withing another component. public override void Render() // ... var block = new Block(); block.Init(EngineContext, Context); block.Render(); // ... } The problem is that Block component can't find it's template. ResourceProcessingException Message: Unable to process resource 'components\CustomReportComponentComponent\default.vm': Resource could not be located I guess, other problems can arise because the component is not properly initialized. Is it possible to initialize a component from within another component's Render method, so it renders just as if called from a .vm?

    Read the article

  • Executing Stored Procedure for each InputRow + SSIS Script Component.

    - by Nev_Rahd
    Hello, In my Script Component, am trying to execute Stored Procedure = which return multiple rows = of which need to generate output rows. Code as below: /* Microsoft SQL Server Integration Services Script Component * Write scripts using Microsoft Visual C# 2008. * ScriptMain is the entry point class of the script.*/ using System; using System.Data; using System.Data.SqlClient; using Microsoft.SqlServer.Dts.Pipeline.Wrapper; using Microsoft.SqlServer.Dts.Runtime.Wrapper; [Microsoft.SqlServer.Dts.Pipeline.SSISScriptComponentEntryPointAttribute] public class ScriptMain : UserComponent { SqlConnection cnn = new SqlConnection(); IDTSConnectionManager100 cnManager; //string cmd; SqlCommand cmd = new SqlCommand(); public override void AcquireConnections(object Transaction) { cnManager = base.Connections.myConnection; cnn = (SqlConnection)cnManager.AcquireConnection(null); } public override void PreExecute() { base.PreExecute(); } public override void PostExecute() { base.PostExecute(); } public override void InputRows_ProcessInputRow(InputRowsBuffer Row) { while(Row.NextRow()) { DataTable dt = new DataTable(); cmd.Connection = cnn; cmd.CommandText = "OSPATTRIBUTE_GetOPNforOP"; cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@NK", SqlDbType.VarChar).Value = Row.OPNK.ToString(); cmd.Parameters.Add("@EDWSTARTDATE", SqlDbType.DateTime).Value = Row.EDWEFFECTIVESTARTDATETIME; SqlDataAdapter adapter = new SqlDataAdapter(cmd); adapter.Fill(dt); foreach (DataRow dtrow in dt.Rows) { OutputValidBuffer.AddRow(); OutputValidBuffer.OPNK = Row.OPNK; OutputValidBuffer.OSPTYPECODE = Row.OSPTYPECODE; OutputValidBuffer.ORGPROVTYPEDESC = Row.ORGPROVTYPEDESC; OutputValidBuffer.HEALTHSECTORCODE = Row.HEALTHSECTORCODE; OutputValidBuffer.HEALTHSECTORDESCRIPTION = Row.HEALTHSECTORDESCRIPTION; OutputValidBuffer.EDWEFFECTIVESTARTDATETIME = Row.EDWEFFECTIVESTARTDATETIME; OutputValidBuffer.EDWEFFECTIVEENDDATETIME = Row.EDWEFFECTIVEENDDATETIME; OutputValidBuffer.OPQI = Row.OPQI; OutputValidBuffer.OPNNK = dtrow[0].ToString(); OutputValidBuffer.OSPNAMETYPECODE = dtrow[1].ToString(); OutputValidBuffer.NAMETYPEDESC = dtrow[2].ToString(); OutputValidBuffer.OSPNAME = dtrow[3].ToString(); OutputValidBuffer.EDWEFFECTIVESTARTDATETIME1 = Row.EDWEFFECTIVESTARTDATETIME; OutputValidBuffer.EDWEFFECTIVEENDDATETIME1 = Row.EDWEFFECTIVEENDDATETIME; OutputValidBuffer.OPNQI = dtrow[6].ToString(); } } } public override void ReleaseConnections() { cnManager.ReleaseConnection(cnn); } } This is always skipping the first row. while(Row.NextRow()) is always bringing the second row of the input buffer. What am I doing wrong. Thanks

    Read the article

  • File Watcher Task

    The task will detect changes to existing files as well as new files, both actions will cause the file to be found when available. A file is available when the task can open it exclusively. This is important for files that take a long time to be written, such as large files, or those that are just written slowly or delivered via a slow network link. It can also be set to look for existing files first (1.2.4.55). The full path of the found file is returned in up to three ways: The ExecValueVariable of the task. This can be set to any String variable. The OutputVariableName when specified. This can be set to any String variable. The FullPath variable within OnFileFoundEvent. This is a File Watcher Task specific event.   Advanced warning of a file having been detected, but not yet available is returned through the OnFileWatcherEvent. This event does not always coincide with the completion of the task, as completion and the OnFileFoundEvent is delayed until the file is ready for use. This event indicates that a file has been detected, and that file will now be monitored until it becomes available. The task will only detect and report on the first file that is created or changes, any subsequent changes will be ignored. Task properties and there usages are documented below: Property Data Type Description Filter String Default filter *.* will watch all files. Standard windows wildcards and patterns can be used to restrict the files monitored. FindExistingFiles Boolean Indicates whether the task should check for any existing files that match the path and filter criteria, before starting the file watcher. IncludeSubdirectories Boolean Indicates whether changes in subdirectories are accepted or ignored. OutputVariableName String The name of the variable into which the full file path found will be written on completion of the task. The variable specified should be of type string. Path String Path to watch for new files or changes to existing files. The path is a directory, not a full filename. For a specific file, enter the file name in the Filter property and the directory in the Path property. PathInputType FileWatcherTask.InputType Three input types are supported for the path: Connection - File connection manager, of type existing folder. Direct Input - Type the path directly into the UI or set on the property as a literal string. Variable – The name of the variable which contains the path. Timeout Integer Time in minutes to wait for a file. If no files are detected within the timeout period the task will fail. The default value of 0 means infinite, and will not expire. TimeoutAsWarning Boolean The default behaviour is to raise an error and fail the task on timeout. This property allows you to suppress the error on timeout, a warning event is raised instead, and the task succeeds. The default value is false.   Installation The task is provided as an MSI file which you can download and run to install it. This simply places the files on disk in the correct locations and also installs the assemblies in the Global Assembly Cache as per Microsoft’s recommendations. You may need to restart the SQL Server Integration Services service, as this caches information about what components are installed, as well as restarting any open instances of Business Intelligence Development Studio (BIDS) / Visual Studio that you may be using to build your SSIS packages. For 2005/2008 Only - Finally you will have to add the task to the Visual Studio toolbox manually. Right-click the toolbox, and select Choose Items.... Select the SSIS Control Flow Items tab, and then check the File Watcher Task in the Choose Toolbox Items window. This process has been described in detail in the related FAQ entry for How do I install a task or transform component? We recommend you follow best practice and apply the current Microsoft SQL Server Service pack to your SQL Server servers and workstations. Downloads The File Watcher Task  is available for SQL Server 2005, SQL Server 2008 (includes R2) and SQL Server 2012. Please choose the version to match your SQL Server version, or you can install multiple versions and use them side by side if you have more than one version of SQL Server installed. File Watcher Task for SQL Server 2005 File Watcher Task for SQL Server 2008 File Watcher Task for SQL Server 2012 Version History SQL Server 2012 Version 3.0.0.16 - SQL Server 2012 release. Includes upgrade support for both 2005 and 2008 packages to 2012. (5 Jun 2012) SQL Server 2008 Version 2.0.0.14 - Fixed user interface bug. A migration problem caused the UI type editors to reference an old SQL 2005 assembly. (17 Nov 2008) Version 2.0.0.7 - SQL Server 2008 release. (20 Oct 2008) SQL Server 2005 Version 1.2.6.100 - Fixed UI bug with TimeoutAsWarning property not saving correctly. Improved expression support in UI. File availability detection changed to use read-only lock, allowing reduced permissions to be used. Corrected installed issue which prevented installation on 64-bit machines with SSIS runtime only components. (18 Mar 2007) Version 1.2.5.73 - Added TimeoutAsWarning property. Gives the ability to suppress the error on timeout, a warning event is raised instead, and the task succeeds. (Task Version 3) (27 Sep 2006) Version 1.2.4.61 - Fixed a bug which could cause a loop condition with an unexpected exception such as incorrect file permissions. (20 Sep 2006) Version 1.2.4.55 - Added FindExistingFiles property. When true the task will check for an existing file before the file watcher itself actually starts. (Task Version 2) (8 Sep 2006) Version 1.2.3.39 - SQL Server 2005 RTM Refresh. SP1 Compatibility Testing. Property type validation improved. (12 Jun 2006) Version 1.2.1.0 - SQL Server 2005 IDW 16 Sept CTP. Futher UI enhancements, including expression indicator. Fixed bug caused by execution within loop Subsequent iterations detected the same file as the first iteration. Added IncludeSubdirectories property. Fixed bug when changes made in subdirectories, and folder change was detected, causing task failure. (Task Version 1) (6 Oct 2005) Version 1.2.0.0 - SQL Server 2005 IDW 15 June CTP. Changes made include an enhanced UI, the PathInputType property for greater flexibility with path input, the OutputVariableName property, and the new OnFileFoundEvent event. (7 Sep 2005) Version 1.1.2 - Public Release (16 Nov 2004) Screenshots   Troubleshooting Make sure you have downloaded the version that matches your version of SQL Server. We offer separate downloads for SQL Server 2005 and SQL Server 2008. If you an error when you try and use the task along the lines of The task with the name "File Watcher Task" and the creation name ... is not registered for use on this computer, this usually indicates that the internal cache of SSIS components needs to be updated. This cache is held by the SSIS service, so you need restart the the SQL Server Integration Services service. You can do this from the Services applet in Control Panel or Administrative Tools in Windows. You can also restart the computer if you prefer. You may also need to restart any current instances of Business Intelligence Development Studio (BIDS) / Visual Studio that you may be using to build your SSIS packages. The full error message is shown below for reference: TITLE: Microsoft Visual Studio ------------------------------ The task with the name "File Watcher Task" and the creation name "Konesans.Dts.Tasks.FileWatcherTask.FileWatcherTask, Konesans.Dts.Tasks.FileWatcherTask, Version=1.2.0.0, Culture=neutral, PublicKeyToken=b2ab4a111192992b" is not registered for use on this computer. Contact Information: File Watcher Task A similar error message can be shown when trying to edit the task if the Microsoft Exception Message Box is not installed. This useful component is installed as part of the SQL Server Management Studio tools but occasionally due to the custom options chosen during SQL Server 2005 setup it may be absent. If you get an error like Could not load file or assembly 'Microsoft.ExceptionMessageBox.. you can manually download and install the missing component. It is available as part of the Feature Pack for SQL Server 2005 release. The feature packs are occasionally updated by Microsoft so you may like to check for a more recent edition, but you can find the Microsoft Exception Message Box download links here - Feature Pack for Microsoft SQL Server 2005 - April 2006 If you encounter this problem on SQL Server 2008, please check that you have installed the SQL Server client components. The component is no longer available as a separate download for SQL Server 2008  as noted in the Microsoft documentation for Deploying an Exception Message Box Application The full error message is shown below for reference, although note that the Version will change between SQL Server 2005 and SQL Server 2008: TITLE: Microsoft Visual Studio ------------------------------ Cannot show the editor for this task. ------------------------------ ADDITIONAL INFORMATION: Could not load file or assembly 'Microsoft.ExceptionMessageBox, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The system cannot find the file specified. (Konesans.Dts.Tasks.FileWatcherTask) Once installation is complete you need to manually add the task to the toolbox before you will see it and to be able add it to packages - How do I install a task or transform component? If you are still having issues then contact us, but please provide as much detail as possible about error, as well as which version of the the task you are using and details of the SSIS tools installed. Sample Code If you wanted to use the task programmatically then here is some sample code for creating a basic package and configuring the task. It uses a variable to supply the path to watch, and also sets a variable for the OutputVariableName. Once execution is complete it writes out the file found to the console. /// <summary> /// Create a package with an File Watcher Task /// </summary> public void FileWatcherTaskBasic() { // Create the package Package package = new Package(); package.Name = "FileWatcherTaskBasic"; // Add variable for input path, the folder to look in package.Variables.Add("InputPath", false, "User", @"C:\Temp\"); // Add variable for the file found, to be used on OutputVariableName property package.Variables.Add("FileFound", false, "User", "EMPTY"); // Add the Task package.Executables.Add("Konesans.Dts.Tasks.FileWatcherTask.FileWatcherTask, " + "Konesans.Dts.Tasks.FileWatcherTask, Version=1.2.0.0, Culture=neutral, PublicKeyToken=b2ab4a111192992b"); // Get the task host wrapper TaskHost taskHost = package.Executables[0] as TaskHost; // Set basic properties taskHost.Properties["PathInputType"].SetValue(taskHost, 1); // InputType.Variable taskHost.Properties["Path"].SetValue(taskHost, "User::InputPath"); taskHost.Properties["OutputVariableName"].SetValue(taskHost, "User::FileFound"); #if DEBUG // Save package to disk, DEBUG only new Application().SaveToXml(String.Format(@"C:\Temp\{0}.dtsx", package.Name), package, null); #endif // Display variable value before execution to check EMPTY Console.WriteLine("Result Variable: {0}", package.Variables["User::FileFound"].Value); // Execute package package.Execute(); // Display variable value after execution, e.g. C:\Temp\File.txt Console.WriteLine("Result Variable: {0}", package.Variables["User::FileFound"].Value); // Perform simple check for execution errors if (package.Errors.Count > 0) foreach (DtsError error in package.Errors) { Console.WriteLine("ErrorCode : {0}", error.ErrorCode); Console.WriteLine(" SubComponent : {0}", error.SubComponent); Console.WriteLine(" Description : {0}", error.Description); } else Console.WriteLine("Success - {0}", package.Name); // Clean-up package.Dispose(); } (Updated installation and troubleshooting sections, and added sample code July 2009)

    Read the article

  • How to dynamically change the content of a facet in a custom component?

    - by romaintaz
    Hello, Let's consider that I want to extend an existing JSF component, such as the <rich:datatable/>. My main requirement is to dynamically modify the content of a <f:facet>, to change its content. What is the best way to achieve that? Or where is the best place in the code to achieve that? In my faces-config.xml, I have the following declaration: <faces-config> ... <component> <component-type>my.component.dataTable</component-type> <component-class>my.project.component.table.MyHtmlDataTable</component-class> </component> ... <render-kit> <render-kit-id>HTML_BASIC</render-kit-id> <renderer> <component-family>org.richfaces.DataTable</component-family> <renderer-type>my.renderkit.dataTable</renderer-type> <renderer-class>my.project.component.table.MyDataTableRenderer</renderer-class> </renderer> ... Also, my my-project.taglib.xml file (as I use Facelets) looks like: <facelet-taglib> <namespace>http://my.project/jsf</namespace> <tag> <tag-name>dataTable</tag-name> <component> <component-type>my.component.dataTable</component-type> <renderer-type>my.renderkit.dataTable</renderer-type> </component> </tag> So as you can see, I have two classes in my project for my custom datatable: MyHtmlDataTable and MyDataTableRenderer. One of my idea is to modify the content of the <f:facet> directly in the doEncodeBegin() method of my renderer. This is working (in fact almost working), but I don't really think that's the better place to achieve my modification. What do you think? Technical information: JSF 1.2, Facelets, Richfaces 3.3.2, Java 1.6

    Read the article

  • Rendering MXML component only after actionscript is finished

    - by basicblock
    In my mxml file, I'm doing some calculations in the script tag, and binding them to a custom component. <fx:Script> <![CDATA[ [Bindable] public var calc1:Number; [Bindable] public var calc2:Number; private function init():void { calc1 = //calculation; calc2 = //calculation; } ]]> </fx:Script> <mycomp:Ball compfield1="{calc1}" compfield2="{calc2}"/> The problem is that the mxml component is being created before the actionscript is run. So when the component is created, it actually doesn't get calc1 and calc2 and it fails from that point. I know that binding happens after that, but the component and its functions have already started and have run with the null or 0 initial values. My solution was to create the component also in actionscript right after calc1 and calc2 have been created. This way I get to control precisely when it's created <fx:Script> <![CDATA[ [Bindable] public var calc1:Number; [Bindable] public var calc2:Number; private function init():void { calc1 = //calculation; calc2 = //calculation; var Ball:Ball = new Ball(calc1, calc2); } ]]> </fx:Script> but this is creating all kinds of other problems due to the way I've set up the component. Is there a way I can still use mxml to create the component, yet control that it the <myComp:Ball> gets created only after init() is run and calc1 calc2 evaluated?

    Read the article

  • CakePHP: Why does adding 'Security' component break my app?

    - by Steve
    I have a strange problem -- of my own making -- that's cropped up, and is driving me crazy. At some point, I inadvertently destroyed a file in the app/tmp directory...I'm not sure which file. But now my app breaks when I include the "Security" component, and works just fine when it's not included. I'm thinking it might be related to the Security.salt value somehow, or possibly to the saved session info, but I don't really have a deep enough knowledge of CakePHP to figure it out. Can anyone offer any insight here?

    Read the article

  • Where to define a filter function for a form field in my Joomla component's preferences

    - by Herman
    I am creating a component in Joomla 2.5. This component has some options that are defined in its config.xml, so they can be set in the preferences of the component. Now I would like to apply a filter to one of these option fields, using the attribute filter="my_filter". In the source code of JForm I saw the following lines at the very end of the implementation of JForm::filterField(): if (strpos($filter, '::') !== false && is_callable(explode('::', $filter))) { $return = call_user_func(explode('::', $filter), $value); } elseif (function_exists($filter)) { $return = call_user_func($filter, $value); } That's what I needed for using a filter function defined by myself! I managed to do this for form fields used in the views of my component. I defined the filter function as MyComponentHelper::my_filter(), where MyComponentHelper is a helper class which I always load in the very base of my component. And in the form's xml I added filter="MyComponentHelper::my_filter" to the fields that have to be filtered. However... when I am trying to apply the filter function to a form field in my component's preferences, I am not in my own component, but in com_config instead, so my helper class is not available! So, therefore, my question: where to define my own filter function in such a way that it can be found and called by JForm::filterField() in com_config?? Help is very much appreciated.

    Read the article

  • Flex component setActualSize

    - by dlots
    I am a little confused about the setActualSize method. It appears from what I've read, that if it is not called on a component by its parent, the component will not be rendered. So it appears that setActualSize is a critical method that is directly bound to rendering the UIComponent. It also appears that the width and height properties of UIComponent override the functionality of the width and height properties of flash.display.DisplayObject, in that they are not directly bound to the rendering of the object but are virtual values that are mainly used by the getExplicitOrMeasured when the parent of the component calls the component's setActualSize method. So the question are: 1) Why isn't the default behavior of every component to just call setActualSize(getExplicitOrMeasuredWidth(),getExplicitOrMeasuredHeight()) on itself? 2) I guess this question stems from the above question and the behavior as I understand it as described above: does setActualSize change the visibility of the component? It appears that that the behavior is that a component is not rendered until setActualSize is called, but if it contains display object children itself (expected behavior as it can calculate measure on itself) and is added to the display list, the only reason why flash isn't rendering it, is because its not visible. 3) Relating to question #1, does updateDisplayList of UIComponent have a method that goes through its children calling setActualSize on each of them?

    Read the article

  • Flex: How to create a floating notification message of sorts for a custom component?

    - by aberrant80
    I have a custom TextInput-based component for date and time with certain restrictions on what's considered "within range". But it's still fine to insert dates that are outside the range. When a user types in a date, on valueCommit, I'd like to be able to display a hovering notification to the user, to inform/warn them that the date is outside the accepted range. I'm thinking of notifications ala the Validators, but I'd rather not use the Validator mechanism because it's really not validation, just notification. Something like a tooltip, but it will only appear if the user changed the value. Maybe an effect of some sort? If anyone has any ideas or if anyone has done something like this, I'm all ears!

    Read the article

  • How to know the order of component rendering in Flex

    - by Tam
    I have a component that has a sub-component they both use a shared variable from the model. The shared variable needs to be set by the parent component before it can be used by the child component. I did like this in the parent component: <mx:Canvas xmlns:mx="library://ns.adobe.com/flex/mx" ... creationComplete="group1_completeHandler(event)" > .... protected function group1_activateHandler(event:Event):void { model.myVariable = something; } .... <components:myCustomComponent> ... <components:myCustomComponent> ... </mx:Canvas> But for some reason when the code inside myCustomComponent tries to use myVariable for the first time I get a "null" object error. This means I guess that the child component gets rendered before the group1_activateHandler gets called and consequently myVariable gets set. What should I do to ensure that the parent container initializes the variable before the child component gets created?

    Read the article

  • State changes in entities or components

    - by GriffinHeart
    I'm having some trouble figuring how to deal with state management in my entities. I don't have trouble with Game state management, like pause and menus, since these are not handled as an entity component system; just with state in entities/components. Drawing from Orcs Must Die as an example, I have my MainCharacter and Trap entities which only have their components like PositionComponent, RenderComponent, PhysicsComponent. On each update the Entity will call update on its components. I also have a generic EventManager with listeners for different event types. Now I need to be able to place the traps: first select the trap and trap position then place the trap. When placing a trap it should appear in front of the MainCharacter, rendered in a different way and following it around. When placed it should just respond to collisions and be rendered in the normal way. How is this usually handled in component based systems? (This example is specific but can help figure out the general way to deal with entities states.)

    Read the article

  • How to prioritize related game entity components?

    - by Paul Manta
    I want to make a game where you have to run over a bunch of zombies with your car. When moving around, the zombies have a few things to take into consideration: When there's no player around they might just roam about randomly. And even when some other component dictates a specific direction, they should wobble to the left and right randomly (like drunk people). This implies a small, random, deviation in their movement. They should avoid static obstacles. When they see they are headed towards a wall, they should reorient themselves. They should avoid the car. They should try to predict where the car will be based on its velocity and try to move out of the way. When they can, they should try to get near the player. All these types of decisions they have to do seem like they should be implemented in different components. But how should I manage them? How can I give different components different weights that reflect the importance of each decision (in a given situation)? I would need some other component that acts as a manager, but do you have any tips on how I should implement it? Or maybe there's a better solution?...

    Read the article

  • Create excel files with GemBox.Spreadsheet .NET component

    - by hajan
    Generating excel files from .NET code is not always a very easy task, especially if you need to make some formatting or you want to do something very specific that requires extra coding. I’ve recently tried the GemBox Spreadsheet and I would like to share my experience with you. First of all, you can install GemBox Spreadsheet library from VS.NET 2010 Extension manager by searching in the gallery: Go in the Online Gallery tab (as in the picture bellow) and write GemBox in the Search box on top-right of the Extension Manager, so you will get the following result: Click Download on GemBox.Spreadsheet and you will be directed to product website. Click on the marked link then you will get to the following page where you have the component download link Once you download it, install the MSI file. Open the installation folder and find the Bin folder. There you have GemBox.Spreadsheet.dll in three folders each for different .NET Framework version. Now, lets move to Visual Studio.NET. 1. Create sample ASP.NET Web Application and give it a name. 2. Reference The GemBox.Spreadsheet.dll file in your project So you don’t need to search for the dll file in your disk but you can simply find it in the .NET tab in ‘Add Reference’ window and you have all three versions. I chose the version for 4.0.30319 runtime. Next, I will retrieve data from my Pubs database. I’m using Entity Framework. Here is the code (read the comments in it):             //get data from pubs database, tables: authors, titleauthor, titles             pubsEntities context = new pubsEntities();             var authorTitles = (from a in context.authors                                join tl in context.titleauthor on a.au_id equals tl.au_id                                join t in context.titles on tl.title_id equals t.title_id                                select new AuthorTitles                                {                                     Name = a.au_fname,                                     Surname = a.au_lname,                                     Title = t.title,                                     Price = t.price,                                     PubDate = t.pubdate                                }).ToList();             //using GemBox library now             ExcelFile myExcelFile = new ExcelFile();             ExcelWorksheet excWsheet = myExcelFile.Worksheets.Add("Hajan's worksheet");             excWsheet.Cells[0, 0].Value = "Pubs database Authors and Titles";             excWsheet.Cells[0, 0].Style.Borders.SetBorders(MultipleBorders.Bottom,System.Drawing.Color.Red,LineStyle.Thin);             excWsheet.Cells[0, 1].Style.Borders.SetBorders(MultipleBorders.Bottom, System.Drawing.Color.Red, LineStyle.Thin);                                      int numberOfColumns = 5; //the number of properties in the authorTitles we have             //for each column             for (int c = 0; c < numberOfColumns; c++)             {                 excWsheet.Columns[c].Width = 25 * 256; //set the width to each column                             }             //header row cells             excWsheet.Rows[2].Cells[0].Value = "Name";             excWsheet.Rows[2].Cells[1].Value = "Surname";             excWsheet.Rows[2].Cells[2].Value = "Title";             excWsheet.Rows[2].Cells[3].Value = "Price";             excWsheet.Rows[2].Cells[4].Value = "PubDate";             //bind authorTitles in the excel worksheet             int currentRow = 3;             foreach (AuthorTitles at in authorTitles)             {                 excWsheet.Rows[currentRow].Cells[0].Value = at.Name;                 excWsheet.Rows[currentRow].Cells[1].Value = at.Surname;                 excWsheet.Rows[currentRow].Cells[2].Value = at.Title;                 excWsheet.Rows[currentRow].Cells[3].Value = at.Price;                 excWsheet.Rows[currentRow].Cells[4].Value = at.PubDate;                 currentRow++;             }             //stylizing my excel file look             CellStyle style = new CellStyle(myExcelFile);             style.HorizontalAlignment = HorizontalAlignmentStyle.Left;             style.VerticalAlignment = VerticalAlignmentStyle.Center;             style.Font.Color = System.Drawing.Color.DarkRed;             style.WrapText = true;             style.Borders.SetBorders(MultipleBorders.Top                 | MultipleBorders.Left | MultipleBorders.Right                 | MultipleBorders.Bottom, System.Drawing.Color.Black,                 LineStyle.Thin);                                 //pay attention on this, we set created style on the given (firstRow, firstColumn, lastRow, lastColumn)             //in my example:             //firstRow = 2; firstColumn = 0; lastRow = authorTitles.Count+1; lastColumn = numberOfColumns-1; variable             excWsheet.Cells.GetSubrangeAbsolute(3, 0, authorTitles.Count+2, numberOfColumns-1).Style = style;             //save my excel file             myExcelFile.SaveXls(Server.MapPath(".") + @"/myFile.xls"); The AuthorTitles class: public class AuthorTitles {     public string Name { get; set; }     public string Surname { get; set; }     public string Title { get; set; }     public decimal? Price { get; set; }     public DateTime PubDate { get; set; } } The excel file will be generated in the root of your ASP.NET Web Application. The result is: There is a lot more you can do with this library. A set of good examples you have in the GemBox.Spreadsheet Samples Explorer application which comes together with the installation and you can find it by default in Start –> All Programs –> GemBox Software –> GemBox.Spreadsheet Samples Explorer. Hope this was useful for you. Best Regards, Hajan

    Read the article

  • Flex 4: Component move event

    - by alexey
    I have a CustomTextInput component based on TextInput (Spark) component. The instance of this class is placed on a popup window (TitleWindow). How can I capture the popup move (dragging the title) event inside CustomTextInput implementation? MoveEvent.MOVE event of the CustomTextInput itself doesn't work. Of course, I can't access the parent popup window inside the component implementation, because it's a common component that can be used not only on the popup windows.

    Read the article

  • Searching an open source RSS component, any suggestions?

    - by Antipod
    Guys, I am searching an open source RSS component to use in my project (.Net 3.5, C#). I have found ASP.Net RSS toolkit: http://aspnetrsstoolkit.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=3674. Do you know about advantages and disadvantages of the component? Could you suggest a better open source RSS component, if yes, what are pros and cons of the suggested component? Thanks a lot.

    Read the article

  • Regular Expression Transformation

    The regular expression transformation exposes the power of regular expression matching within the pipeline. One or more columns can be selected, and for each column an individual expression can be applied. The way multiple columns are handled can be set on the options page. The AND option means all columns must match, whilst the OR option means only one column has to match. If rows pass their tests then rows are passed down the successful match output. Rows that fail are directed down the alternate output. This transformation is ideal for validating data through the use of regular expressions. You can enter any expression you like, or select a pre-configured expression within the editor. You can expand the list of pre-configured expressions yourself. These are stored in a Xml file, %ProgramFiles%\Microsoft SQL Server\nnn\DTS\PipelineComponents\RegExTransform.xml, where nnn represents the folder version, 90 for 2005, 100 for 2008 and 110 for 2012. If you want to use regular expressions to manipulate data, rather than just validating it, try the RegexClean Transformation. The component is provided as an MSI file, however for 2005/200 you will have to add the transformation to the Visual Studio toolbox by hand. This process has been described in detail in the related FAQ entry for How do I install a task or transform component?, just select Regular Expression Transformation in the Choose Toolbox Items window. Downloads The Regular Expression Transformation is available for SQL Server 2005, SQL Server 2008 (includes R2) and SQL Server 2012. Please choose the version to match your SQL Server version, or you can install multiple versions and use them side by side if you have more than one version of SQL Server installed. Regular Expression Transformation for SQL Server 2005 Regular Expression Transformation for SQL Server 2008 Regular Expression Transformation for SQL Server 2012 Version History SQL Server 2012Version 2.0.0.87 - SQL Server 2012 release. Includes upgrade support for both 2005 and 2008 packages to 2012. (5 Jun 2012) SQL Server 2008Version 2.0.0.87 - Release for SQL Server 2008 Integration Services. (10 Oct 2008) SQL Server 2005 Version 1.1.0.93 - Added option for you to choose AND or OR logic when multiple columns have been selected. Previously behaviour was OR only. (31 Jul 2008) Version 1.0.0.76 - Installer update and improved exception handling. (28 Jan 2008) Version 1.0.0.41 - Update for user interface stability fixes. (2 Aug 2006) Version 1.0.0.24 - SQL Server 2005 RTM Refresh. SP1 Compatibility Testing. (12 Jun 2006) Version 1.0.0.9 - Public Release for SQL Server 2005 IDW 15 June CTP (29 Aug 2005) Screenshots  

    Read the article

  • Please help with System.Runtime.InteropServices.SEHException: External component has thrown an excep

    - by Brandon
    My aspx page gives me this error sometimes: External component has thrown an exception. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Runtime.InteropServices.SEHException: External component has thrown an exception. Source Error: An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace: [SEHException (0x80004005): External component has thrown an exception.] Luxand.FSDK.Initialize(String DataFilesPath) +0 WebService.onLoad() +70 WebService..ctor() +91 facematch.Page_Load(Object sender, EventArgs e) +50 System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +15 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +33 System.Web.UI.Control.OnLoad(EventArgs e) +99 System.Web.UI.Control.LoadRecursive() +47 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1436

    Read the article

  • Cannot Debug Visual Basic 6 ActiveX Component On 64-bit OS

    - by Humanier
    Hi, The situation might sound a bit weird but I have to play with what I have. There's a Win2003 64-bit server OS and a legacy application written using Visual Studio 6. The app consists of two parts: ActiveX components written in VB6 and C++ code which uses them. I need to debug the components' code. I installed Visual Studio 6 on the server and I'm able to step into the component's code. Then I got following situation: 1) C++ code works until it needs to instantiate component A. 2) At this step we switch to VB6 and start debugging Component's A. 3) In the very beginning component A creates an instance of a class C exposed by component B. At this step VB6 debugger shows error message with title "OLEDB32.DLL" and following text: "Failed to load resource DLL C:\Program Files (x86)\Common Files\System\Ole DB\OLEDB32R.DLL" Additional information: The last step in initialization of the class C is opening an ADO connection to SQL server using OLEDB provider. I'd appreciate any ideas on how resolve this problem. Thanks in advance.

    Read the article

  • Calling a COM+ Component remotely using C#

    - by Arturo Caballero
    Hello, I have a little COM+ component as a service on a remote server. I´m trying to execute a method of this component using: Type type = Type.GetTypeFromProgID("ComPlusTest.ComTestClass",serverName); // Create Service Object service = Activator.CreateInstance(type); // Execute Method String result = service.GetType().InvokeMember("LaunchPackage", BindingFlags.InvokeMethod, null, parameters, null).ToString(); The type is returned as null. What is the best way to do this?? The server is Windows 2003 Enterprise, the service is a .NET component wraped as COM+ (I know that I don´t have to do it that way, but the purpose is to itegrate a legacy App with a .NET component) The purpose of this is just to test that the .NET COM+ Component works. Thanks in advance!

    Read the article

  • Deploying .NET components (upgrade the component for only a single client application)

    - by Vytas999
    I use Visual Studio .NET to create a component that will be shared by two client applications. Eventually, I plan to deploy new version of this component. However, not all of the new versions will be compatible with both client applications. When I deploy component and the client applications, I must ensure that I can upgrade the component for a single client application. I must also minimize the need for configuration changes when I deploy new version of the component. What are possible ways to achieve this goal?

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >