To view the source right click the movie and select view source.
2009-07-08
Papervision3D
Labels:
flex,
papervision 3D,
project template,
Web
Ok so I have started and the first thing I realised when I looked at the template is that it was doing stuff in 3D so I figured that I probably need to learn how to do that. The template was called Ultra biz papervision 3d flash I figured that Papervision3D is what was doing all the 3D heavy lifting it turns out I was right.
I downloaded the swc and tried to work it out, this is what I managed.
2009-07-07
Project Template
Labels:
flex,
project template,
Web
A few weeks ago after spending ages trying to make a cross browser Javascript application and ending up with two lots of code one for IE 7 and one for the rest of the browsers, I decided that there must be a better way enter flex.
I spent a week doing the flex in a week and then it was time to come up with an project to see how this flex thing really works. This is where the contest I won came into play I won $100 of templates and got this template so I figured what better way to learn flex that to try and recreate it using flex instead of boring old flex so project template was born, I will update here as I work through it with all source code included.
I spent a week doing the flex in a week and then it was time to come up with an project to see how this flex thing really works. This is where the contest I won came into play I won $100 of templates and got this template so I figured what better way to learn flex that to try and recreate it using flex instead of boring old flex so project template was born, I will update here as I work through it with all source code included.
Out in the Wild
Labels:
Web
My pet project has just finshed its first test in the wild and from what I can tell things went great. To have a look at the website where you to can ask for information feel free to go to the ultimate iphone and iPod Touch Survey Software for Market Research tool, yeah I know its a long link but i do what I am told.
2009-07-06
Excel Reader Writer (excel not required)
Labels:
.net,
Free Stuff,
How to,
Web,
Windows
Ok as promised here it is a very simple(1 days work) wrapper for reading and writing excel files using 2007 Office System Driver: Data Connectivity Component. Below is an example function that shows what the class library can do. Remember to include a reference to the library in you project.
public void CorichExcel()
{
string file = "C:/excel.xls";
string sheet = "";
try
{
//Gets a liost of sheets from the excel file
string[] sheets = Corich.Excel.ReaderWriter.GetSheets(file);
sheet = sheets[0];
}
catch(Exception ex)
{
MessageBox.Show(ex.Message);
return;
}
//Check to see if the sheet exist
if (Corich.Excel.ReaderWriter.SheetExists(file, sheet))
{
//gets a list of colums from the first sheet in the excel file
string[] columns = Corich.Excel.ReaderWriter.GetColumns(file, sheet);
//Loads the data in the first excel sheet into a data table
DataTable data = Corich.Excel.ReaderWriter.Read(file);
//Writes the data from the first sheet to a new excel file, currently only writes to xlsb files
Corich.Excel.ReaderWriter.Write("C:\new_file.xlsb", data);
//Writes the data from the first sheet to a new excel file in the temp directory then opens it, currently only writes to xlsb files
Corich.Excel.ReaderWriter.WriteToTemp("new_file.xlsb", data, true);
}
}
You can download the .dll and the source here the code is under the GNU GPL licence it would be nice to point people to my site if you use it.
2009-07-03
Excel Sheet Names using ODBC
I recently needed to import data from excel into a c# application after doing some searching I found the 2007 Office System Driver: Data Connectivity Components there is a lot of good info on the net so I quickly got it up and running.
There was only one problem nowhere I looked could I find out how to get the sheet names. I stared putting various stuff into a data grid until I cam up with the code below.
string filename = "your filename";
string connectionString;
connectionString = "Driver={Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)};dbq=" + filename + ";fil=excel 12.0;readonly=0;usercommitsync=Yes";
OdbcConnection myConnection = new OdbcConnection(connectionString);
myConnection.Open();
DataTable data = myConnection.GetSchema("Tables");
myConnection.Close();
List sheets = new List();
foreach (DataRow sheet in data.Rows)
{
sheets.Add(sheet["TABLE_NAME"].ToString().Trim('\'').TrimEnd('$'));
}
P.S. I have built a whole static class library to read and write excel sheets I will post it here when I have some time to comment it.
2008-11-25
Auto Redirect to Login in page on an ASP.NET Website and keep styles
I have been working on an ASP.NET website recently and I ran into a problem where if I automatically redirected to the login page I lost my styles.
I found a solution tho and here it is:
<!-- allows access Styles and Images directories-->
<location path="Styles">
<system.web>
<authorization>
<allow users="?">
</allow></authorization>
</system.web>
</location>
<location path="Images">
<system.web>
<authorization>
<allow users="?">
</allow></authorization>
</system.web>
</location>
<system.web>
...
<authentication mode="Forms">
<!-- When a user does not have access redirects to the login-->
<forms loginUrl="Login.aspx" name="Login">
</forms></authentication>
<!-- Blocked access to all undecleared directores/files-->
<authorization>
<deny users="?">
</deny></authorization>
...
</system.web>
2008-11-17
Pirates are not always cool
Labels:
Gaming
It turns out Pirates like games too so much so that they are stealing your consoles. Damn pirates!
Subscribe to:
Comments (Atom)