Wednesday, February 20, 2008

Let's Talk about .. InfoPath 2007-Display the Current User in the form

Last week, I found the way to display the username of the user who logged in and open this InfoPath form. I found the way in this article..

Itay Shakury's article, InfoPath - Get the current user without writing code : http://blogs.microsoft.co.il/blogs/itaysk/archive/2007/04/05/InfoPath-_2D00_-Get-the-current-user-without-writing-code.aspx

This article suggests to get the current username via the web service UserProfileService at

http://ServerName/_vti_bin/UserProfileService.asmx

Let's Talk about .. Visual Studio 2005-String Compare in VB.Net

I am familiar with C more than VB, I just know that to compare two strings, we can use

"[string1]".ToString() = "[string2]"

Let's Talk about .. SQL Server 2005-mySQLConnection

The syntax if my mySQLConnection normally is

mySqlConnection = New SqlClient.SqlConnection("Data Source=[myServerName];Database=[myDatabaseName];Integrated Security=false;User ID=[username];Password=[password]")

Integrated Security:
True = No need username&password
False = Need username&password

Tuesday, February 19, 2008

Let's Talk about .. MOSS2007-Where is the Virtual Directories?

The Virtual Directories directories is located at C:\Inetpub\wwwroot\wss\VirtualDirectories in the MOSS Server

Monday, February 18, 2008

Let's Talk about .. InfoPath 2007-Error Request for the permission of type 'System.Data.SqlClient.SqlClientPermission failed

Today I connected my InfoPath form to the SQL database, but when I ran it, I got the error "Request for the permission of type 'System.Data.SqlClient.SqlClientPermission, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed." I read some articles in the internet, and I tried to solve this problem by setting the full trust, and it works.
The instruction about how to set Full Trust.
  1. In the desing mode, click menu Tools.
  2. Click Form Options...
  3. Select Category Security and Trust.
  4. Check out the Automatically determine security level.
  5. Check Full Trust.
  6. Create the Certificate.
  7. Select that Certificate.
  8. Click OK.

Then, when you open the form, you have to trust this certificate for the first time of using the form.

Friday, February 15, 2008

Let's Talk about .. InfoPath 2007-Hide the Control

I found this article, Hide a control based on values on the form :: http://office.microsoft.com/en-us/infopath/HP100340241033.aspx, related to my requirement. My requirement is data validation for the summary value of 4 text boxes must not greater than 100, thus I think I should create one text box to be the summary of them, then set the data validation at this text box but I don't want it to be shown so I have to hide it.

The instruction about how to hide a control
  1. Double click at the control.
  2. ClickDisplay Tab.
  3. Click Conditional Formatting Button.
  4. Click Add Button.
  5. Set the condition and check Hide this Control.

Note: some control can't be set as hide this control, but it can be set as Read-only.

Tuesday, February 12, 2008

Let's Talk about .. InfoPath2007-Customize Insert Item

My new requirement is to remove the link "Insert Item" under the repeating table. I found one article helping me, the article Insert a repeating table : http://office.microsoft.com/en-us/infopath/HP100809161033.aspx

The instruction about customizing the Insert Item
  1. Double click at Repeating Table tab, below the repeating table.
  2. The Repeating Table Properties appears on screen. You can remove the check box of Show insert button and hint text to hide the Insert button. And you can click at Customize command to modify the Table command.
  3. In the Table command, you can add, remove, and change the command for that repeating table.

Let's Talk about .. InfoPath 2007-Let's Start

Last week I learned the InfoPath 2007 from P'Tum at my office after I read books and practice some exercises. InfoPath is the essential tool to create the form since there are many useful tool and nice template layout.

P'Tum suggested us to learn more about InfoPath at the MSDN InfoPath Training : http://msdn2.microsoft.com/en-us/library/bb267336.aspx

Thursday, February 7, 2008

Let's Talk about .. SQL Server 2005-Foreign Key

Foreign key is used to reference between two tables in the relational database. Foreign key has to be a primary key or the unique key of a referenced table. P'Kaew taught me how to make a relationship between tables in SQL Server 2005.

The instruction about how to create the Foreign key
  1. Right click at which column attribute you want it to be a foreign key.
  2. Click Relationships.
  3. Click Add in the Foreign Key Relationships.
  4. Click the ... button.
  5. Select the table and the attribute to be a foreign key.

Tuesday, February 5, 2008

Let's Talk about .. VisualStudio 2005-Working with Visual SourceSelf 6.0

By using Microsoft Visual SourceSelf, you can work as team. Many programmers can join one solution. When ProgrammerA checks out the item(s) out, other programmers cannot edit them. P'Aoi, senior system analyst at my office taught me today.

The Instruction about how to add solution to SourceSelf's source control
  1. After creating the project or web site, click Add Solution to Source Control.
  2. Type Username, Password, and select database.
  3. Type the project name.
  4. Click Yes.
  5. Then, your solution is in Source Control. You have to check out to edit what you want.

Friday, February 1, 2008

Let's Talk about .. MOSS2007-Business Data Catalog

Today, there was a meeting at my office, since our database is stored in SAP, but our site is on MOSS 2007, my boss suggested in the meeting room that our solution maybe the Business Data Catalog.
Business Data Catalog is the new feature of MOSS 2007 that serves us to be able to enable MOSS 2007 surfaces with business data from SAP, or other LOB application, with minimal coding.
Again, it's just my begining time. I just study about it from the msdn

More info at http://msdn2.microsoft.com/en-us/library/ms551230.aspx