Not sure it this is the right place or how to describe my problem. I have a brand new windows 10 and installed Office 2016. Now when I want to develop something in VBA in Excel or Word and I add a UserForm the icons in toolbox which represent the controls to use on the form are too small. The strange thing is, when I first added a form, the toolbox windows was hardly visible (first image). Does anyone know what the problem is? Or better how to solve it.
I had the same issue with SQL Management Studio. Same odd behaviour. Luckely today I stumbled upon a solution which works perfectly for SMSS. So I guess I can try it voor VBA as well.
SMSS solution
This is a nice workaround, but it is not needed anymore, because MS has an updated version available for SMSS which you can find here
Anyway, I know now what the issue is, so I can try this workaround for other applications too.
Related
I am building my first "real" VB Window Forms Application (I'm a "traditional programmer") and my application has perhaps half a dozen forms.
On execution all of these forms have the Windows 10 visual style (eg: grey on white max/min/close buttons at top right)... except for 1 form, which seems to be rendering in Win XP style (eg: Blue and red button style).
I have checked that "Enable XP Visual Styles" is UNClicked in the Project Properties, but this one form stubbornly refused to change.
I have a number of my forms that also appear in "XP style" in the VS Designer, but execute fine.
I suspect I may have enabled/disabled the "XP Visual Styles" option a couple of times, and perhaps initially created some forms when this was in different states... although I have no idea if this would have been the cause.
I really want this one form to be like all the others...
any ideas please? I am using VB in VS2010 (a bit old, but what I have to hand)
As I am quite new to VB so tell me what I can provide to help..
Many thanks,
David's comment has solved my immediate issue:
The single form appearing differently is indeed using Show() whereas the others are all ShowDialog(). There is no reason for me doing this, so I have changed it.
OK, this might be a bit of a generic and repeated non-code question but the latest article I can find about this is from over 2 years ago, so I'm wondering if there's been a fix or an update or maybe some clever dude out there has cracked the secret to curing this.
Every time I extend my screen while Excel (2007, 2010 or 2013) is running, and every time I unplug from an extension while Excel is running, my ActiveX controls are rendered useless, because with each click they either shrink or get bigger, depending on if I extended or unplugged.
This happens until I close the Excel application and restart it, unfortunately if I've saved it while the buttons are bigger/smaller they might end up stuck like that.
There is a thread here which has a bit code to help deal with the issue but quite frankly I'm hoping by now, two years later, someone has a slightly more efficient method of dealing with it.
I've took to using hyperlinks to run macros now but that's no good for my drop-boxes and things. And for me personally, I can just make sure I close Excel before extending/unplugging, but the real issue is I'm developing apps for people around the company and it's starting to cause problems with these damned buttons.
Does anyone know of a definitive fix for this yet?
If you only need ActiveX buttons to run macros, use Shapes instead. You can assign macros to a s shape's Click event. Right-click the shape and select "Assign Macro".
When working w/ a WinForm project in VS.NET 2015, our team has noticed that the mere act of opening a .VB form in the designer view (default action when double-clicking the file in Solution Explorer) will cause VS to modify many object properties in the "Windows Form Designer generated code" section of the actual .VB code-behind. It seems to be limited to the .Size and .Location properties for sometimes dozens or more of UI objects, always changing their X,Y coords just slightly.
Mind you we don't perform any action to drive this -- simply open the file (obtained from source-control and residing in the local solution/project) in VS.NET's form designer by double-clicking the file in Solution Explorer, and bam -- it has the "unsaved" asterisk and if you save it and compare to source control version you can see the modifications already made.
I couldn't find much on this. Is this a known behavior? Any idea why it does this? Kind of reminds me of the old days w/ MS FrontPage's designer view, and even the early days of ASP.NET in VS which would apply some HTML changes if you opened a WebForm in designer view, until they gave the option to disable that on a later release.
thanks for any input.
UPDATE: this appears to be continuing even with myself as the only editor of the .VB form in designer. various form elements are shifting their position very slightly. Here's a diff screenshot between my last check in and today, and I know I'm the only one editing:
...there are many like that. Always these two properties, always just a few pixels difference.
I don't have an specific answer for this, but since this drove us crazy a bit a few months ago with my team, while working on a WinForms project, I am glad to share my experience!
Every time someone opened any form on VS2015, it would ask other people who has the same solution open at that time to reload the code. We first thought the third party controls (at that time it was both DevExpress and Infragistics) we are using were re-generated on designed initialization - because they tend to do that a lot but then we realised this kept happening on forms that only contains .NET controls.
Now the funny part. This only happened to us on VS2015. We were using VS2013 before, without this annoying problem.
Long story short, then we realized the screens we are using have different DPIs, just like Cody Gray said. I am not absolutely sure if this was the reason, but since we started using TFS, obviously we don't have the problem anymore... Hope this helps somehow lol.
I've been working on a dashboard for the past several months in Excel 2010 and was nearing completion when we were upgraded to Excel 2013. I have experienced one issue that I'm completely stumped on...
I built a simple UI for the dashboard utilizing the first several rows of each sheet. Essentially, each sub-menu is hidden in a different row and only the appropriate rows are visible at any time. Is also allows the user to toggle on/off the various menus in/out of view without using a userform.
Prior to upgrading to 2013, it was very snappy and responsive, taking around 0.05 seconds each time a change was made in the UI. However, after migrating to Excel 2013 the UI is very sluggish. At first I thought it was a screenupdating issue because the screen was updating in bits and pieces - the labels, hidden rows, background color, etc would come in chunks, instead of all at once. I've ruled that out as a possibility.
I also tried disabling all of the annoying new animations that are baked into 2013. I tried all of the different methods I saw out there online - disabling the hardware graphics acceleration, turning off unnecessary animations in the ease of access center, etc. That too seems to have no effect.
After a full day of troubleshooting, I've noticed a sheet with just the UI and nothing else runs just as snappy as before. It's only when there are objects on the worksheet that things go wrong. From what I can tell, shapes and text boxes seem to have no effect on performance. Labels, both form control and Active X, seem to be the culprit.
I've noticed that the little bits of code I have for the UI continue to run at the same speed, but the screen will continue to change even after the procedure has run. This also totally perplexes me. I have tried changing the property from Move and Size with Cell to Free Floating and neither seems to make any difference. I've also tried changing things like Print Object, Locked, etc.
I'm totally stumped as to how to resolve this issue. It's definitely something endemic to 2013 as the exact same file runs without issue on 2010. If anyone has any suggestions they would be greatly appreciated.
UPDATE: Here is a link to a sample file highlighting the issue. Both work fine when tested on 2010.
https://www.dropbox.com/s/r2ep5bgyn6ohjph/2013%20Issue.xlsm?dl=0
Granted this is a stretch, but a little bit of research tells me that Excel 2013 has suffered a number of problems with ActiveX controls. There were several patches Microsoft has released, so I recommend you install them first and make sure your copy of Excel 2013 is completely up to date.
https://support.microsoft.com/en-us/kb/3025036
https://support.microsoft.com/en-us/kb/2956145
If this does not fix the problem, please let me know and I will remove this answer.
All, thanks for your help. I finally solved the issue I was having. I isolated the problem to Form Controls or ActiveX controls being visible at the time the code is run. I'm not sure why but the presence of either creates an issue. However, hiding all shapes prior to running the code and then unhiding them after resolves the issue. I did notice, however, this solution only works if the code does NOT turn screenupdating off prior to execution. I will post an updated file later when I have access to dropbox.
I've been thoroughly looking for a combobox alternative to use for Windows Phone development for a full 24 hours now. The best i've found so far was this
,which is perfectly fine, but i'm really looking for something to work with in Vb.net.
PS: I'm using Visual studio 2010 as my code editor
Anticipated thanks :)
The List Picker is the best alternative to a ComboBox.
You can get the List Picker by installing the Toolkit update: http://silverlight.codeplex.com/releases/view/55034
It doesn't matter whether you use VB or C#. The Listpicker is basically a control in XAML, in the design view.
The only difference would be the Databinding syntax in your code view.