Search Results

Search found 421 results on 17 pages for 'luis yang'.

Page 7/17 | < Previous Page | 3 4 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • iPhone Inspiration Stories...

    - by Luis Tovar
    So we have all heard of these overnight millionaires in the app store. We know it would be great, but somewhat unlikely to do ourselves. What I do know is, that learning and developing for the iPhone can sometimes be overwhelming. I continue to push on and learn more and more, even when my brain just cant take anymore I turn my mac on and read up on how to do new and different things I haven't done yet in my app yet. I would like to see a few post's of a common day developer's story and how their life has improved now that they are sitting up on the golden pedestal of an iphone developer. I look at these Dice.com jobs on think how nice it would be to be making that kind of money offered for an experienced iphone developer. Im on my way... and while I'm on that road i'd like to look over and see your story... Please include how you got into iPhone development and any apps you have out there and your success with them. Care to share?

    Read the article

  • Vs2010 using log4net with Intellisense

    - by Luís Custódio
    I'm using vs2010 and I need to log a multithreading application. So I decided to use log4net, but as I'm not used to work with this, Intellisense is gonna be worth. I download the .xsd from http://csharptest.net/downloads/schema/log4net.xsd and put this in VSFolder/Xml/Schemas. But, how can I say to my log4net.config to use the XSD Schema?

    Read the article

  • Couldn't attachto Firefox 3.x browser by using Browser.AttachTo<FireFox>method in WatiN 2.0 RC1

    - by Shu Yang
    I am using HTTPWatch automation API to launch a new Firefox instance like that: HttpWatch.Controller ct = new HttpWatch.Controller(); HttpWatch.Plugin plugin = ct.FireFox.New(""); plugin.GotoURL("http://www.google.com"); These codes could start a Firefox browser successfully. Then I want to control the browser in WatiN 2.0: FireFox ff = Browser.AttachTo<FireFox>(Find.ByTitle("Google")); WatiN could not find Firefox window (JSSH plugin has been added in Firefox). But the same test on IE 7 is ok. I even tried to open a Firefox window manually and visit google.com page. WaitN in IE7 could attach to the browser, but Firefox failed. Is there anything wrong with my codes? Or any other advice? Thanks in advance! Here is the config for my environment: OS: Windows XP Pro SP2 WatiN: 2.0 RC1 Browser: IE 7, Firefox 3.0/3.5/3.6 with JSSH plugin

    Read the article

  • Convert htaccess to helicon tech ISAPI rewrite

    - by Luis
    Can someone help me converting these htaccess rewrite rules to helicon tech ISAP? RewriteEngine On RewriteBase / # remove the www RewriteCond %{HTTP_HOST} ^(www\.$) [NC] RewriteRule ^ http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] # Add a trailing slash to paths without an extension RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_URI} !(\.[a-zA-Z0-9]{1,5}|/)$ RewriteRule ^(.*)$ $1/ [L,R=301] # Remove index.php RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /index.php/$1 [L] Thanks

    Read the article

  • NHibernate: Collection was modified; enumeration operation may not execute

    - by Daoming Yang
    Hi All, I'm currently struggling with this "Collection was modified; enumeration operation may not execute" issue. I have searched about this error message, and it's all related to the foreach statement. I do have the some foreach statements, but they are just simply representing the data. I did not using any remove or add inside the foreach statement. NOTE: The error randomly happens (about 4-5 times a day). The application is the MVC website. There are about 5 users operate this applications (about 150 orders a day). Could it be some another users modified the collection, and then occur this error? I have log4net setup and the settings can be found here Make sure that the controller has a parameterless public constructor I do have parameterless public constructor in AdminProductController Does anyone know why this happen and how to resolve this issue? A friend (Oskar) mentioned that "Theory: Maybe the problem is that your configuration and session factory is initialized on the first request after application restart. If a second request comes in before the first request is finished, maybe it will also try to initialize and then triggering this problem somehow." Many thanks. Daoming Here is the error message: System.InvalidOperationException Collection was modified; enumeration operation may not execute. System.InvalidOperationException: An error occurred when trying to create a controller of type 'WebController.Controllers.Admin.AdminProductController'. Make sure that the controller has a parameterless public constructor. --- System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. --- NHibernate.MappingException: Could not configure datastore from input stream DomainModel.Entities.Mappings.OrderProductVariant.hbm.xml --- System.InvalidOperationException: Collection was modified; enumeration operation may not execute. at System.Collections.ArrayList.ArrayListEnumeratorSimple.MoveNext() at System.Xml.Schema.XmlSchemaSet.AddSchemaToSet(XmlSchema schema) at System.Xml.Schema.XmlSchemaSet.Add(String targetNamespace, XmlSchema schema) at System.Xml.Schema.XmlSchemaSet.Add(XmlSchema schema) at NHibernate.Cfg.Configuration.LoadMappingDocument(XmlReader hbmReader, String name) at NHibernate.Cfg.Configuration.AddInputStream(Stream xmlInputStream, String name) --- End of inner exception stack trace --- at NHibernate.Cfg.Configuration.LogAndThrow(Exception exception) at NHibernate.Cfg.Configuration.AddInputStream(Stream xmlInputStream, String name) at NHibernate.Cfg.Configuration.AddResource(String path, Assembly assembly) at NHibernate.Cfg.Configuration.AddAssembly(Assembly assembly) at DomainModel.RepositoryBase..ctor() at WebController.Controllers._baseController..ctor() at WebController.Controllers.Admin.AdminProductController..ctor() at System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) --- End of inner exception stack trace --- at System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) at System.Activator.CreateInstance(Type type, Boolean nonPublic) at System.Web.Mvc.DefaultControllerFactory.GetControllerInstance(RequestContext requestContext, Type controllerType) --- End of inner exception stack trace --- at System.Web.Mvc.DefaultControllerFactory.GetControllerInstance(RequestContext requestContext, Type controllerType) at System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName) at System.Web.Mvc.MvcHandler.ProcessRequestInit(HttpContextBase httpContext, IController& controller, IControllerFactory& factory) at System.Web.Mvc.MvcHandler.BeginProcessRequest(HttpContextBase httpContext, AsyncCallback callback, Object state) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) UPDATE CODE: In my Global.asax.cs, I'm doing this: protected void Application_BeginRequest(object sender, EventArgs e) { ManagedWebSessionContext.Bind(HttpContext.Current, SessionManager.SessionFactory.OpenSession()); } protected void Application_EndRequest(object sender, EventArgs e) { ISession session = ManagedWebSessionContext.Unbind(HttpContext.Current, SessionManager.SessionFactory); if (session != null) { try { if (session.Transaction != null && session.Transaction.IsActive) { session.Transaction.Rollback(); } else { session.Flush(); } } finally { session.Close(); } } } In the SessionManager class, I'm doing: public class SessionManager { private readonly ISessionFactory sessionFactory; public static ISessionFactory SessionFactory { get { return Instance.sessionFactory; } } private ISessionFactory GetSessionFactory() { return sessionFactory; } public static SessionManager Instance { get { return NestedSessionManager.sessionManager; } } public static ISession OpenSession() { return Instance.GetSessionFactory().OpenSession(); } public static ISession CurrentSession { get { return Instance.GetSessionFactory().GetCurrentSession(); } } private SessionManager() { Configuration config = new Configuration().Configure(); config.AddAssembly(Assembly.GetExecutingAssembly()); sessionFactory = config.BuildSessionFactory(); } class NestedSessionManager { internal static readonly SessionManager sessionManager = new SessionManager(); } } In the Repository, I'm doing this: public IEnumerable<User> GetAll() { ICriteria criteria = SessionManager.CurrentSession.CreateCriteria(typeof(User)); return criteria.List<User>(); } In the Controller, I'm doing this: public class UserController : _baseController { IUserRoleRepository _userRoleRepository; internal static readonly ILogger log = LogManager.GetLogger(typeof(UserController)); public UserController() { _userRoleRepository = new UserRoleRepository(); } public ActionResult UserList() { var myList = _usersRepository.GetAll(); return View(myList); } }

    Read the article

  • android: how to align image in the horizontal center of an imageview?

    - by Yang
    I've tried all scaletype in gravity, but all of them result in the image to be at the left corner of the imageview. <ImageView android:id="@+id/image" android:scaleType="centerInside" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginRight="6dip" android:background="#0000" android:src="@drawable/icon1" />

    Read the article

  • Android: failed to setContentView when switching to ListActivity

    - by Yang
    This is an follow-up issue on my previous question http://stackoverflow.com/questions/2548304/android-which-view-should-i-use-for-showing-text-and-image I read the article about creating ListView for LinearLayout. However, my following code failed at the setContentView() function when I changed "extends Activity" to "extends ListActivity", any idea why? private TextView mSelection; //private ImageView mImages; static final String[] keywords = new String[]{"China", "Japan", "USA", "Canada"}; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.contactLayout); mSelection = (TextView)findViewById(R.id.ContactNames); ArrayAdapter adapter = new ArrayAdapter<String>(this, R.layout.contactlayout, R.id.ContactNames,keywords); setListAdapter(adapter); } My Layout is from this article: http://www.curious-creature.org/2009/02/22/android-layout-tricks-1/ <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="?android:attr/listPreferredItemHeight" android:padding="6dip"> <ImageView android:id="@+id/icon" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_marginRight="6dip" android:src="@drawable/icon" /> <LinearLayout android:orientation="vertical" android:layout_width="0dip" android:layout_weight="1" android:layout_height="fill_parent"> <TextView android:id="@+id/ContactNames" android:layout_width="fill_parent" android:layout_height="0dip" android:layout_weight="1" android:gravity="center_vertical" android:text="My Application" /> <TextView android:layout_width="fill_parent" android:layout_height="0dip" android:layout_weight="1" android:singleLine="true" android:ellipsize="marquee" android:text="Simple application that shows how to use RelativeLayout" /> </LinearLayout>

    Read the article

  • android: tablerow mixed with columns and multiline text

    - by Yang
    I am trying to have a tablelayout contains several tablerows. One of the rows contains 4 buttons, while the second row contains a very long text. However, the width of the button stretches with the text in the second row. Is there anyway to prevent this? http://img684.imageshack.us/i/tableview1.jpg/ http://img521.imageshack.us/i/tableview2.jpg/ Here is my xml file: (somehow this website is not friendly to xml file) AbsoluteLayout android:id="@+id/widget0" android:layout_width="fill_parent" android:layout_height="fill_parent" xmlns:android="http://schemas.android.com/apk/res/android" TableLayout android:id="@+id/widget28" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="vertical" android:layout_x="0px" android:layout_y="10px" TableRow android:id="@+id/widget29" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="horizontal" Button android:id="@+id/widget30" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" Button android:id="@+id/widget31" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" Button android:id="@+id/widget32" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" Button android:id="@+id/widget33" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" TableRow android:id="@+id/widget35" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="horizontal" TextView android:id="@+id/widget40" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="TextViewTextViewTextViewTextViewTextViewTextView"

    Read the article

  • Registering instances with MEF

    - by yang
    I have to register an object instance into a container. I can't use the generic ComposeExportedValue<T> since I don't know what T is at compile time. The method I need is something like this: container.RegisterInstance(Type someType, object instance) Any ideas? Thanks.

    Read the article

  • Make svcutil.exe generate Properties with no Order attribute

    - by Luis Filipe
    I use svcutil.exe to generate proxy classes from a hosted WebService created by WebSphere that uses Java under the hood. I am using the XmlSerializer instead of DataContractSerializer and targeting Framework v3.5 with VS2010 The proxy classes are generated with the following attribute for each property [System.Xml.Serialization.XmlArrayAttribute(Order=20)] How can i tell the utility to suppress generating the Order parameter?

    Read the article

  • android: CheckedTextView cannot be checked?

    - by Yang
    Initially I wanted a checkmark where the text is placed on the left of the checkmark. After searching on this site I found out the best workaround is android:CheckedTextView? However, I found out that the checkmark cannot be changed manually by users. Is it by design? <CheckedTextView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/autoupdatecheckboxview" android:layout_width="fill_parent" android:layout_height="wrap_content" android:gravity="center_vertical" android:checkMark="?android:attr/listChoiceIndicatorMultiple" android:paddingLeft="6dip" android:paddingRight="6dip" android:text="Pop up a message when new data available" android:typeface="sans" android:textSize="16dip"/>

    Read the article

  • Trace not working in a .NET DLL loaded from VB6 EXE

    - by Luis
    Hello I have a .NET DLL that writes to the Trace. But seems that when I call my DLL from a VB6 EXE the trace is not working. I have created an myApp.config file in the EXE folder with the trace configuration, but this does not solves the issue. I've also tried creating the Trace objects in code,but doesn't work: Dim _traceSrc as TraceSource= New TraceSource("myTraceSorce") Dim flListener As FileLogTraceListener = New FileLogTraceListener("myFileLogTraceListener") Dim tSwitch As SourceSwitch = New SourceSwitch("mySwitch") tSwitch.Level = _logLevel If I call my DLL from a .NET EXE it works, even if I dont have the app.config in the EXE folder, becusase I set it in code if the config is not found. Thanks

    Read the article

  • android: which view should I use for showing text and image?

    - by Yang
    My app shows a list of items, where each line is an item title with its image asides, the line reserves 70% of space for text and 30% for image. Imagine what iphone app store looks like. Which view/layout combo is recommended for this purpose? I googled and find this article: http://www.curious-creature.org/2009/02/22/android-layout-tricks-1/ Does this view sound good? <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="?android:attr/listPreferredItemHeight" android:padding="6dip"> <ImageView android:id="@+id/icon" android:layout_width="wrap_content" android:layout_height="fill_parent" android:layout_alignParentTop="true" android:layout_alignParentBottom="true" android:layout_marginRight="6dip" android:src="@drawable/icon" /> <TextView android:id="@+id/secondLine" android:layout_width="fill_parent" android:layout_height="26dip" android:layout_toRightOf="@id/icon" android:layout_alignParentBottom="true" android:layout_alignParentRight="true" android:singleLine="true" android:ellipsize="marquee" android:text="Simple application that shows how to use RelativeLayout" /> <TextView android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_toRightOf="@id/icon" android:layout_alignParentRight="true" android:layout_alignParentTop="true" android:layout_above="@id/secondLine" android:layout_alignWithParentIfMissing="true" android:gravity="center_vertical" android:text="My Application" />

    Read the article

  • is there any easy way to auto generated code like this?

    - by Kevin Yang
    i have a file which will be used across many app projects. the only difference of these files is the webserice referrence name. code like this: public void Test(){ Kevin.ServiceReference1.Service1Client client = new Kevin.ServiceReference1.Service1Client(); // do something.... } like code above, the 'Kevin.ServiceReference1' will be replace by specified app project namespace. so, according to DRY(dont repeat yourself), i shouldn't just copy the file to many projects and rename the specified part manually. is there any way i can easily replace some parts of my template file to something related to the project?

    Read the article

  • android: two issues using Tablerow+TextView in Tablelayout

    - by Yang
    I am using Tablerow+TextView to make a simple view for blog posts and their replies. In each TableRow I put a TextView in. Now I have two issues: The text which is longer than the screen won't automatically wrap up to be multi-line. Is it by design of TableRow? I've already set tr_content.setSingleLine(false); [update] This has been addressed, I think I should change Fill_parent to be Wrap_content in textView.tr_author_time.setLayoutParams(new LayoutParams( LayoutParams.**WRAP_CONTENT**, LayoutParams.WRAP_CONTENT)); The Table won't scroll like ListView. My rows are more than the screen size. I expect the table could be scrolled down for viewing just like ListView. Is that possible? Here is my code: TableLayout tl = (TableLayout) findViewById(R.id.article_content_table); TextView tr_title = new TextView(this); TextView tr_author_time = new TextView(this); TextView tr_content = new TextView(this); TableRow tr = new TableRow(this); for(int i = 0; i < BlogPost.size(); i++){ try{ // add the author, time tr = new TableRow(this); /////////////////add author+time row BlogPost article = mBlogPost.get(i); tr_author_time = new TextView(this); tr_author_time.setText(article.author+"("+ article.post_time+")"); tr_author_time.setTextColor(getResources().getColor(R.color.black)); tr_author_time.setGravity(0x03); tr_author_time.setLayoutParams(new LayoutParams( LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); tr.addView(tr_author_time); tl.addView(tr,new TableLayout.LayoutParams( LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); ////////////////////// then add content row tr = new TableRow(this); tr_content = new TextView(this); tr_content.setText(article.content); tr_content.setSingleLine(false); tr_content.setGravity(0x03); tr_content.setLayoutParams(new LayoutParams( LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); tr.addView(tr_content); tr.setBackgroundResource(R.color.white); tl.addView(tr,new TableLayout.LayoutParams( LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); }

    Read the article

  • Accessing one process's memory contents from another module

    - by Fangkai Yang
    I am developing a virtual device driver such that the user can write to the driver a process' pid and a virtual address, and the module will use these two values to get the memory contents of the target process. I am wondering if there is any easy functions that can fetch user page's data at this virtual address. I have tried get_user but this is not possible because the modules executing get_user at another process's context. I also tried to use ptrace_readdata, however, it seems that the file at /kernel/ptrace.c leaves a function access_process_vm undefined and also I don't know how to compile the source code of my module with this file (the linker seaches file in /linux/include by default). I am wondering if there are any other solutions...

    Read the article

  • Apache Ant Build command "Access Denied"

    - by Luis Armando
    Hey! I am trying to get ant installed and actually already did following this instructions however, I get this error: Buildfile: build.xml does not exist! Build failed which it says there I might get so I just tried executing the next command it says I should(since I'm under Windows it's this one): build -Ddist.dir=<C:\Ant> dist anyway I get "access denied" when hitting enter and I can't figure out why. I also tried build install and build install-lite but I always get that message =/ any ideas why? or what am I doing wrong? Edit Without the < I get a: 'build' is not recognized as an internal or external command, operable program or batch file. Edit2 Well, my ANT_HOME is in C:\Ant and I'm trying to run the command while placing myself on that folder, isn't that correct?

    Read the article

  • MVC moq unit test the object before RedirecToAction()

    - by Daoming Yang
    I want to test the data inside the "item" object before it redirect to another action. public ActionResult WebPageEdit(WebPage item, FormCollection form) { if (ModelState.IsValid) { item.Description = Utils.CrossSiteScriptingAttackCheck(item.Description); item.Content = Utils.CrossSiteScriptingAttackCheck(item.Content); item.Title = item.Title.Trim(); item.DateUpdated = DateTime.Now; // Other logic stuff here webPagesRepository.Save(item); return RedirectToAction("WebPageList"); } Here is my Test method: [Test] public void Admin_WebPageEdit_Save() { var controller = new AdminController(); controller.webPagesRepository = DataMock.WebPageDataInit(); controller.categoriesRepository = DataMock.WebPageCategoryDataInit(); FormCollection form = DataMock.CreateWebPageFormCollection(); RedirectToRouteResult actionResult = (RedirectToRouteResult)controller.WebPageEdit(webPagesRepository.Get(1), form); Assert.IsNotNull(actionResult); Assert.AreEqual("WebPageList", actionResult.RouteValues["action"]); var item = ((ViewResult)controller.WebPageEdit(webPagesRepository.Get(1), form)).ViewData.Model as WebPage; Assert.NotNull(item); Assert.AreEqual(2, item.CategoryID); } It failed at this line: var item = ((ViewResult)controller.WebPageEdit(webPagesRepository.Get(1), form)).ViewData.Model as WebPage; I am thinking about is there any ways to test the "item" object before it redirect to other actions?

    Read the article

  • Windows Form: showing child object value in the DataGridView

    - by Daoming Yang
    I have a productVariant object which has child product object. I want to show the value in the DataGridView, can anyone let me know how to do this? Here is the structure of the object. I tried to bind "ProductVariant.Product.Name" to the DataProptertyName in the DataGridView, however, it did not not showing any value. Can anyone help with this? Many thanks.

    Read the article

  • How does Nike's website do this Flash effect when the user selects a choice.

    - by Luis Armando
    I was wondering how does Nike website make the change you can see when selecting a color or a sole. At first I thought they were only using images and when the user picked a color you just replaced that part, but when I selected a different sole I noticed it didn't changed like an image it looked a bit more as if it was being rendered. Does anybody happens to know how this is made? Or where can I get further info about making this effect :)?

    Read the article

  • I have a error building a .vdproj on msbuild with nant

    - by Luís Custódio
    I'm getting used to using nant for build releases. But I have started to use asp.net MVC, and i choice make the setup for installation with a .vdproj . But, when I call the: < exec program="${dotnet.dir}/msbuild.exe" commandline='"./Wum.sln" /v:q /nologo /p:Configuration=Release' / in nant, my result is: [exec] D:\My Documents\Visual Studio 2008\Projects\Wum\Wum.sln : warning MS B4078: The project file "Wum.Setup\Wum.Setup.vdproj" is not supported by MSBuild and cannot be built. Someone have some clue, or a solution? If I use the devenv, I'll have a problem? Thanks in advance.

    Read the article

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