|
Oops, sorry. I didn't know.
|
|
|
|
|
I am populating a datagrid using threads.
Sometimes, the datagrid display gets distorted with double scrollbars appearing. and if click on the grid esp. the scrollbars, you get anyone of following 2 exceptions.
Try Catch blocks exist everywhere but the exception cant be trapped.
On clicking on Break(on the exception msgbox), the location of exception occurence is the begininng of the form class.
Two exceptions:
1. System.Runtime.InteropServices.SEHException' occurred in
system.windows.forms.dll
Additional information: External component has thrown an exception.
2.An unhandled exception of type 'System.NullReferenceException' occurred in
Unknown Module.
Additional information: Object reference not set to an instance of an object.
Need help urgently.
|
|
|
|
|
genius123 wrote:
I am populating a datagrid using threads.
You can only manipulate controls from the primary thread. The .NET framework provides the Control.Invoke method to ease this. Check this MSDN article[^] to further details.
I see dead pixels
Yes, even I am blogging now!
|
|
|
|
|
Hi
Thanks But have already implemented the me.begininvoke method.
It works fine but still sometimes ,I get these exceptions.
for reasons unknown.
Regards,
genius123
|
|
|
|
|
Dear guys
i have one problem in .net frame work designing
i have designed the winform in one mechine,and i implemented in another mechine ,but when i will
get the same design in another mechine the design will be changed like it gets big fonts and unsize to screen.how can i keep the designing settings in all mechines same and how can i write and get the registry for app settings
|
|
|
|
|
It sounds like you have a screen resolution problem or in the advanced settings of the screen properties the font is set larger. Its not your program its WINDOWS.
1. Out of clutter, find simplicity.
2. From discord, find harmony.
3. In the middle of difficulty lies opportunity.
Albert Einstein
three rules of work
|
|
|
|
|
dear guy
I have checked with resolution ,but thats not a problem,if resolution problem only the font is get bigger or smaller but my case the total control gets bigger or smaller in forms,in design time i have designed control is very compact in form but in another mechine it will not convenient fit
|
|
|
|
|
|
ThanX
Dear het ,
I have check with the font settings in two systems ,both are same (90dpi) so thats not the problem,only one diffrence is the screen Area (my developement system screen resolution is 800 * 600) but my designing system screen resolution is 1024 * 768) but when i will change the screen resolution,it will get more smaller all application in windows OS),actually in my application controls size only gets big size rather than designing mechine),for example(if Label1 size is 400*56 on design time in designing mechine then it will comes to development mechine it comes to 556* 67)
so that is problem in changing this setting in client side.now my question is how can we adjust our application's display seetings depends on screen display settings.
|
|
|
|
|
|
How to Find last Sundays Date using VB.net Code ?
Sagar J
|
|
|
|
|
First find the Sunday using Weekdayname and then if it is TRUE,then Stored the date nad minus 7 from it then you will get the date and using that day in the Weekdayname you can verify that whether it was sunday or not.
|
|
|
|
|
Uhm, I'm not exactly sure what Zafeer is saying, but here's some code that works:
Dim lastSunday As Date
lastSunday = DateAdd("d", -Weekday(Now), Now)
|
|
|
|
|
Hi Ppl
I am trying to create a service in ASP.net. This service would be called from command line and passed parameters (like the at service (MsTask)).
For example on the command prompt if I write 'myService param1'. Then the service should do something (like opening apps, sending logs, mails etc. in background)depending upon the value of param1.
I have been able to write, compile, build and deploy a basic service that logs some stuff. Thanx to the simple service wizard and even simpler tutorials on the net.
I have not been able to implement a mechanism where in I could accept stuff from command line and then open simple win32 apps based on the parameters.
Please help. Links to tutorials on this will also be of great help.
TIA
|
|
|
|
|
To Debug ur service , got0 project properties---Configuration Properties---debugging ==input ur parameters in the command line argument ...or after making build ..make a bat file conating the exe name & parametres . And Windows services has facility to run this service Automatically. But for this u have to shedule ur job which is to be run..I hope u can get idea to solve this problem.
Sagar
|
|
|
|
|
ASP.NET?? I doubt it...
You'll need to write a second application (Console App it you want) that can talk to your service. You can use .NET Remoting for this. This second app will just provide the interface for you to send your commands to the service, and maybe some return data.
In order for your service to be able to launch an application so you can SEE it, you're service has to be tagged "Allow interaction with desktop". You can do this in the Services control panel. If this is not done, the service will launch applications on a desktop that you cannot see.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I ahve a textbox control array. i am able to loop through each textbox but i am not able to get the value written in the textbox.
Dim o As Object
Dim ctrl As New System.Windows.Forms.TextBox
For Each o In Me.Controls
If o.GetType Is ctrl.GetType Then
s = ctrl.Text
End If
Next
|
|
|
|
|
may be this will work.
create another sub for textchanged for your text box and dim somthing as a string
dim modtext as string
modtext = ctrl.text
you could then move it anywhere through your program
1. Out of clutter, find simplicity.
2. From discord, find harmony.
3. In the middle of difficulty lies opportunity.
Albert Einstein
three rules of work
|
|
|
|
|
Thanx, but i have used an array and put the textboxes in the array. and now i am getting the text
|
|
|
|
|
a textbox contains strings, so you'll have to cast the values using Cxxx() for example, where xxx is the type you'd like to cast to (CInt() for example)
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
Actaully i need to print my Bill in on the top of A4 papaer size, but every time i press the button print, the printer will print my bill in middle and only printing half only. I try to print again, but my printer will continued print again the half bill for my 1st printing.
how can i reset again for printing code?
Steve
|
|
|
|
|
Hi,
i just want to know the procedure for creating an excel sheet using vb.net where data is to be retrived from database
|
|
|
|
|
Hi Nidhishri
I guess this code snippet shoulld solve your problem.
Dim ExcelApp As New Excel.Application
Dim ExcelWorkBook As Excel.Workbook
ExcelWorkBook = ExcelApp.Workbooks.Add
Dim TemplateSheet As New Excel.Worksheet
TemplateSheet = ExcelWorkBook.Sheets.Add
TemplateSheet.Name="SQLDATA"
Dim SQLData As New SqlDataAdapter("YOUR QUERY FOR GETTING DATA",DatabaseConnection)
SQLDATA.SelectCommand.Parameters.Add("PARAMETERS IF REQUIRED)
SQLDATA.SelectCommand.Parameters(0).Value = "VALUES FOR PARAMETERS"
Dim Myrow As DataRow
Dim SQLdatatable As New DataTable
Try
SQLDATA.Fill(EquationNormDataTable)
Catch ex As Exception
End Try
Dim StartRowForFile As Integer = 1
StartRowForFile += 1
For Each Myrow In EquationNormDataTable.Rows
'Now u can iterate through each rows of the table and populate data in an excel sheet
Dim ColCount As Integer = 1
For ColCount = 1 To 3
TemplateSheet.Cells(StartRowForFile, ColCount).Value = Myrow(ColCount - 1)
Next
StartRowForFile += 1
Next
'now u can save the excel file
ExcelWorkBook.SaveAs(""FILENAME WITH COMPLETE PATH")
Mandar Patankar
Microsoft Certified professional
|
|
|
|
|
Can we use more than one dataset on one crystal report.
A sample code will be more useful.
|
|
|
|
|
You mean more than one database or more than one database table? The answer to these I know is yes
1. Out of clutter, find simplicity.
2. From discord, find harmony.
3. In the middle of difficulty lies opportunity.
Albert Einstein
three rules of work
|
|
|
|