646 Posted Topics

Member Avatar for jhonnyboy

Multi column listbox doesn't actually show items in multiple columns. It "wraps" items to the next column when you add them and the number of the items reaches the listbox's height. If you want to show items in two columns, you'll have to use some grid control or listview control. …

Member Avatar for danprash
0
8K
Member Avatar for datajaya_ap

You have to get the qualified type name first i.e. get the right namespace. Then you can create an instance of that name and convert it to a form (since you know it's a form)[CODE=VB.NET] Dim objForm As Form Dim sValue As String Dim FullTypeName As String Dim FormInstanceType As …

Member Avatar for alifax89
0
2K
Member Avatar for willlotr

Why do you use For Next loop??? Here's how I would do it in .NET way: [CODE]Dim Gen As System.Random Gen = New System.Random(My.Computer.Clock.TickCount) Txtrandom.Text = Gen.Next(1, 101).ToString[/CODE] A few points: - I would use computer clock's TickCount as a seed number - Next(1, 101) method generates integers from 1 …

Member Avatar for G_Waddell
0
878
Member Avatar for katrinavizconde

You can download straight from the Microsoft (you should find VB.NET 2005 EE also from there): [URL="http://www.microsoft.com/express/vb/"]Visual Basic 2008 Express Edition[/URL] and that's the only [B]legally distributed[/B] free version of VB.NET. HTH

Member Avatar for botitog
0
54
Member Avatar for TIP.Synergy

Here's the simplest way. This calculates the sum of the fourth column [CODE=VB.NET]Dim TotalSum As Double = 0 Dim TempNode As ListViewItem For Each TempNode In ListView1.Items TotalSum += CDbl(TempNode.SubItems.Item(3).Text) Next MsgBox(TotalSum) ' Debug [/CODE]and it assumes that each item is a valid number. A bit safer solutions uses TryParse …

Member Avatar for N.E.Y.O-01
0
6K
Member Avatar for ms061210

Does it work if you add a semicolon after User ID: `"Provider=MSDAORA;Data Source=xe;Persist SecurityInfo=True;Password=me;User ID=cj;"`

Member Avatar for poojavb
0
312
Member Avatar for chocomilk
Member Avatar for chocomilk
0
184
Member Avatar for moone009

Here's a thread-safe way to assign text to the (UI-thread) control: Delegate Sub SetTextCallback(newString As String) Private Sub SetText(ByVal newString As String) ' Calling from another thread? -> Use delegate If Me.TextBox1.InvokeRequired Then Dim d As New SetTextCallback(AddressOf SetText) ' Execute delegate in the UI thread, pass args as an …

Member Avatar for moone009
0
5K
Member Avatar for monching

In the line 17 you set a connection object to a command object: `myCommand.Connection = conn` In the line 18 you create a new command object which destroys previous command instance: `myCommand = New MySqlCommand(comm)` and this new command object doesn't have an open connection. Solution: swap lines 17 and …

Member Avatar for monching
0
472
Member Avatar for MeSam0804

First, use Try...Catch...End Try to catch the error. It helps to solve the problem. And secondly, everything you do with the web is always more or less error prone. Basic problem in your code is understanding how communication works between server and the client. In the code above you **request** …

Member Avatar for Reverend Jim
0
3K
Member Avatar for yoavgold

[QUOTE]Intellisense says that Interface "outlook.item" cannot be indexed because it has not default property.[/QUOTE]I believe it said "[B]outlook.items[/B]". Yes, you have to use Item property of Outlook.Items collection. I partly rewrote the OP's code. Simply commented out some lines, added few properties for the appointment and fixed the error mentioned …

Member Avatar for Begginnerdev
-1
2K
Member Avatar for geeky123

Add a reference to System.IO namespace. Before saving your Excel file (line 155) check if the file already exists and if it does, just delete the previous file: if (File.Exists("c:\\test\\test.xls")) File.Delete("c:\\test\\test.xls");

Member Avatar for geric823
0
5K
Member Avatar for JOSheaIV

I don't see any point for using threading in this code. I wrote a simple example how to get the content of the final page i.e. not HTML code. This code uses a button to start loading, a label to show what's happening and a multiline textbox where I dump …

Member Avatar for JOSheaIV
0
296
Member Avatar for me_coolvibes

Hi Coolvibes! Do not post the same question to multiple forums. This is a VB.NET forum and you're using VB6 so [Visual Basic 4 / 5 / 6](http://www.daniweb.com/software-development/visual-basic-4-5-6/4) forum, where you ask the same question is the right place for your question.

Member Avatar for Teme64
0
88
Member Avatar for nav010

If you use a short delay, user won't notice any freezing. [CODE=VB.NET]Threading.Thread.CurrentThread.Sleep(1000)[/CODE] and the parameter is in milliseconds. Above code causes one second delay.

Member Avatar for mad4x4
0
8K
Member Avatar for wenbnet

I'm not sure what you mean by 'window' but you maximize forms by setting their WindowState property: [CODE=VB.NET]Private Sub Form1_DoubleClick(sender As Object, e As System.EventArgs) Handles Me.DoubleClick Me.WindowState = FormWindowState.Maximized End Sub[/CODE]Now when you double-click your form called Form1, it changes it's WindowState to Maximized. HTH

Member Avatar for poojavb
1
486
Member Avatar for jps447

There's never a 100% secure solution. First, do not store password in plain text. Use some hash function to calculate hashed value of the password and store this hashed value. Some methods are MD5, SHA1 or simple CRC32 etc. You'll find sample code with Google. So when the user gives …

Member Avatar for billyakaeaster
0
2K
Member Avatar for taylormsj

There's no reason to convert a datetime value to a string. Use Hour and Minute properties instead [CODE=VB.NET]Dim day As String = Format(Today, "dddd") Dim time As Date Dim CurrHour As Integer Dim CurrMinute As Integer time = DateTime.Now CurrHour = time.Hour ' Get current hour value CurrMinute = time.Minute …

Member Avatar for oderbang
0
9K
Member Avatar for spinnaret

100 ms is a quite short time to application load. Instead of [ICODE]System.Threading.Thread.Sleep(100)[/ICODE] you may try [ICODE]procSungard.WaitForInputIdle(10000)[/ICODE]. You'll have a higher chances that the app is actually loaded, UI running and thus app is processing message queue. Setting focus requires API calls. Get handle to application window: [ICODE]Public Declare Function …

Member Avatar for eryrasa
0
2K
Member Avatar for Begginnerdev

Here's how you create your panel at run time [CODE=VB.NET]Dim newPanel As Panel newPanel = New Panel() ' Set "child" panel's properties '... ' Set a unique name for each panel newPanel.Name = "ChildPanel1" ' Set Click event handler AddHandler newPanel.Click, AddressOf childPanelClick ' Add panel to main panel's controls …

Member Avatar for Begginnerdev
0
165
Member Avatar for GAiXz

[QUOTE]i'm getting an error..[/QUOTE] Next time post the error message. You set the formats like this [CODE=VB.NET] DateTimePicker1.Format = DateTimePickerFormat.Custom DateTimePicker1.CustomFormat = "dd-MMM-yyyy" DateTimePicker2.Format = DateTimePickerFormat.Custom DateTimePicker2.CustomFormat = "yyyy"[/CODE] then you trap DateTimePicker2's ValueChanged event, right? [CODE=VB.NET]Private Sub DateTimePicker2_ValueChanged(sender As Object, e As System.EventArgs) Handles DateTimePicker2.ValueChanged ' Dim newYear As …

Member Avatar for codeorder
0
2K
Member Avatar for Begginnerdev

I've posted this link a few times before here in DaniWeb: [URL="http://www.developerfusion.com/tools/convert/csharp-to-vb/"]Convert C# to VB.NET[/URL] See if it helps you.

Member Avatar for Begginnerdev
0
363
Member Avatar for jayawant.sawant

[QUOTE]Window.document it is the property in vb 6.0[/QUOTE] No it isn't. It's the property of a HTML page loaded in the webbrowser control. In VB.NET WebBrowser.Document [QUOTE]Gets the Document object that represents the hosted HTML page[/QUOTE] and that's the same as what Window.document did in VB6. WebBrowser.Document has GetElementById() method …

Member Avatar for Teme64
0
237
Member Avatar for J0hn30

If you want to prevent user to doing something you usually can achieve that with (local) group policy objects. You edit LGPOs with Group Policy Editor, but GPOs in fact modify your registry just like you thought. You can [URL="http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=25250"]download[/URL] available Group Policy settings and check if you find those …

Member Avatar for J0hn30
0
2K
Member Avatar for moone009

You're comparing file's name to a date. The comparison should be [CODE=VB.NET]If fri.LastAccessTime > sDay Then[/CODE] You should also move [ICODE]FSO = CreateObject("scripting.filesystemobject")[/ICODE] before [ICODE]For Each fri In fiArr[/ICODE] because now your loop creates a new object in each iteration. After the loop (line [ICODE]Next fri[/ICODE]) dispose the filesystem object …

Member Avatar for Teme64
0
200
Member Avatar for mansi sharma

If you just want to download videos, there are some add-ons for Firefox (maybe for IE too) that can download streamed videos. If you really want to do that with VB.NET, you can't use any simple DownloadFile method because the videos are streamed. Streamed videos are, however, saved to browser's …

Member Avatar for johnsmithtwh
0
117
Member Avatar for Momerath

Skatamatic, 64-bit version has development tools and 32-bit version doesn't. Pseudorandom21, no, it doesn't even install on VMware VM. The problem is with Win8 HAL.

Member Avatar for Pjieter
1
336
Member Avatar for low1988

[QUOTE]Could it be implemented on the vb.net or i should do it on C#?[/QUOTE] Doesn't make any difference. Both will do the job. [QUOTE]and analyse the file signature[/QUOTE] What do you mean by file signature? Something (a hash value) you've pre-calculated from the files in a file system and associated …

Member Avatar for akkbkht
0
1,000
Member Avatar for markdean.expres

[QUOTE]Is this possible i the first place?[/QUOTE] Yes it is. [QUOTE]If yes, then how?[/QUOTE] Here's a subroutine from my crapbox. The extra features you'll get are: restrict files with file creation date and/or with file size. I was too lazy to take those off, but you can do it by …

Member Avatar for keyboardxtreme
0
152
Member Avatar for markdean.expres

[QUOTE]is this possible?[/QUOTE] Yes it is. First, here's a very straightforward solution for the search. You need a list box, text box and a button. Type a search-term in the text box and press the button. [CODE=VB.NET]Private Sub SearchListBox(ByVal searchTerm As String) ' Fill test data ListBox1.Items.Clear() ListBox1.Items.Add("Apple") ListBox1.Items.Add("Banana") ListBox1.Items.Add("Guava") …

Member Avatar for markdean.expres
0
6K
Member Avatar for Traicey

What programming language you're using? If VB.NEt, you may try Daniweb's site search. I've answered the same or at least very similar question few times. A pretty good search phrase is "image SQL Server VB.NET" (without quotes).

Member Avatar for yassooo
0
185
Member Avatar for dan555

I'm not familiar with FoxPro but DESC is related to ORDER BY. With "standard" syntax the query should be [CODE]SELECT product.code, ullage.counttotal FROM product LEFT JOIN ullage ON product.code = ullage.code ORDER BY product.code DESC[/CODE] HTH

Member Avatar for Teme64
0
192
Member Avatar for RedexProGamma

There's not such a method in StreamReader class that reads a specific line, see [URL="http://msdn.microsoft.com/en-us/library/system.io.streamreader.readline.aspx"]StreamReader.ReadLine Method[/URL]. Instead, if you need a specific line, read the lines to a string array and get the specific line from the array. Another solution would be to use counter variable for the lines: [CODE=VB.NET]Dim …

Member Avatar for RedexProGamma
0
191
Member Avatar for RenanLazarotto

[QUOTE]The .ico file is 344Kb larger[/QUOTE] That's not a Windows Icon File. Not quite sure but X Windows system has icons of that size. If you want a Windows ico file with a few Kb, try to convert file. If you don't have a suitable application, try open source [URL="http://www.gimp.org/"]GIMP[/URL]. …

Member Avatar for RenanLazarotto
0
134
Member Avatar for juanmikael

To make it really unique you would have to come up with a new compression algorithm. See [URL="http://en.wikipedia.org/wiki/Data_compression"]Data compression[/URL] what exists and come up with a new idea. After that you have to implement the algorithm and compare it's "efficiency" with other methods/applications, like 7z, WinZip, WinRAR etc. I don't …

Member Avatar for Teme64
0
235
Member Avatar for user543820

If you're using a namespace [ICODE]using Microsoft.Office.Interop.Excel;[/ICODE] you can't refer to types as [ICODE]Excel.Application[/ICODE] or [ICODE]Excel.Workbook[/ICODE]. You use just Application and Workbook. Application is a reserved word in .NET. Use _Application or Microsoft.Office.Interop.Excel.Application instead. HTH

Member Avatar for Teme64
0
178
Member Avatar for nav010

Hi rohitgeek! Please start a new thread for your question. You're not answering or solving the original question about pop-up windows. You'll get answers to your question when everybody sees what [U]you[/U] are asking :) And gomathinayagam could do the same.

Member Avatar for imawesome511
0
16K
Member Avatar for glut

Here's the documentation of [URL="http://msdn.microsoft.com/en-us/library/system.windows.forms.treeview.selectednode.aspx"]TreeView.SelectedNode[/URL]. Your ReadFile function works just fine, so the problem has to be in the passed argument (filePath). You could add following lines to the beginning of ReadFile: [CODE=C#]if (filePath == null) MessageBox.Show("FilePth has null value"); if (!File.Exists(filePath)) MessageBox.Show("File: '" + filePath + "' not found");[/CODE] …

Member Avatar for Mitja Bonca
0
175
Member Avatar for chellemits

Don't try to save leading zeroes. That's just a way to display, not to store, numbers 1,2,3 etc. and you already know how to use PadLeft(5, "0") function. HTH

Member Avatar for Teme64
0
241
Member Avatar for tuquoise

Your code [U]may[/U] exit the loop, but [ICODE]StrOut = txtAnswer.Text[/ICODE] should probably be [ICODE]txtAnswer.Text = StrOut[/ICODE]. HTH

Member Avatar for tuquoise
0
417
Member Avatar for Sophiron

You use plain [ICODE]oSelection.EndKey()[/ICODE] which moves to the end of the line. EndKey's first parameter is the units where to move, in your case to the end of the document: [CODE=VB.NET]Dim oWord As Word.Application Dim oDoc As Word.Document Dim oDoc2 As Word.Document Dim oDoc3 As Word.Document Dim oSelection As Word.Selection …

Member Avatar for Teme64
0
193
Member Avatar for gumbum8

Move line 26. [ICODE]List<string> temp = new List<string>();[/ICODE] to line 29. and drop [ICODE]temp.Clear();[/ICODE] HTH

Member Avatar for gumbum8
0
189
Member Avatar for cheiL

You could take timespan object by subtracting start date from end date. Now you would have "a single datetime value". But if you need to get back either start date or the end date from the timespan, you can't do it. In that case the only solution is to add …

Member Avatar for cheiL
0
124
Member Avatar for AndyPants

With a PNG image, open image file in your graphics program and set palette transparency i.e. the "background" color of X and O to transparent in the images palette. You should be able to do this with any graphics application. If you have also X and O images with non-transparent …

Member Avatar for AndyPants
0
489
Member Avatar for lxXTaCoXxl

Here's a link to code to extract icon: [URL="http://www.codeguru.com/csharp/csharp/cs_misc/icons/article.php/c4261"]Getting Associated Icons Using C#[/URL]. I still use that code. To drag and drop files: [URL="http://codehill.com/2009/06/drag-and-drop-files-to-a-c-application/"]Drag And Drop Files to a C# Application[/URL]. I found that with some googling and it seemed a very simple and easy to understand example. Since the …

Member Avatar for Teme64
0
152
Member Avatar for fredw300

You did get this [ICODE]new Form2.show();[/ICODE] through the compiler??? Anyway, this is how it should be done [CODE=C#]for (int i = 0; i < numOfCopies; i++) { Form2 newForm; newForm = new Form2(); newForm.Show(); }[/CODE]

Member Avatar for fredw300
0
127
Member Avatar for Seten

[QUOTE]Do you have an idea how is the best way to overcome this problem?[/QUOTE] Not at this moment :) I have a little doubt about Active Directory's part in your problem. Have you tried changing log files ACL?

Member Avatar for Seten
0
202
Member Avatar for jianhe99

[QUOTE]..i try this but cant work Call lnkFromPR_LinkClicked(sender, e) [/QUOTE] I'm sure that e is of type System.EventArgs but now it should be of type LinkLabelLinkClickedEventArgs Here's one way to do it [CODE=VB.NET]' Get selected link Dim thisLink As LinkLabel.Link ' Just take the first link thisLink = LinkLabel1.Links.Item(0) ' …

Member Avatar for jianhe99
0
95
Member Avatar for Jaydenn

[QUOTE]I know there must be a quicker and more efficient way of fixing this problem[/QUOTE] I'm afraid there isn't. In fact, if you suspect user to change system clock, you'll always have to check NTP. .NET doesn't have any built-in support for NTP but I found [URL="http://www.codeproject.com/KB/datetime/SNTPClient.aspx"]An SNTP Client for …

Member Avatar for Teme64
0
101
Member Avatar for wissam.ashkar

Replace line 59: [CODE=C#]cmd = null; cmd = new OleDbCommand(); cmd.Connection = MyConnection.con; cmd.CommandText = "INSERT INTO supplier...[/CODE] HTH

Member Avatar for wissam.ashkar
0
245

The End.