Reputation: 1 Apprentice
- Active Members
- Active Posts:
- 119 (0.11 per day)
- 11-March 11
- Profile Views:
- Last Active:
- Jan 16 2014 12:55 PM
- Dream Kudos:
Posts I've Made
Posted 16 Jan 2014I am looking for a 2d list as well. A list meaning any other collection out there that's not an array, so a dictionary/List/Hasttable/HashSet
Key was just an example of what I could use to search the whole collection, rather than using a for loop. So if I was able to convert it over to a 2d dictionary, I could search the whole dictionary values with just the Key or Value variables which I am hoping to copy over from the 2d array.
Posted 16 Jan 2014To a different type of list entirely. What I'm looking for is I'm trying to reduce the amount of for loops I have, and to do that I was going to move the values of the array I originally looped through to find the value, to just be able to search for the key with a dictionary or hashtable hence removing the need to do multiple for loops, only just the one to convert or copy the array to a new list and then use that list from then on. 1d array aren't a problem but I guess i've never ran into this with 2d arrays before
Posted 14 Oct 2013@Modi - Perhaps I'm not understanding exactly what I thought a backgroundworker is for.
Currently, I have functions that take some time to run through(.5s+) in the background worker as to not have the UI wait for those functions to complete before allowing the window to be responsive. My question is really geared only towards one of my functions I am calling(the biggest one taking up to a possible 2s). My thought logic was to move that to the BGW to begin running the functions prior to updating the labels on the form(around 50+). In my mind, if it takes the form an avg of 6+ with normally just to load the labels and comboboxes putting these time consuming functions in the background worker would actually cut down the response time by many seconds. But currently it's looking that everything I placed in the BGW such as combobox populate functions and the big functions actually are updated last on the GUI. I'm assuming because the UI thread hasn't completed from the original thread, it then updates the BGW functions to update the UI. Perhaps I am misunderstanding the use of a BGW.
Note: The big functions are actually only updating some text boxes so it's just a few actual controls
@Martyr2 - Perhaps I didn't give enough information. The BGW actually does make my form more responsive and shows information at a much more rapid pace(to me anyway) but I am more curious as to why my functions that update controls in the BGW are last to update the UI if I call the BGW well before the _load code actually begins to run.
Regarding your note on delegates, I'm not too keen on these but I do believe you can use thread delegates to notify another thread. Like a BGW thread notifying the UI thread to update said control. I thought that since there's only one UI thread per application, that anything you would want to update control-wise would have to wait until the UI thread was free before you would be able to update any control on a form, regardless of delegates or not.
Thanks for your time!!
Posted 8 Oct 2013So I see it's a privacy thing. So what would you do if your child was taken? All you would be able to do is wait while the authorities find the person and who even knows if your child would still be alive by then. The world is a scary place and you can only do so much to keep your children safe. I'm not saying the chip is a good thing I'm just saying it gives you a fighting chance if this has is ever to happen to anyone.
Posted 9 Jul 2013Sorry for the late reply.
Here's the trace of the error to help better understand my issue /> The error is occuring on the line
HTMLElementMain.Click(). There may be a better way to go about this, but it's worked for me in the past so I'm not entirely sure if this way even works with any textbox out there.
System.UnauthorizedAccessException was unhandled Message="Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))" Source="mscorlib" StackTrace: at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object args, Boolean byrefModifiers, Int32 culture, String namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object providedArgs, ParameterModifier modifiers, CultureInfo culture, String namedParams) at Microsoft.VisualBasic.CompilerServices.VBBinder.InvokeMember(String name, BindingFlags invokeAttr, Type objType, IReflect objIReflect, Object target, Object args, String namedParameters) at Microsoft.VisualBasic.CompilerServices.LateBinding.InternalLateCall(Object o, Type objType, String name, Object args, String paramnames, Boolean CopyBack, Boolean IgnoreReturn) at Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateCall(Object Instance, Type Type, String MemberName, Object Arguments, String ArgumentNames, Type TypeArguments, Boolean CopyBack, Boolean IgnoreReturn) at YTAA.YTAA.btnBegin_Click(Object sender, EventArgs e) in xxxxxxxxxxxxxx at System.Windows.Forms.Control.onclick(EventArgs e) at System.Windows.Forms.Button.onclick(EventArgs e) at System.Windows.Forms.Button.onmouseup(MouseEventArgs mevent) at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ButtonBase.WndProc(Message& m) at System.Windows.Forms.Button.WndProc(Message& m) at System.Windows.Forms.Control.ControlNativewindow.OnMessage(Message& m) at System.Windows.Forms.Control.ControlNativewindow.WndProc(Message& m) at System.Windows.Forms.Nativewindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg) at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData) at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context) at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context) at System.Windows.Forms.Application.Run(ApplicationContext context) at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun() at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel() at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(String commandLine) at YTAA.My.MyApplication.Main(String Args) in 17d14f5c-a337-4978-8281-53493378c1071.vb:line 81 at System.AppDomain._nExecuteAssembly(Assembly assembly, String args) at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String args) at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart() InnerException:
- Member Title:
- D.I.C Head
- Age Unknown
- Birthday Unknown