|
csciwiz wrote: know how to use a thing called google?
Welcome to the club
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I have a form that its loading takes several seconds so I use a another form with Graphical objects as a splash . I call the latter one before the former .
it was shown but doesnot show graphical objects so it is a simple form .
please help me .
thanks in advanced . enMahdi.
|
|
|
|
|
We cannot help if we do not see the code behind that Form
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
I call the forms by these codes .
Dim frmsp As New Form1 ' may splash form with graphical objects
frmsp.MdiParent = Me
frmsp.Show()
Dim frmUser As New FrmUserInfo ' my form that its loading takes several seconds
frmUser.MdiParent = Me
frmUser.Show()
frmsp.Close() 'after showing the form I close the splash .
|
|
|
|
|
but why do you have to Parentme a Form. remove the Statemet in Both the Splash and the user form. you dont need that.A Splsh should not have a arent, it should appear for few seconds and disappear, i suggest you use timer control for it, after its done, mybe you can choose to display an MDI form ythat will be the parent of the forms,but remember that the Splash is out of memory, and dont lie to your selff thinking that if you have written .close method you have dispose it. and try running it again
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
thanks . my problem was solved .
can you help me if I want to crate a thread and run my second form in a different thread .
|
|
|
|
|
Hii
I want to get the version ( means office 2002,2003 or 2007) of office that are installed on my computer.
Please suggest.
Thanx
~Khatri Mitesh
|
|
|
|
|
Read through the registry and it should show you everything that is installed. How to do this in code is left as a programming exercise
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
how to converting windows application to server based application
i did a windows application in vb.net 2.0 which runs for every system
but now i want it to run thru server
i place my application in server
from it every user should access it and run the application
but it is asking the permissions
i dont have idea of converting this application to server based application
plz help me
thanks in advance
vijay
|
|
|
|
|
it is very intresting for me . please tell me how you do that convert .
it is my problem . I have winApps that I want to convert them to server based program .
thanks in advanced . enmahdi.
|
|
|
|
|
Guys
Lets Understand Something First before we call something a Server , Can you Define what is a Server for me, then i will understand why did you say you want to convert an application to be a Server. Please be very carefull with your terms
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
hai Vuyiswa Maseko
my company has a server which is maintained by system administrator
i developed a windows application in my system and created an exe.
now that exe i copied into few other systems and they r using it.
i dont want to do it
i put my exe in server and every user i will give a shortcut to it so that the application will run from server and source will be only one for the company
this is my problem
plz help me
thanks in advance
vijay
|
|
|
|
|
Where exactly ur problem is?
Best Regards
3ala2
|
|
|
|
|
hi
I understand your problem, n\but still even that exe reside in that machine you call a server it will be like the users are accessing from their machines, so what you need is a different Solution, you want your users to access your Application from the central point, then its fine. it can be done in exe(windows)but now you have to install the exe to every user, but there is an easy way, "WEB", you can create what you have created in Windows and di it to Web, and you will be sure that its been accessed centrally. look at my articles on N-tier, you can Convert them to Web and Create a Solution that you want.
Sorrry for answering you so late , am Sick
Hope this helps
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
hi Vuyiswa Maseko
how r u now
can i solve my problem thru .net remoting
i read u r article , is it 3 tier or n tier
what is differnce between 3 tier and n tier
presentation layer , bussiness layer , data layer
these are 3 differnt things thats y we call this as 3 tier
i understood like this
if it is wrong plz tell me ..
in n tier how many layers will be...
plz help me and give a solution to my problem
thanks in advance
vijay
|
|
|
|
|
hi vijaylumar
Am sorry to answer you so late. am very sick. but lets get back to your questions. The N-tier and 3 Tier is the same thing. but "N" means that you can use any number . that means 3 is the number of layers you have in your Application, so when we say N-tier,we include all types of designs that has 2 or more layers. and the way you read it from my article its correct,presentation layer , bussiness layer , data layer. in the N-tier you can have as many tiers as you want, but remember the reason we use N-Tier is to make the application code maintanable and be able to practise polynorphism.
To solve your problem, design the your solution exactly as my last Article part 2. if you need more answers reach me on skype "vuyiswamb"
hope i helped
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
I thing that the problem you are experincing is due to .NET Framework Security rights for the zone that you are trying to run from. Local servers (as apposed to Internet servers) usually reside in the Intranet zone.
You can adjust the each Zones security in the .Net configration, which is in Control Panel.
Also you will have to Strong Name your assemblies etc.
Steve Jowett
-------------------------
It is offen dangerous to try and see someone else's point of view, without proper training. Douglas Adams (Mostly Harmless)
|
|
|
|
|
how to get system name and user name in vb.net windows application
i m doing a windows application project in vb.net
first form is login form
in that form i want to store the current system name and user name of the system
plz help me
thanks in advance
vijay
|
|
|
|
|
Hiii
This Sample code returns all OS Detail of system.
Public Structure Env
Dim strVarName As String
Dim strValue As String
End Structure
Public Sub Main()
Dim intCtr, intPos As Integer
Dim strRetVal As String
Dim udtEnv As Env
intCtr = 1
Do
strRetVal = Environ(intCtr)
If strRetVal <> "" Then
intPos = InStr(1, strRetVal, "=")
udtEnv.strVarName = Left(strRetVal, intPos - 1)
udtEnv.strValue = Mid(strRetVal, intPos + 1)
MsgBox(udtEnv.strVarName & " " & udtEnv.strValue)
Else
Exit Do
End If
intCtr = intCtr + 1
Loop
End Sub
End Module
May be this solve your problem.
Thanx
~Khatri Mitesh
|
|
|
|
|
using WMI (Windows management Instrmentation ) you can get User & system related information easily.
you can get a lot of result if you Googling
you can also find a lot of articles on code Project
try 1 and 2
hope this helps
|
|
|
|
|
Hi,
easiest way is using SystemInformation.ComputerName and Environment.UserName
Isn't Google working where you are?
|
|
|
|
|
To Get the Systen name if Current Login name we use Environmental Variables, this is Simple.
String strloginname = Environment.UserName.ToString();
String strComputername = Environment.MachineName.ToString();
MessageBox.Show(strloginname);
MessageBox.Show(strComputername);
There are a lot of Answers in Google, you should teach your self to research before you ask.
Hope this Help
Vuyiswa Maseko,
Sorrow is Better than Laughter, it may Sadden your Face, but It sharpens your Understanding
VB.NET/SQL7/2000/2005
http://vuyiswamb.007ihost.com
http://Ecadre.007ihost.com
vuyiswam@tshwane.gov.za
|
|
|
|
|
Hi,
I have a main startup form called MainForm and I declared an instance of a class that launches a timers.timer that needs to update the MainForm controls (textboxes, progressBars,...) so I created the following delegate in MainForm:
Public Delegate Sub updateMainForm(ByRef neededChannel As Integer)
and the following call from the Timers.Timer.Elapsed event:
mainForm.Invoke(New mainForm.updateMainForm(AddressOf mainForm.determineIfKeepInAllOrIndividualChannel), New Object() {currentSTATE.CHANNEL})
and I get this error:
An error occurred creating the form. See Exception.InnerException for details. The error is: Current thread must be set to single thread apartment (STA) mode before OLE calls can be made. Ensure that your Main function has STAThreadAttribute marked on it.
I looked into the error and they recommended putting a <STATThread>_ in the Main function but I don't have a main function. If there is a better way to communicate with the MainForm from the Elapsed event then that is fine as well. I'm looking into starting the Timer from a BackgroundThread and keep it alive with Monitor so that I can utilize both ProgressChanged and WorkCompleted, but there must be a simpler way.
|
|
|
|
|
Hi,
seems like you are using some component (a separate DLL?) that needs the thread to be STA.
(what are those channels?)
A Timers.Timer will fire on a separate Thread of which you don't have control.
The easiest fix might be to switch to a Windows.Forms.Timer, which ticks on the GUI thread,
which by default is STA IIRC.
|
|
|
|
|
I looked into the error details and it came out with this:
System.InvalidOperationException was unhandled by user code
Message="An error occurred creating the form. See Exception.InnerException for details. The error is: Current thread must be set to single thread apartment (STA) mode before OLE calls can be made. Ensure that your Main function has STAThreadAttribute marked on it."
Source="ScienceProgram_v2"
StackTrace:
at ScienceProgram_v2.My.MyProject.MyForms.Create__Instance__[T](T Instance) in 17d14f5c-a337-4978-8281-53493378c1071.vb:line 190
at ScienceProgram_v2.My.MyProject.MyForms.get_mainForm()
at ScienceProgram_v2.startExperimentClass.STATUSupdate_MainForm() in G:\ProgrammingFolder\ScienceProgram\ScienceProgram_v2\neededClasses\startExperimentClass.vb:line 1229
at ScienceProgram_v2.startExperimentClass.endExperiment(Boolean& experimentCanceled) in G:\ProgrammingFolder\ScienceProgram\ScienceProgram_v2\neededClasses\startExperimentClass.vb:line 1190
at ScienceProgram_v2.startExperimentClass.sendCommands() in G:\ProgrammingFolder\ScienceProgram\ScienceProgram_v2\neededClasses\startExperimentClass.vb:line 1115
at ScienceProgram_v2.startExperimentClass.repeatingTimer_elapsed(Object source, ElapsedEventArgs e) in G:\ProgrammingFolder\ScienceProgram\ScienceProgram_v2\neededClasses\startExperimentClass.vb:line 1094
at System.Timers.Timer.MyTimerCallback(Object state)
InnerException: System.Threading.ThreadStateException
Message="Current thread must be set to single thread apartment (STA) mode before OLE calls can be made. Ensure that your Main function has STAThreadAttribute marked on it."
Source="System.Windows.Forms"
StackTrace:
at System.Windows.Forms.ComboBox.set_AutoCompleteSource(AutoCompleteSource value)
at ScienceProgram_v2.mainForm.InitializeComponent() in G:\ProgrammingFolder\ScienceProgram\ScienceProgram_v2\mainForm.Designer.vb:line 843
at ScienceProgram_v2.mainForm..ctor()
InnerException:
Maybe something here?
The only DLLs that I use are the Krypton Toolkit and the DevExpress Xtra editors. Everything else is standard Microsfot stuff.
-Max
modified on Monday, July 14, 2008 4:07 AM
|
|
|
|