|
Have you considered a good book? You could also try the Beginners Portal[^] on MSDN.
Bastard Programmer from Hell
|
|
|
|
|
Eddy Vluggen wrote: Have you considered a good book?
Reading a good book rather than learning VB.NET, good suggestion!
Luc Pattyn [My Articles] Nil Volentibus Arduum
Fed up by FireFox memory leaks I switched to Opera and now CP doesn't perform its paste magic, so links will not be offered. Sorry.
|
|
|
|
|
Pratchett is always a good suggestion
|
|
|
|
|
you can contact me on ag99110011@gmail.com for learning vb.net programming.
ag99110011
|
|
|
|
|
|
thank's Clark for the link..
i'd love to start learning vb.net from the beginning..
|
|
|
|
|
|
Hi mates,
I have a website and my boss wants to have 3 language.
In a login page there will be a dropdown list (English,Japanese,Chinese)
after the password box.
The problem is, I don't know how to code it,
anyone have idea would be much appreciated.
They want to put in excel file.
So that they can easily add/modify a word or sentence.
I've read and search in google but result is only using
the .resx files.
Thanks in advance.
C# コードMicrosoft End User
2000-2008
「「「「「「「「「「「「「「「「「「「「「「「「「「「「
The best things in life are free
」」」」」」」」」」」」」」」」」」」」」」」」」」」」
|
|
|
|
|
C#Coudou wrote: I've read and search in google but result is only using the .resx files.
That's the easiest way; see the topic Multilingual content in Web Pages[^].
Making an interface to Excel will be extra work, complicating the issue. I suggest you start by introducing multilingual content, and worry about editing the languages later on.
Bastard Programmer from Hell
|
|
|
|
|
|
I am using Microsoft.Office.Interop.Excel to open, read, and write to an excel workbook in VB.net. How do I figure out if a workbook is already open?
|
|
|
|
|
Maybe this might help ...
Dim gExcelApp As New Excel.Application
Dim i As Integer
gExcelApp.Visible = True
gExcelApp.WindowState = Excel.XlWindowState.xlNormal
gExcelApp.Workbooks.Open("C:\Temp\Test.xls", , True)
For i = 1 To gExcelApp.Workbooks.Count
If (gExcelApp.Workbooks(i).Name.Equals("test.xls")) Then
Debug.Print("Already open")
End If
Next
|
|
|
|
|
Thanks David. This worked for me when the workbook was open with the current excel app. Is there a way I can find out if it is open under another excel app? Put another way, is there a way I can find all running excel apps?
|
|
|
|
|
Sounds like you want to look at other running applications on the current machine and see if they have the workbook open.
Hmmm ... sorry, I don't have an answer for you on that.
|
|
|
|
|
I would like to implement a check before / after images of the effects to which I apply, in a winform in vb.net.
some help?
overlay two images and see the other one hiding?
This is an example I wish I could play javscript in vb.net.
http://www.catchmyfame.com/2009/06/25/jquery-beforeafter-plugin/
Thanks for any response.
modified 22-Jan-12 13:15pm.
|
|
|
|
|
Assuming you have two images of identical size, I would use a Panel (of that same size) and a Scrollbar below it, then paint part of both images to the panel in its Paint handler depending on the scrollbar's value. And invalidate the Panel when the scrollbar's value gets changed. Should be straightforward.
|
|
|
|
|
paint only a portion of the image? array of pixels?
|
|
|
|
|
I suggest you read up on Graphics.DrawImage() , it is all there.
|
|
|
|
|
Thanks, it's a good start ...
|
|
|
|
|
Hi,
On 1 (office) computer I get the error
Errormessage:Invoke of BeginInvoke kan niet op een besturingselement worden aangeroepen tot de vensterkoppeling is gemaakt. bij System.Windows.Forms.Control.WaitForWaitHandle(WaitHandle waitHandle) bij System.Windows.Forms.Control.MarshaledInvoke(Control caller, Delegate method, Object[] args, Boolean synchronous) bij System.Windows.Forms.Control.Invoke(Delegate method, Object[] args) bij System.Windows.Forms.Control.Invoke(Delegate method) bij Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.HideSplashScreen() bij Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.MainFormLoadingDone(Object sender, EventArgs e) bij System.EventHandler.Invoke(Object sender, EventArgs e) bij System.Windows.Forms.Form.OnLoad(EventArgs e) bij System.Windows.Forms.Form.OnCreateControl() bij System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) bij System.Windows.Forms.Control.CreateControl() bij System.Windows.Forms.Control.WmShowWindow(Message m) bij System.Windows.Forms.Control.WndProc(Message m) bij System.Windows.Forms.ScrollableControl.WndProc(Message m) bij System.Windows.Forms.ContainerControl.WndProc(Message m) bij System.Windows.Forms.Form.WmShowWindow(Message m) bij System.Windows.Forms.Form.WndProc(Message m) bij System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message m) bij System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message m) bij System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
on starting the program. The second time I start the program it works fine.
Has someone an idee what this all means? and how to solve it
On my own pcs it works fine
Jan
|
|
|
|
|
Every WinForms Control (inluding a Form) has a Handle property which is used internally (it is to hold the HWND handle); when the control hasn't been sufficiently initialized, the Handle value is still undefined and some operations can't be performed yet. I don't remember having ever had the problem, however the solution should be:
- postpone special operations, maybe move some first-use code from the Form's constructor to its Load or Shown event;
- or: inside the Form constructor, force the handle to be generated, by executing something like IntPtr dummyHandle=myControl.Handle .
From the stack traceback, it seems like you may have a problem with a splash screen. I don' know for sure, and you might be using either a special VB one or one of your own, I do know I have seen lots of bad splash implementations: all control operations should run on the main thread, and that holds true for the splash screen as well.
BTW: if you do something like (this is C$, don't know how it gets packaged in VB):
Splash splash=new Splash();
splash.Show();
MainForm form=new MainForm();
form.Splash=spash;
Application.Run(form);
then:
1) everything runs on the main thread;
2) the splash is visible as soon as possible;
3) the splash is fully initialized before the MainForm constructor might access it.
VB may offer its own implementation of a splash, and if so I don't know whether it is any good.
|
|
|
|
|
On the mainform and on the splashscreen are no controls that I have made. all basic stuff
The spash is handled by vb itself.
It still confuses me tha this only happend by my office computer, but not always, and not on other computers.
Jan
|
|
|
|
|
I am in the process of converting a project from vb6 to vb.net. Code is now re-written and I can run it.
The first thing I see is that when I select and option to load a form from my main screen, I see lots of animation which I assume to be me moving my controls around, before the form clears itself up and looks like I wanted it to.
I have anywhere from 100 to 300 text boxes, labels buttons and so-on that I arrange based on the system configuration. This is all done dynamically in code as the form loads because they can be vertical, horizontal, different quantities and so-on based on what type of hardware it is connected to.
I tried making the form not visible in the load event but no luck, any other suggestions?
It was very clean in VB6
No-e
|
|
|
|
|
Frankly, I wouldn't be doing what you described. 300 controls on a form is excessive and takes forever to render. Rearranging them from their initial layout just makes things worse.
I'd probably be skipping the textboxes all together unless these values can be updated.
In either case, I'd look at compartmentalizing these in logical groups and creating controls or usercontrols that handle/rearrange/draw themselves depending on the data that's passed to them. You could then create instances of only those controls you need at runtime.
Form.Load only happens the first time a form is displayed and happens just before it's shown. You'll get another event, VisibleChanged, when that happens.
The earliest event you get from a form is HandleCreated.
|
|
|
|
|
InterOp to LockWindowUpdate API could be used to disable drawing for a sec.
Bastard Programmer from Hell
|
|
|
|