vb.net

how to group fields in crystal reports using vb.net code?

I am using vb.net 2005. i am trying to set report groupings of a crystal report at runtime based on user defined options. MSDN says this: Dim FieldDef As FieldDefinition FieldDef = Report.Database.Tables.Item(0).Fields.Item(comboBox1().Text) Report.DataDefinition.Groups.Item(0).ConditionField = FieldDef but error shows invalid group...

Switch -Regex in Powershell.

$source |% { switch -regex ($_){ '\<'+$primaryKey+'\>(.+)\</'+$primaryKey+'\>' { $primaryKeyValue = $matches[1]; continue; } } I want to use dynamic key value with switch-regex, is that possible? ...

DATE concept in VB.NET

i have created VB.net project.In that i have two textbox,and two buttons button1-->submit button2-->Duedate textbox1 contain the current date My constraints is if i click button2(Duedate) than add 30 days to textbox1 date and assign that value into textbox2. How to achieve this? I want the result like as folloes If I give textbox...

custom tab controls in vb.net

i want to control my tab pages with custom buttons...now i want to hide my tabs from tab controls...how can i do that... ...

I am looking for information to make my windows form app self updating.

I would like to make my windows form app self updating when it starts. Where can I find good information for that? I am using Visual Studio 2008 VB.NET. I like the click once approach. With this application I have an access db as the backend datastore. When the application self updates how can I be sure the mdb file is not overwri...

VB restart form

I created a button and I need it to restart the form I have no idea how to work on the visual basic what should i write Private Sub Button2_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click End Sub ...

textbox accept only digits

Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles TextBox1.KeyPress Dim allowedChars As String = "0123456789$," If allowedChars.IndexOf(e.KeyChar) = -1 Then ' Invalid Character e.Handled = True End If End Sub this code accept only digits a...

Binding not writing to datasource on .NET Compact Framework Form -- works on Full Framework

I have a problem with a bound user control writing back to it's datasource on a NetCF forms application. The application is too complex to post code, so I made a toy version to show you. I create a form, usercontrol with a combobox, a class (testBind) and another class (TestLookup). I bind a property of the usercontrol ("value") to a ...

Webbrowser control and cookies

Hello! I have a webbrowser control in my program and what I want to do is to delete all the cookies stored in my computer. The problem is that for example I'm in some site, and then I decide I want to delete all the cookies, so I do it by the command "Kill()" but the problem is that the cookies remain and this site still can recognize me...

Why doesn't this (translated) VB.NET code work?

I had a piece of C# code converted, but the translated code isn't valid... Can somebody help out? C# <table> <% Html.Repeater<Hobby>("Hobbies", "row", "row-alt", (hobby, css) => { %> <tr class="<%= css %>"> <td><%= hobby.Title%></td> </tr> <% }); %> </table> VB <% Html.Repeater(of Hobby)(Model.Hobbies, "row", "row-alt", ...

.NET MVC Ajax Form - How do you hide it?

Ok, everything is 'functionally' working with what I am attempting to accomplish and once again, I am sure this is something dumb, but I cannot figure out how to do this one thing. I have an edit form for an entity, lets say a car. This 'car' can have 0 - many passengers. So on my edit form, I have all the fields for the car, then a l...

Custom Number Format in Crystal Report !

How can i format quantity value in crystal report like if the value is 5, then just show as 5. If the value is 5.25, then show as 5.25. So which format should i use for that? Thanks. ...

Tools to convert option strict off code into option strict on?

I have to take over a project written in vb.net, which contains more than 400k lines of code written in option strict off mode. I want to build it under option strict on first before I do anything else -- which maybe converting it into C#. I found there's thousands of lines of code raises compilation error, mostly are about implicit type...

whats the page life cycle in Ajax call in Asp.net?

whats the page life cycle in Ajax call in Asp.net? ...

grouping data from two dataset

hi, i've got a problem with dataset: I've got two dataset from two different server but they have the same columns. so it's like that: First DataSet : asset description make jobtype jan feb ... dec 0001 mine ik Acc 0 0 10 0002 yours ic Over 0 0 10 Second dataset : asset description make ...

How to Detect Trusted Connection in Crystal Reports using VB.NET?

I have some Crystal Reports connecting to a Sql Server db that I would like to detect whether the connection is trusted or whether I need to supply the log on info (reports are not supplied by me so I can't control the connect method). If I just blindly supply login credentials, it won't connect if it is a trusted connection. The follo...

Populate data Crystal Report from a query

hi big bro and sis, Im having a problem with how to display data using crystal report programmatically and need your help. Im using vb.net for my project. I have a form that I called reportFrm on which I put the CrystalReportViewer1. I also added the CrystalReport1.rpt to my project and the CrystalReport1.rpt contains a textbox called...

Problem with VisualBasic

I have a silly error that I am unable to resolve. I try to debug, and when I debug I get the following error ERROR "Visual Studio cannot start debugging because debut target 'C:\Documents and Settings\user\Desktop\programs6\HuricaneSeasonStatistics\bin\Debug\HuricaneStatistics.exe" is missing. Please build the project and...

Error In VB.Net code

I am getting the error "Format Exception was unhandled at "Do While objectReader.Peek <> -1 " and after. any help would be wonderful. 'Date: Class 03/20/2010 'Program Purpose: When code is executed data will be pulled from a text file 'that contains the named storms to find the average number of storms during the time 'period chose...

(VB or C#) Run app in system tray and listen to keyboard input even when the app is not in focus

I want to make an app which on loading sits in the system tray and even after I open another program (say notepad or vlc or anything) i.e. even when the app is not in focus and if I press "G" on my keyboard, the tray icon should show a tool tip - "key G is pressed". I have tried several codes but nothing works when the app goes out of fo...